00 01 02 03 04 05 06 07 08 09 10 11 12 13 14 15
00 0 1 2 3 4 5 6 7 8 9 . SET EXP CHANGE SIGN E13 Clear Clear Display
01 TOTAL 00 TOTAL 01 TOTAL 02 TOTAL 03 TOTAL 04 TOTAL 05 TOTAL 06 TOTAL 07 TOTAL 08 TOTAL 09 TOTAL 10 TOTAL 11 TOTAL 12 TOTAL 13 TOTAL 14 TOTAL 15
02 + 00 + 01 + 02 + 03 + 04 + 05 + 06 + 07 + 08 + 09 + 10 + 11 + 12 + 13 + 14 + 15
03 - 00 - 01 - 02 - 03 - 04 - 05 - 06 - 07 - 08 - 09 - 10 - 11 - 12 - 13 - 14 - 15
04 × 00 × 01 × 02 × 03 × 04 × 05 × 06 × 07 × 08 × 09 × 10 × 11 × 12 × 13 × 14 × 15
05 ÷ 00 ÷ 01 ÷ 02 ÷ 03 ÷ 04 ÷ 05 ÷ 06 ÷ 07 ÷ 08 ÷ 09 ÷ 10 ÷ 11 ÷ 12 ÷ 13 ÷ 14 ÷ 15
06 STORE 00 STORE 01 STORE 02 STORE 03 STORE 04 STORE 05 STORE 06 STORE 07 STORE 08 STORE 09 STORE 10 STORE 11 STORE 12 STORE 13 STORE 14 STORE 15
07 RECALL 00 RECALL 01 RECALL 02 RECALL 03 RECALL 04 RECALL 05 RECALL 06 RECALL 07 RECALL 08 RECALL 09 RECALL 10 RECALL 11 RECALL 12 RECALL 13 RECALL 14 RECALL 15
08 SEARCH * RECALL * PRINT (*) GO JIF0 JIF+ SIN COS TAN RAD-DEG LOGeX ex X2 √X LOAD PROG 1/X
09 MARK * STORE * α * STOP JIF≠0 JIF ERROR SIN-1 COS-1 TAN-1 DEG-RAD LOG10X 10x INT X |X| END PROG RETURN
10 Call
10 00
Call
10 01
Call
10 02
Call
10 03
Call
10 04
Call
10 05
Call
10 06
Call
10 07
Call
10 08
Call
10 09
Call
10 10
Call
10 11
Call
10 12
Call
10 13
Call
10 14
Call
10 15
11 Call
11 00
Call
11 01
Call
11 02
Call
11 03
Call
11 04
Call
11 05
Call
11 06
Call
11 07
Call
11 08
Call
11 09
Call
11 10
Call
11 11
Call
11 12
Call
11 13
Call
11 14
Call
11 15
12 Call ROM
12 00
Call ROM
12 01
Call ROM
12 02
Call ROM
12 03
Call ROM
12 04
Call ROM
12 05
Call ROM
12 06
Call ROM
12 07
Call ROM
12 08
Call ROM
12 09
Call ROM
12 10
Call ROM
12 11
Call ROM
12 12
Call ROM
12 13
Call ROM
12 14
Call ROM
12 15
13 Call ROM
13 00
Call ROM
13 01
Call ROM
13 02
Call ROM
13 03
Call ROM
13 04
Call ROM
13 05
Call ROM
13 06
Call ROM
13 07
Call ROM
13 08
Call ROM
13 09
Call ROM
13 10
Call ROM
13 11
Call ROM
13 12
Call ROM
13 13
Call ROM
13 14
Call ROM
13 15
14 EXCHG 00 EXCHG 01 EXCHG 02 EXCHG 03 EXCHG 04 EXCHG 05 EXCHG 06 EXCHG 07 EXCHG 08 EXCHG 09 EXCHG 10 EXCHG 11 EXCHG 12 EXCHG 13 EXCHG 14 EXCHG 15
15 RECALL * Print * I/O * SEARCH ROM * SEARCH ROM * SEARCH ROM * SEARCH ROM * Call * (MARK) * STORE * α * INDIR * Call ROM * GROUP 1 * GROUP 2 * SEARCH *
* Two-step command sequences, described below

SEARCH, MARK, and Call prefixes
The second step is a "label", used to implement goto and call. Any code may be used, however END PROG should be avoided.
Note: while the 15 08 variant of MARK is executed identically to 09 00, it does not actually mark a label. It is, in affect, a two-step no-op.

STORE and RECALL prefixes
The second step is a register number, 00 00 through 15 15. Note, registers above 15 06 are system memory and should not be used. The register 09 14 is the code for the END PROG command, and using it as a direct-target register in a program will affect program listings, recording/loading from tape, and inserting/deleting program steps.

