LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices

Reply
 
Search this Thread
Old 01-06-2006, 06:28 AM   #1
ppanyam
Member
 
Registered: Oct 2004
Location: India
Distribution: Redhat
Posts: 88

Rep: Reputation: 15
EBCDIC to ASCII in Perl


In my Perl script, $data contains 3200 bytes of data, which is actually 3200 chars of text written in EBCDIC format.

How can I print it on screen or convert it to ASCII?
 
Old 01-06-2006, 11:35 AM   #2
jim mcnamara
Member
 
Registered: May 2002
Posts: 964

Rep: Reputation: 34
dd is a linux command line utility that converts ASCII<->EBCDIC.

You'll have to invoke it using system() (it only works on files and stdin) and create a tmpfile that is ASCII.

See man dd for more information.

Last edited by jim mcnamara; 01-06-2006 at 11:37 AM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
ASCII C Help, Please InvisibleSniper Programming 33 10-10-2005 10:25 AM
what are the Hexadecimal function and ASCII function in Perl Bassam Programming 1 06-03-2004 01:44 AM
perl(Cwd) perl(File::Basename) perl(File::Copy) perl(strict)....What are those? Baldorg Linux - Software 1 11-09-2003 08:09 PM
PERL premature end of script ASCII question Neorio Programming 2 08-08-2003 09:06 AM
ASCII help My_World Linux - General 1 04-13-2003 12:17 PM


All times are GMT -5. The time now is 09:24 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration