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, 07: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, 12:35 PM   #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 12:37 PM.
 
  


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 11:25 AM
what are the Hexadecimal function and ASCII function in Perl Bassam Programming 1 06-03-2004 02:44 AM
perl(Cwd) perl(File::Basename) perl(File::Copy) perl(strict)....What are those? Baldorg Linux - Software 1 11-09-2003 09:09 PM
PERL premature end of script ASCII question Neorio Programming 2 08-08-2003 10:06 AM
ASCII help My_World Linux - General 1 04-13-2003 01:17 PM


All times are GMT -5. The time now is 06:42 AM.

Main Menu
Advertisement
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