EBCDIC

Extended Binary Coded Decimal Interchange Code[1] (EBCDIC;[1] /ˈɛbsɪdɪk/) is an eight-bit character encoding used mainly on IBM mainframe and IBM midrange computer operating systems. It descended from the code used with punched cards and the corresponding six bit binary-coded decimal code used with most of IBM's computer peripherals of the late 1950s and early 1960s.[2] It is supported by various non-IBM platforms, such as Fujitsu-Siemens' BS2000/OSD, OS-IV, MSP, and MSP-EX, the SDS Sigma series, Unisys VS/9, Burroughs MCP and ICL VME.

EBCDIC encoding family
Classification8-bit basic Latin encodings (non‑ASCII)
Preceded byBCD
Succeeded byUTF-16

History

Blue-punch-card-front-horiz top-char-contrast-stretched
Punched card with the Hollerith encoding of the 1964 EBCDIC character set. Contrast at top enhanced to show the printed characters.

EBCDIC was devised in 1963 and 1964 by IBM and was announced with the release of the IBM System/360 line of mainframe computers. It is an eight-bit character encoding, developed separately from the seven-bit ASCII encoding scheme. It was created to extend the existing Binary-Coded Decimal (BCD) Interchange Code, or BCDIC, which itself was devised as an efficient means of encoding the two zone and number punches on punched cards into six bits. The distinct encoding of 's' and 'S' (using position 2 instead of 1) was maintained from punched cards where it was desirable not to have hole punches too close to each other to ensure the integrity of the physical card.

While IBM was a chief proponent of the ASCII standardization committee,[3] the company did not have time to prepare ASCII peripherals (such as card punch machines) to ship with its System/360 computers, so the company settled on EBCDIC.[2] The System/360 became wildly successful, together with clones such as RCA Spectra 70, ICL System 4, and Fujitsu FACOM, thus so did EBCDIC.

All IBM mainframe and midrange peripherals and operating systems use EBCDIC as their inherent encoding[4] (with toleration for ASCII, for example, ISPF in z/OS can browse and edit both EBCDIC and ASCII encoded files). Software and many hardware peripherals can translate to and from encodings, and modern mainframes (such as IBM zSeries) include processor instructions, at the hardware level, to accelerate translation between character sets.

There is an EBCDIC-oriented Unicode Transformation Format called UTF-EBCDIC proposed by the Unicode consortium, designed to allow easy updating of EBCDIC software to handle Unicode, but not intended to be used in open interchange environments. Even on systems with extensive EBCDIC support, it has not been popular. For example, z/OS supports Unicode (preferring UTF-16 specifically), but z/OS only has limited support for UTF-EBCDIC.

IBM AIX running on the RS/6000 and its descendants including the IBM Power Systems, Linux running on z Systems, and operating systems running on the IBM PC and its descendants use ASCII, as did AIX/370 and AIX/390 running on System/370 and System/390 mainframes.

Compatibility with ASCII

The fact that all the code points were different was less of a problem for inter-operating with ASCII than the fact that sorting EBCDIC put lowercase letters before uppercase letters and letters before numbers, exactly the opposite of ASCII.

Programming languages and file formats and network protocols designed for ASCII quickly made use of available punctuation marks (such as the curly braces '{ ' and  ' }' ) that did not exist in EBCDIC, making translation to EBCDIC ambiguous (this also prevented various attempts to make internationalized versions of ASCII which also replaced these punctuation marks with letters).

The gaps between letters made simple code that worked in ASCII fail on EBCDIC. For example, "for (c='A';c<='Z';++c)" would set c to the 26 letters in the ASCII alphabet, but 41 characters including a number of unassigned ones in EBCDIC. Fixing this required complicating the code with function calls which was greatly resisted by programmers.

By using all eight bits EBCDIC may have encouraged the use of the eight-bit byte by IBM, while ASCII was more likely to be adopted by systems with 36 bits (as five seven-bit ASCII characters fit into one word).

As eight-bit bytes became widespread, ASCII systems sometimes used the "unused" bit for other purposes, such as metacharacters to mark the borders of records or words. This made it difficult to change the code to work with EBCDIC. On the PDP-11 bytes with the high bit set were treated as negative numbers, behavior that was copied to C, causing unexpected problems with EBCDIC. Both of these problems also hindered the adoption of extended ASCII character sets.

Code page layout

The table below shows the "invariant subset" of EBCDIC, which are characters that should have the same assignments on all EBCDIC code pages. It also shows (in gray) missing ASCII and EBCDIC punctuation, located where they are in CCSID 037 (one of the code page variants of EBCDIC). Unassigned codes are typically filled with international or region-specific characters in the various EBCDIC code page variants, but the characters in boxes are often moved around as well.

