ASCII
ASCII, an acronym for American Standard Code for Information Interchange, is a character encoding standard for representing a particular set of 95 printable and 33 control characters a total of 128 code points. The set of available punctuation had significant impact on the syntax of computer languages and text markup. ASCII hugely influenced the design of character sets used by modern computers; for example, the first 128 code points of Unicode are the same as ASCII.
ASCII encodes each code-point as a value from 0 to 127 storable as a seven-bit integer. Ninety-five code-points are printable, including digits 0 to 9, lowercase letters a to z, uppercase letters A to Z, and commonly used punctuation symbols. For example, the letter is represented as 105. Also, ASCII specifies 33 non-printing control codes which originated with, most of which are now obsolete. The control characters that are still commonly used include carriage return, line feed, and tab.
ASCII lacks code-points for characters with diacritical marks and therefore does not directly support terms or names such as résumé, jalapeño, or René. But, depending on hardware and software support, some diacritical marks can be rendered by overwriting a letter with a backtick or tilde.
The Internet Assigned Numbers Authority prefers the name US-ASCII for this character encoding.
ASCII is one of the IEEE milestones.
History
ASCII is the standardisation of a seven-bit teleprinter code developed in part from earlier telegraph codes.Work on the ASCII standard began in May 1961, when IBM engineer Bob Bemer submitted a proposal to the American Standards Association's X3.2 subcommittee. The first edition of the standard was published in 1963, contemporaneously with the introduction of the Teletype Model 33. It later underwent a major revision in 1967, and several further revisions until 1986. In contrast to earlier telegraph codes such as Baudot, ASCII was ordered for more convenient collation, and added controls for devices other than teleprinters.
ASCII was developed under the auspices of a committee of the American Standards Association, called the X3 committee, by its X3.2 subcommittee, and later by that subcommittee's X3.2.4 working group. The ASA later became the United States of America Standards Institute and ultimately became the American National Standards Institute.
With the other special characters and control codes filled in, ASCII was published as ASA X3.4-1963, leaving 28 code positions without any assigned meaning, reserved for future standardization, and one unassigned control code. There was some debate at the time whether there should be more control characters rather than the lowercase alphabet. The indecision did not last long: during May 1963 the CCITT Working Party on the New Telegraph Alphabet proposed to assign lowercase characters to sticks 6 and 7, and International Organization for Standardization TC 97 SC 2 voted during October to incorporate the change into its draft standard. The X3.2.4 task group voted its approval for the change to ASCII at its May 1963 meeting. Locating the lowercase letters in sticks 6 and 7 caused the characters to differ in bit pattern from the upper case by a single bit, which simplified case-insensitive character matching and the construction of keyboards and printers.
The X3 committee made other changes. It added the brace and vertical bar characters. It renamed some control characters SOM became SOH. It moved or removed others RU was removed. ASCII was subsequently updated as USAS X3.4-1967, then USAS X3.4-1968, ANSI X3.4-1977, and finally, ANSI X3.4-1986.
The use of ASCII format for Network Interchange was described in 1969. That document was formally elevated to an Internet Standard in 2015.
Revisions
- ASA X3.4-1963
- ASA X3.4-1965
- USAS X3.4-1967
- USAS X3.4-1968
- ANSI X3.4-1977
- ANSI X3.4-1986
- ANSI X3.4-1986
- ANSI X3.4-1986
- ANSI INCITS 4-1986
- ANSI INCITS 4-1986
- INCITS 4-1986
- INCITS 4-1986
- INCITS 4-1986
Design considerations
Bit width
The X3.2 subcommittee designed ASCII based on the earlier teleprinter encoding systems. Like other character encodings, ASCII specifies a correspondence between digital bit patterns and character symbols. This allows digital devices to communicate with each other and to process, store, and communicate character-oriented information such as written language. Before ASCII was developed, the encodings in use included 26 alphabetic characters, 10 numerical digits, and from 11 to 25 special graphic symbols. To include all these, and control characters compatible with the Comité Consultatif International Téléphonique et Télégraphique International Telegraph Alphabet No. 2 standard of 1932, FIELDATA, and early EBCDIC, more than 64 codes were required for ASCII.ITA2 was in turn based on Baudot code, the 5-bit telegraph code Émile Baudot invented in 1870 and patented in 1874.
The committee debated the possibility of a shift function, which would allow more than 64 codes to be represented by a six-bit code. In a shifted code, some character codes determine choices between options for the following character codes. It allows compact encoding, but is less reliable for data transmission, as an error in transmitting the shift code typically makes a long part of the transmission unreadable. The standards committee decided against shifting, and so ASCII required at least a seven-bit code.
The committee considered an eight-bit code, since eight bits would allow two four-bit patterns to efficiently encode two digits with binary-coded decimal. However, it would require all data transmission to send eight bits when seven could suffice. The committee voted to use a seven-bit code to minimize costs associated with data transmission. Since perforated tape at the time could record eight bits in one position, it also allowed for a parity bit for error checking if desired. Eight-bit machines that did not use parity checking typically set the eighth bit to 0.
Internal organization
The code itself was patterned so that most control codes were together and all graphic codes were together, for ease of identification. The first two so-called ASCII sticks were reserved for control characters. The "space" character had to come before graphics to make sorting easier, so it became position 20hex; for the same reason, many special signs commonly used as separators were placed before digits. The committee decided it was important to support uppercase 64-character alphabets, and chose to pattern ASCII so it could be reduced easily to a usable 64-character set of graphic codes, as was done in the DEC SIXBIT code. Lowercase letters were therefore not interleaved with uppercase. To keep options available for lowercase letters and other graphics, the special and numeric codes were arranged before the letters, and the letter A was placed in position 41hex to match the draft of the corresponding British standard. The digits 0–9 are prefixed with 011, but the remaining 4 bits correspond to their respective values in binary, making conversion with binary-coded decimal straightforward.Many of the non-alphanumeric characters were positioned to correspond to their shifted position on typewriters; an important subtlety is that these were based on mechanical typewriters, not electric typewriters. Mechanical typewriters followed the de facto standard set by the Remington No. 2, the first typewriter with a shift key, and the shifted values of
23456789- were "#$%_&' early typewriters omitted 0 and 1, using O and l pairs became standard once 0 and 1 became common. Thus, in ASCII !"#$% were placed in the second stick, positions 1–5, corresponding to the digits 1–5 in the adjacent stick. The parentheses could not correspond to 9 and 0, however, because the place corresponding to 0 was taken by the space character. This was accommodated by removing _ from 6 and shifting the remaining characters, which corresponded to many European typewriters that placed the parentheses with 8 and 9. This discrepancy from typewriters led to bit-paired keyboards, notably the Teletype Model 33, which used the left-shifted layout corresponding to ASCII, differently from traditional mechanical typewriters.Electric typewriters, notably the IBM Selectric, used a somewhat different layout that has become de facto standard on computers following the IBM PC, especially Model M and thus shift values for symbols on modern keyboards do not correspond as closely to the ASCII table as earlier keyboards did. The
/? pair also dates to the No. 2, and the ,<.> pairs were used on some keyboards or .. However, ASCII split the ;: pair, and rearranged mathematical symbols to :* ;+ -=.Some then-common typewriter characters were not included, notably
½ ¼ ¢, while ^ ` ~ were included as diacritics for international use, and < > for mathematical use, together with the simple line characters \ |. The @ symbol was not used in continental Europe and the committee expected it would be replaced by an accented À in the French variation, so the @ was placed in position 40hex, right before the letter A.The control codes felt essential for data transmission were the start of message, end of address, end of message, end of transmission, "who are you?", "are you?", a reserved device control, synchronous idle, and acknowledge. These were positioned to maximize the Hamming distance between their bit patterns.