[H-GEN] EBCDIC -> ASCII
Stuart Longland
stuartl at longlandclan.hopto.org
Tue Dec 30 20:38:00 EST 2003
Brenton Bills wrote:
> I am trying to conver an EBCDIC file to ASCII, I am using the command,
>
> dd conv=ascii if=infile of=new.txt
>
I just tried the following...
(11:32) stuartl at beast stuartl $ dd if=Configure.help
of=Configure.help.ebcdic conv=ebcdic
2386+1 records in
2386+1 records out
>> got me an EBCDIC-encoded file: Configure.help.ebcdic
(11:32) stuartl at beast stuartl $ less Configure.help.ebcdic
"Configure.help.ebcdic" may be a binary file. See it anyway? y
{@<D4><81><89><95><A3><81><89><95><85><84>@<82><A8>z%{^E<C5><99><89>
<83>@<E2>K@<D9><81><A8><94><96><95><84>@L<94><81><89><93><A3><96>z<85>
<A2><99>|<A3><88><A8><99><A2><A4><A2>K<83><96><94>n%{^E<E2><A3><85><A5>
<85><95>@<C3><96><93><85>@L<94><81><89><93><A3><96>z<85><93><85><95><A2>
<A3><85><A5>|<94><85><A2><81><A3><96><97>K<83><96><94>n%{%{@<E3><99>
<81><95><A2><93><81><A3><89><96><95><A2>@<96><86>@<A3><88><89><A2>@
<86><89><93><85>@<81><A5><81><89><93><81><82><93>
>> I see more random junk like the above (I assume this is what EBCDIC
>> looks like when viewed as ASCII). Now to convert back...
(11:32) stuartl at beast stuartl $ dd if=Configure.help.ebcdic
of=Configure.help.ascii conv=ascii
2386+1 records in
2386+1 records out
(11:32) stuartl at beast stuartl $ less Configure.help.ascii
# Maintained by:
# Eric S. Raymond <mailto:esr at thyrsus.com>
# Steven Cole <mailto:elenstev at mesatop.com>
#
# Translations of this file available on the WWW:
#
# - Japanese, maintained by the JF Project <mailto:JF at linux.or.jp>, at
# <http://www.linux.or.jp/JF/JFdocs/Configure.help/>
Looks like that's back to ASCII... Hope this helps.
--
+-------------------------------------------------------------+
| Stuart Longland stuartl at longlandclan.hopto.org |
| Brisbane Mesh Node: 719 http://stuartl.cjb.net/ |
| I haven't lost my mind - it's backed up on a tape somewhere |
| Atomic Linux Project <---> http://atomicl.berlios.de/ |
+-------------------------------------------------------------+
More information about the General
mailing list