In each table cell below, the first row is an abbreviation for a control code or (for printable characters) the character itself; and the second row is the Unicode code (blank for controls that don't exist in Unicode).

EBCDIC
_0 _1 _2 _3 _4 _5 _6 _7 _8 _9 _A _B _C _D _E _F
0_ NUL
0000
SOH
0001
STX
0002
ETX
0003
SEL
 
HT
0009
RNL
 
DEL
007F
GE
 
SPS
 
RPT
 
VT
000B
FF
000C
CR
000D
SO
000E
SI
000F
1_ DLE
0010
DC1
0011
DC2
0012
DC3
0013
res/enp
 
NL
0085
BS
0008
POC
 
CAN
0018
EM
0019
UBS
 
CU1
 
IFS
001C
IGS
001D
IRS
001E
ius/itb
001F
2_ DS
 
SOS
 
FS
 
WUS
 
byp/inp
 
LF
000A
ETB
0017
ESC
001B
SA
 
SFE
 
sm/sw
 
CSP
 
MFA
 
ENQ
0005
ACK
0006
BEL
0007
3_ SYN
0016
IR
 
PP
 
TRN
 
NBS
 
EOT
0004
SBS
 
IT
 
RFF
 
CU3
 
DC4
0014
NAK
0015
SUB
001A
4_ SP
0020
¢
00A2
.
002E
<
003C
(
0028
+
002B
|
007C
5_ &
0026
!
0021
$
0024
*
002A
)
0029
;
003B
¬
00AC
6_ -
002D
/
002F
¦
00A6
,
002C
%
0025
_
005F
>
003E
?
003F
7_ `
0060
:
003A
#
0023
@
0040
'
0027
=
003D
"
0022
8_ a
0061
b
0062
c
0063
d
0064
e
0065
f
0066
g
0067
h
0068
i
0069
±
00B1
9_ j
006A
k
006B
l
006C
m
006D
n
006E
o
006F
p
0070
q
0071
r
0072
A_ ~
007E
s
0073
t
0074
u
0075
v
0076
w
0077
x
0078
y
0079
z
007A
B_ ^
005E
[
005B
]
005D
C_ {
007B
A
0041
B
0042
C
0043
D
0044
E
0045
F
0046
G
0047
H
0048
I
0049
D_ }
007D
J
004A
K
004B
L
004C
M
004D
N
004E
O
004F
P
0050
Q
0051
R
0052
E_ \
005C
S
0053
T
0054
U
0055
V
0056
W
0057
X
0058
Y
0059
Z
005A
F_ 0
0030
1
0031
2
0032
3
0033
4
0034
5
0035
6
0036
7
0037
8
0038
9
0039
EO
 

Definitions of non-Unicode EBCDIC controls

SEL 0004 Device-specific control character
RNL 0006 Required newline and resets Indent Tab mode
GE 0008 Non-locking shift that changes the interpretation of the following character
SPS 0009 Begin superscript or undo subscript
RPT 000A Repeat, device-specific character string repeat order
RES/ENP 0014 Restore/Enable Presentation, "terminates the Bypass/Inhibit Presentation mode of operation and activates associated printers or displays"
POC 0017 Program Operator Communication. Followed by two one-byte operators that identify the specific function, for example a light or function key
UBS 001A Unit backspace a fractional space
CU1 001B Customer use, not used by IBM
IUS/ITB 001F Interchange Unit Separator, Intermediate Transmission Block. Terminates an information block called a UNIT.
DS 0020 Digit Select, used by S/360 edit (ED) instruction
SOS 0021 Start of Significance, used by S/360 edit (ED) instruction
WUS 0023 Word Underscore, underscores the immediately preceding word
BYP/INP 0024 Bypass/Inhibit Presentation, terminates RES/ENP mode
SA 0028 Set Attribute, marks the beginning of a fixed-length device specific control sequence (deprecated)
SFE 0029 Start Field Extended, marks the beginning of a variable-length device specific control sequence (deprecated)
SM/SW 002A Set Mode/Switch, device specific control that sets a mode of operation
CSP 002B Control Sequence Prefix, marks the beginning of a variable-length device specific control sequence
MFA 002C Modify Field Attribute, marks the beginning of a variable-length device specific control sequence (deprecated)
0030 Reserved for future use by IBM
0031 Reserved for future use by IBM
IR 0033 Index Return, Move to start of next line or terminate an information unit
PP 0034 Presentation Position, followed by two one-byte parameters to set the current position
TRN 0035 Transparent, followed by one byte parameter that indicates the number of bytes of transparent data that follow
NBS 0036 Numeric Backspace, move backwards the width of one digit
SBS 0038 Subscript, begin subscript or undo superscript
IT 0039 Indent Tab, indents the current and all following lines, reset by RNL or RFF
RFF 003A Required Formfeed and reset Indent Tab mode
CU3 003B Customer use, not used by IBM
003E Reserved for future use by IBM
EO 00FF All ones character used as filler

[5]

Criticism and humor

Open-source software advocate and software developer Eric S. Raymond writes in his Jargon File that EBCDIC was loathed by hackers, by which he meant[6] members of a subculture of enthusiastic programmers. The Jargon File 4.4.7 gives the following definition:[7]

EBCDIC: /eb´s@·dik/, /eb´see`dik/, /eb´k@·dik/, n. [abbreviation, Extended Binary Coded Decimal Interchange Code] An alleged character set used on IBM dinosaurs. It exists in at least six mutually incompatible versions, all featuring such delights as non-contiguous letter sequences and the absence of several ASCII punctuation characters fairly important for modern computer languages (exactly which characters are absent varies according to which version of EBCDIC you're looking at). IBM adapted EBCDIC from punched card code in the early 1960s and promulgated it as a customer-control tactic (see connector conspiracy), spurning the already established ASCII standard. Today, IBM claims to be an open-systems company, but IBM's own description of the EBCDIC variants and how to convert between them is still internally classified top-secret, burn-before-reading. Hackers blanch at the very name of EBCDIC and consider it a manifestation of purest evil.

— The Jargon file 4.4.7

EBCDIC design was also the source of many jokes. One such joke went:

Professor: "So the American government went to IBM to come up with an encryption standard, and they came up with—"
Student: "EBCDIC!"

References to the EBCDIC character set are made in the classic Infocom adventure game series Zork. In the "Machine Room" in Zork II, EBCDIC is used to imply an incomprehensible language:

This is a large room full of assorted heavy machinery, whirring noisily. The room smells of burned resistors. Along one wall are three buttons which are, respectively, round, triangular, and square. Naturally, above these buttons are instructions written in EBCDIC...

See also

References

  1. ^ a b Mackenzie, Charles E. (1980). Coded Character Sets, History and Development. The Systems Programming Series (1 ed.). Addison-Wesley Publishing Company, Inc. ISBN 0-201-14460-3. LCCN 77-90165. ISBN 978-0-201-14460-4. Retrieved 2016-05-22. [1]
  2. ^ a b Bemer, Bob. "EBCDIC and the P-Bit (The Biggest Computer Goof Ever) - Computer History Vignettes". Archived from the original on 2018-05-13. Retrieved 2013-07-02. […] but their printers and punches were not ready to handle ASCII, and IBM just HAD to announce.
  3. ^ "X3.4-1963". 1963. p. 4. Archived from the original on 2016-08-12. (NB. IBM had four staff members on the final 21-member ASA X3.2 sub-committee.)
  4. ^ IBMnt (2008). "IBM confirms the use of EBCDIC in their mainframes as a default practice". Archived from the original on 2013-01-03. Retrieved 2008-06-16.
  5. ^ "Appendix G-1. EBCDIC control character definitions". IBM Globalization. IBM Corporation. Archived from the original on 2018-09-11.
  6. ^ Raymond, Eric S. (1997). "The New Hacker's Dictionary". p. 310.
  7. ^ "EBCDIC". Jargon File. Archived from the original on 2018-05-13. Retrieved 2018-05-13.

External links

EBCDIC 005

IBM code page 5 (CCSID 5) is an EBCDIC code page used on IBM mainframes in the United States to support the English language.

EBCDIC 006

IBM code page 6 (CCSID 6) is an EBCDIC code page used on IBM mainframes in the Latin America to support the Spanish language.

EBCDIC 009

IBM code page 9 (CCSID 9) is an EBCDIC code page used on IBM mainframes in France to support the French language.

EBCDIC 037

IBM code page 37 is an EBCDIC code page with the full Latin-1 character set used in IBM mainframes. It is used in some English- and Portuguese-speaking countries, including Australia, Brazil, Canada, New Zealand, Portugal, South Africa, and the United States.

CCSID 1140 is the Euro currency update of code page/CCSID 37. In that code page, the "¤" (currency sign) character at code point 9F is replaced with the "€" (Euro sign) character.

EBCDIC 1025

IBM code page 1025 (CCSID 1025) is an EBCDIC code page with full Cyrillic-charset used in IBM mainframes. It is a revision of EBCDIC 880 to cover all of the Cyrillic-charset.

CCSID 1154 is the Euro currency update of code page/CCSID 1025. Byte E1 is replacing § with € in that code page.

EBCDIC 1026

IBM code page 1026 (CCSID 1026) is an EBCDIC code page with full Latin-5-charset used in IBM mainframes.

CCSID 1155 is the Euro currency update of code page/CCSID 500. Byte 9F is replacing ¤ with € in that code page.

EBCDIC 1047

Code page 1047 is an EBCDIC code page with the full Latin-1 character set. It is closely related to both EBCDIC 037-2 (with only two points differing) and EBCDIC 037 (with six points differing), both of which also encode Latin-1.

CCSID 924 is the Euro currency update of code page/CCSID 1047. In that code page, the "¤" (currency) character at code point 9F is replaced with the "€" (Euro) character.

EBCDIC 252

Code page 252 aka EBCDIC 252 is a Polish EBCDIC code page used in IBM mainframes. GCSGID is 00093, and CPGID is 00252. The number of characters in the code page is 96.

EBCDIC 260

IBM code page 260 (CCSID 260) is an EBCDIC code page used on IBM mainframes. It supports the French language in Canada.

EBCDIC 276

IBM code page 276 (CCSID 276) is an EBCDIC code page used on IBM mainframes in Canada to support the French language.

EBCDIC 280

IBM code page 280 (CCSID 280) is an EBCDIC code page with full Latin-1-charset used in IBM mainframes. It is used in Italy.

CCSID 1144 is the Euro currency update of code page/CCSID 280. Byte 9F is replacing ¤ with € in that code page.

EBCDIC 283

IBM code page 283 (CCSID 283) is an EBCDIC code page with full EBCDIC 256 charset used in IBM mainframes. It was used in Spain.

It has been superseded by EBCDIC 284, which includes the Latin-1 charset at the same time EBCDIC 256 was superseded by EBCDIC 500.

EBCDIC 284

IBM code page 284 (CCSID 284) is an EBCDIC code page with full Latin-1-charset used in IBM mainframes. It is used in Spain and Latin America.

CCSID 1145 is the Euro currency update of code page/CCSID 284. Byte 9F is replacing ¤ with € in that code page.

EBCDIC 285

IBM code page 285 is an EBCDIC code page with full Latin-1-charset used in IBM mainframes. It is used in Ireland and the United Kingdom.

CCSID 1146 is the Euro currency update of code page/CCSID 285. Byte 9F is replaced ¤ with € in that code page.

For other English-speaking countries, see EBCDIC code page 037.

EBCDIC 297

IBM code page 297 (CCSID 297) is an EBCDIC code page with full Latin-1-charset used in IBM mainframes. It is used in France.

CCSID 1147 is the Euro currency update of code page/CCSID 297. Byte 9F is replacing ¤ with € in that code page.

EBCDIC 410

IBM code page 410 (CCSID 410) is an EBCDIC code page that supports Cyrillic used in IBM mainframes. A revision is EBCDIC 880.

EBCDIC 424

IBM code page 424 is an EBCDIC code page that supports Hebrew used in IBM mainframes.

In CCSID 8616, the directional controls were added at positions DB, DE, DF, FB, FC, FD, and FE. In CCSID 12712, the euro sign was added at position 9C new sheqel sign was added at position 9E.

EBCDIC 870

IBM code page 870 (CCSID 870) is an EBCDIC code page with full Latin-2-charset used in IBM mainframes.

CCSID 1110 replaces byte 90 ˚ (ring above) with ° (degree sign)

CCSID 1153 is the Euro currency update of code page/CCSID 870. Byte 9F is replacing ¤ with € in that code page.

EBCDIC code pages

EBCDIC code pages are based on the original EBCDIC character encoding; there are a variety of EBCDIC code pages intended for use in different parts of the world, including code pages for non-Latin scripts such as Chinese, Japanese (e.g., EBCDIC 930, JEF, and KEIS), Korean, and Greek (EBCDIC 875).

The most common newline convention used with EBCDIC code pages is to use a NEL (NEXT LINE) code between lines. Converters to other encodings often replace NEL with LF or CR/LF, even if there is a NEL in the target encoding.

Early telecommunications
ISO/IEC 8859
Bibliographic use
National standards
EUC
ISO/IEC 2022
MacOS code pages("scripts")
DOS code pages
IBM AIX code pages
IBM Apple MacIntoshemulations
IBM Adobe emulations
IBM DEC emulations
IBM HP emulations
Windows code pages
EBCDIC code pages
Platform specific
Unicode / ISO/IEC 10646
TeX typesetting system
Miscellaneous code pages
Related topics

This page is based on a Wikipedia article written by authors (here).
Text is available under the CC BY-SA 3.0 license; additional terms may apply.
Images, videos and audio are available under their respective licenses.