Thu Feb 14 00:12:21 GMT 2008

Travelling through France

Here's the photos of our trip through France in November-December 2007

Trip to France - November to December 2007

Posted by Bradley Dean | Permalink | Categories: Travel

Monday 22nd May, 2006 00:10:41 AEST

Transforming between ASCII and EBCDIC

The first time you come across EBCDIC data in an ASCII based environment (or vice versa) things can become a tad confusing - fotunately there's an easy way to convert the data back and forth.

EBCDIC and ASCII are base character encodings - almost all current operating systems use one or the other of these (most using ASCII).

Definitions from Wikipedia

WikiPedia:ASCII :

ASCII (American Standard Code for Information Interchange), generally pronounced [æski], is a character encoding based on the English alphabet. ASCII codes represent text in computers, communications equipment, and other devices that work with text. Most modern character encodings have a historical basis in ASCII.

WikiPedia:EBCDIC :

EBCDIC (Extended Binary Coded Decimal Interchange Code) is an 8-bit character encoding (code page) used on IBM mainframe operating systems, like z/OS, OS/390, VM and VSE, as well as IBM minicomputer operating systems like OS/400 and i5/OS. It is also employed on various non-IBM platforms such as Fujitsu-Siemens' BS2000/OSD, HP MPE/iX, and Unisys MCP. It descended from punched cards and the corresponding six bit binary-coded decimal code that most of IBM's computer peripherals of the late 1950s and early 1960s used.

To transform data between EBCDIC and ASCII the UNIX utility '''dd''' comes to the rescue - better yet, it comes to the rescue in a very simple way.

ASCII to EBCDIC

1  $ cat ascii_data_file | dd conv=ebcdic

EBCDIC to ASCII

1  $ cat ebcdic_data_file | dd conv=ascii

Posted by Bradley Dean | Permalink | Categories: Travel, Programming