INDIR prefix
The second step is a register command. The operation is performed on the register number that is stored in that register. If register 05 contains 158.00000000, then INDIR +05 will add the display to register 158 (which is also known as 09 14). Note, this method of accessing register 09 14 (END PROG) will not interfere with program control functions.
A special case is for codes 00 rr where 'rr' specifies a register to be used indirectly. The integer, absolute value, contents of register 'rr' is added to the Program Counter (current program step). This effectively is a variable-length jump. The value is limited to 000 through 999.

α prefix
00 00 through 03 15 Print character(s) to OutputWriter. Output stops when 02 02 is seen (not printed). Each character is prefixed by the "print mode" control character 02 08. Resulting symbols are described in table below.
NOTE: this is not a two-step command, but variable length. Code 02 02 terminates command.
04 00 through 07 15 Plot 00 00 through 03 15 on OutputWriter. The characters are prefixed by the "plotting mode" control character, 03 08, and each character by the "step control characters" needed to move the carriage based on registers 00 00 and 00 01. The integer portion of 00 00 controls movement in the Y direction, the integer portion of 00 01 controls movement in the X direction.
NOTE: this is not a two-step command, but variable length. Code 02 02 terminates command.
PRINT Turn on keyboard trace (Printer must be ON)
α Turn off keyboard trace
LOGeX Turn on program trace (Printer must be ON)
eX Turn off program trace
STOP 0.5 second pause
10 00 Value of π to display
10 xx Multiply display by 10xx
11 xx Multiply display by 10-xx
JIF0 Jump if 00 00 = display
JIF+ Jump if 00 00 >= display
SIN Jump if 00 00 < display
LOAD PROG Skip N records and load program from tape. N is integer portion of current display value.
STORE Record N+1 registers to tape. N is integer portion of current display value. Registers are recorded in reverse order, N through 00 00.
RECALL Load N+1 registers from tape. N is integer portion of current display value. Registers are loaded in reverse order, N through 00 00.

Print prefix, and PRINT inside a program
xx 00 through xx 10 Print with 0-10 decimal places
xx 11 through xx 14 print in scientific notation
-- 15 prints blank line
'xx' prints letter "tag" in column 21
00 01 02 03 04 05 06 07 08 09 10 11 12 13 14 15
X Y Z A B C D E F G H I J K L M

I/O prefix
00 00 through 09 15 Print display, formatted, to OutputWriter (device 1). First number is number of (blank-filled) integer places, second is number of decimal places. 00 xx is for scientific notation, also xx 11 through xx 15.
10 xx Jump if 00 00 = display (string compare, not numeric)
11 xx Jump if 00 00 ≠ display (string compare, not numeric)
12 xx Print field of xx blanks to OutputWriter.
13 00 through 13 07 page-in blocks of program steps from "device 2". "Source" address is in 00 00 (integer portion, 0 - 16M). In 00 01 is the starting program step number (integer portion, 0000 - 1847). Length determined by 'xx':
00010203 04050607
1 step 8 steps 16 steps 32 steps 64 steps 128 steps 256 steps 64 steps
13 08 through 13 15 page-out blocks of program steps to "device 2". "Destination" address is in 00 00 (integer portion, 0 - 16M). In 00 01 is the starting program step number (integer portion, 0000 - 1847). Length determined 'xx':
08091011 12131415
1 step 8 steps 16 steps 32 steps 64 steps 128 steps 256 steps 64 steps
14 xx same as 10 xx.
15 xx same as 11 xx.

GROUP 1 or GROUP 2 prefix
Send next code to device(s) on CN-36 port. In program, issues IOB=0, then IOB=4 (GROUP 1) or IOB=5 (GROUP 2) with data, then program stops (requires GO or PRIME to continue). Wang keyboard is locked, so GO must be generated by device. Device (and/or User) generates input codes, which are either interpreted by the running calculator (Run Mode) or placed in program memory (Learn Mode). The input stream is terminated by a GO command. Somce devices have special methods of generating the GO command, for example the TTY allows the user to type Ctrl-A to cause a GO, or the Micro-Interface generates a GO when data hase been acquired and transferred to the calculator.
Known Device Codes
GROUP 1
04 08
Run Mode Model 614 Mark-Sense Card Reader
GROUP 2
04 08
Learn Mode
GROUP 2
04 12
Run Mode Model 611 Input/Output Writer
GROUP 2
04 13
Learn Mode
GROUP 2
04 11
Learn Mode Model 622 Keyboard
GROUP 1
00 00
Run Mode Model 603 Paper-Tape Reader
GROUP 1
00 07
Skip to
Carriage-return
GROUP 1
07 xx
Run Mode Model 605 Micro-Interface ('xx' configurable)
GROUP 1
15 00
Start Paper-Tape
Run Mode
Model 607 TTY-Interface
GROUP 1
15 01 - 15 04
Print "1" (.."4")
Run Mode
GROUP 1
15 05 - 15 15
Run Mode
GROUP 2
15 00
Start Paper-Tape
Learn Mode
GROUP 2
15 01 - 15 04
Print "1" (.."4")
Learn Mode
GROUP 2
15 05 - 15 15
Learn Mode

