/* * chcode.doc 3/01/91 */ /***************************************************************************** * * * Copyright (c) 1991 * * * * The Workstation Vertical Integeration Project, PDD, III * * * * Share and Enjoy it. * * Any part of this program or publication can be reproduced, transmitted, * * transcribed stored in your system, or translated into any language or * * computer language, in any form or by any means, electronic, mechanical, * * magnetic, optical, chemical, biological, and otherwise if you like. * * Welcome any question. * * * * The Workstation Vertical Integeration Project, PDD, III * * 8FL., 106, HOPING E. RD., SEC. 2 TAIPEI, TAIWAN, R.O.C. * * (02) 7377197 Dan_Yi Liu * * * *****************************************************************************/ The Transformation of Chinese Utility Codes NAME chcode -- convert any one of these Chinese codes(BIG5, IBM 5550, IBM HOST, NSC, EUC, TCA, TELegraph) to the other seven. SYNOPSIS chcode infile outfile DESCRIPTION 'chcode' is used to convert an existed file of one of the Chinese codes to an output file of the other seven and must be given the following arguments: ( Note: If chcode is given no argument, you will get the usage. ) This is the type of the Chinese codes in the input file. infile This is the name of the input file which will be converted by the program. This is the type of the Chinese codes in the output file. outfile This is the name of the destination file to which the conversion results of the program are transfered. Options to chcode must always precede file names. The following options are available for chcode: B BIG5 code I IBM 5550 code H IBM HOST code N NSC(National Standard Code) Internal code P NSC with Protocol code E EUC code T TCA code L TELegraph code CODE STRUCTURE The number of different Chinese internal code systems developed by various orgamizations in Taiwan has grown too large to facilitate data transfer between different systems ( especially through net_ works ). This program alleviates the above difficulty by providing convertions among eight internal codes that are most commonly used. Most of these Chinese internal codes consist of 2_byte ASCII codes except for EUC, which control code SI (Shift In, 0f) and SO (Shift Out, 0e) to distinguish Chinese mode from English mode. As for NSC (with protocal), ISO 2022 standard is followed. In this program, the size of the data type of a code, called 'CODE', is four bytes.