OutputWriter (IBM Selectric) Character Codes
00 01 02 03 04 05 06 07 08 09 10 11 12 13 14 15
00 - y space back space q p = j tab / set tab clr tab , ; f g
01 w s shift dn shift up i ' . ½ return index o index rev index a r v m
02 b h step x+ step x- k e n t print mode l step y+ step y- c d u x
03 9 0 step x+y+ step x-y+ 6 5 2 z plot mode 4 step x+y- step x-y- 8 7 3 1
S
H
I
F
T
E
D
_ Y space back space Q P + J tab ? set tab clr tab , : F G
W S shift dn shift up I " . ¼ return index O index rev index A R V M
B H step x+ step x- K E N T print mode L step y+ step y- C D U X
( ) step x+y+ step x-y+ ¢ % @ Z plot mode $ step x+y- step x-y- * & # !

Flatbed Plotter Character Codes
00 01 02 03 04 05 06 07 08 09 10 11 12 13 14 15
00 - Y space / Q P + J } ? = { , : F G
01 W S pen dn pen up I ' . n/a return index? O index? rev index? A R V M
02 B H step x+ step x- K E N T print mode 1 step y+ step y- C D U X
03 9 0 step x+y+ step x-y+ 6 5 2 Z plot mode 4 step x+y- step x-y- 8 7 3 L
04 - Y space / Q P + J } ? = { , : F G
05 W S plot move I ' . n/a chr size O chr space home A R V M
06 B H step x+ step x- K E N T print mode 1 step y+ step y- C D U X
07 9 0 step x+y+ step x-y+ 6 5 2 Z plot mode 4 step x+y- step x-y- 8 7 3 L

Teletype Character Codes
00 01 02 03 04 05 06 07 08 09 10 11 12 13 14 15
00 - Y space n/a Q P = J n/a / DC2 DC4 , ; F G
01 W S shift dn shift up I ' . ! CR/LF O LF n/a A R V M
02 B H n/a n/a K E N T n/a 1 n/a n/a C D U X
03 9 0 n/a n/a 6 5 2 Z n/a 4 n/a n/a 8 7 3 L
S
H
I
F
T
E
D
n/a Y space n/a Q P + J n/a ? DC2 DC4 , : F G
W S shift dn shift up I " . n/a CR/LF O LF n/a A R V M
B H n/a n/a K E N T n/a 1 n/a n/a C D U X
( ) n/a n/a n/a % @ Z n/a $ n/a n/a * & # L

The codes highlighted red are generated by the calculator and have unknown results if embedded in an ALPHA command. The calculator indicates the X and Y delta (registers 01 and 00, respectively) by issuing an appropriate number of the step codes, and the output device effectively counts them and performs the plotting motion.

The codes highlighted green are deviations from the OutputWriter, but only affect the ways strings are created by the programmer. The calculator microcode does not generate these. Note, however, that the IBM Selectic "Shift Up" and "Shift Down" codes have conflicting meanings with the Flatbed Plotter. Software written for the OutputWriter will probably not work without modification on the Flatbed Plotter. However, the modifications are probably limited to the ALPHA - ALPHA END sequences. Note, some commands require X and Y delta values that are used as parameters, not carriage movement.

The codes highlighted blue are plotted characters, the X and Y delta values are used to move the pen to the desired position where the indicated character is drawn. Note, only the first character of a string should be marked as plotted, or else each character will be speparated from the last by the X and Y delta.

The codes highlighted gray indicate deviation from the normal shifted mode of the character but are otherwise still aligned with the Selectric codes.

The codes highlighted yellow are unknown/undefined.

Note, the interface to the device only supports 6 bits. The above tables indicate what a programmer would put in an ALPHA - ALPHA END sequence to produce the indicated results. The device interprets the codes 0x00 through 0x3f according to state previously set up (e.g. plot mode or print mode).

Note the reversal of "1" and "L" in the Plotter/Teletype tables. The IBM Selectric considered the digit 1 to be redundant with lower-case ell. Many typeballs replaced "1" with other special characters. Because of this, the Wang microcode could not assume that it could print a "1" using the code for "1". Therefor, it uses lower case ell. In order to use the same microcode for both the Output Writer and the Plotter, the plotter's character decoding had to interpret lower case ell as "1" and use the encoding normally assigned to "1" as "L". This means that programs written for the Output Writer may not be completely compatable with the Plotter/Teletype.

"DC2" and "DC4" are ASCII control characters that cause the Teletype paper tape punch to turn on and off, respectively.