PDP-1 COMPUTER ELECTRICAL ENGINEERING DEPARTMENT MASSACHUSETTS INSTITUTE OF TECHNOLOGY CAMBRIDGE, MASSACHUSETTS 02139 PDP-22 EXPENSIVE TYPEWRITER August 1, 1972 >>13<>13<>40<<. / (slash) . (period) " (double quote) ' (single quote) >>20<< (right arrow) >>04<< (imply) [these characters are explained later]. The search commands, >>56<>56<<, >>40<>56<<, <, and > [explained later] may also be used as numeric arguments before certain commands. The argument may be an expression made up of search commands, decimal integers or the characters, separated by space or + to add, or - to subtract. Arguments typed together with no separator will be added, unless they are both numbers. Certain commands may take two arguments>>40<<, these appear before command letter, separated from each other by a comma. Comments may be typed at any time in the control mode. A comment is initiated by a left (open) parenthesis, and ended by the first matching right (close) parenthesis. The material within the parentheses is completely ignored. The buffer is intended to hold an arbitrary amount of typescript, divided into pages, with each page organized as a list of lines. Each line has an address within its page which is a decimal number. The third line on a page, for example, is called line 3 when examining that page, and cannot be reached when examining any other page. Use of search commands and the character period make it unnecessary, in most cases, to be concerned with actual line numbers. There does not need to be anything typed on a line>>40<<, each carriage return ends a line. All lines in the buffer must end with a carriage return. >>13<>04<< (imply) Has the value of the number of the current page. >>20<< (right arrow) Has the value of the number of pages in the buffer, i.e., the number of the last page. " (double quote) Has the value of the number of characters from the beginning of the line at which the most recent search command found a match to the first character of the match. ' (single quote) Has the value of the number of characters from the beginning of the line at which the last search command found a match to the last character of the match. In the following examples, the letters m and n preceding the commands are used to signify numeric expressions used as argu- ments. ne (equals) The letter e , or equivalently = , causes the value of the numeric expression n to be typed out as a decimal integer. >>13<>40<<, however parity is ignored if Sense Switch 6 is on. Regardless of parity checking, deleted characters, those with the 7th hole punched, are ignored. The expected format for tapes is to have a stop code, octal code 13, on the tape at the end of each page. The r command stops reading and returns control to the typewriter upon encountering the end of the tape. If there is no stop code on the end of the tape, one will be supplied. If the buffer is empty, i.e., contains one page with zero lines, at the time the command is given, that page will be deleted first. nr (read) Read n pages of text into the buffer. >>13<>40<<. has the same effect as .-1l. nL (lines) This sets the maximum number of lines that will be printed or punched on any page. If n is 0 or absent, there is no limit on the number of lines that may be printed or punched on a page. The parameter set by L initially has the value 60. >>13<<>>35<< nS (size) This sets the total length of the page in lines. This length is effective only if the last L command had a non-zero argument. The parameter set by S initially has the value 66. The parameter set by L must be at least as large as the parameters set by S. If an S or L command is given which violates this condition, the command is executed and then the other parameter is adjusted to make the above condition true. Note>>40<<. Printout can be terminated at any point by turning on Sense Switch 1. >>13<<>>12<< Punching Paper Tape P (punch) The entire buffer is punched on tape with correct parity. The buffer is not modified in any way by this operation. A stop code is punched after each page. The first non-blank line is title punched unless Sense Switch 6 is up. nt (punch) Starting with this page, n pages are successively punched with correct parity. A stop code is punched after each page. T (title punch) All characters up to the next carriage return are punched in "readable" format. The delete hole is punched so that the title will be ignored when the tape is read back in. nf (feed) This feeds n characters of blank tape. If n is larger than 256, only 256 lines are fed. x (dismiss) The punch assignment, if any, is dismissed. Note>>40<<. Punching can be terminated at any time by turning on Sense Switch 1. Page Control n (next) The next page becomes current. mn (next) Move m pages forward in the buffer. j (jump) The first page in the buffer becomes current. nj (jump) Page n becomes the current page. o (combine) This page is combined with the following one. no (combine) This page is combined with the following n pages. nv (divide) A stop code is inserted before line n , thereby dividing the current page into two pages. The first of these becomes the current page. >>13<>56<>56<< (search limited) Search for S ,where S is an arbitrary string of characters not containing the break character (normally >>56<< (overbar)) on the current page. n>>56<>56<< (search limited) Search for S on current page beginning at line n . >>40<>56<< (search unlimited) The entire buffer will be searched for the string S. The page and line where the string is found become current. n>>40<>56<< (search unlimited) Search the entire buffer beginning at line n of the current page. n< (continue search) The above search commands store the string S in a special buffer. The command n< continues the search for that string on the current page, starting on line n of the current page. The special buffer is destroyed by the same commands which destroy the special buffer for command "u" (q.v.). < Same as .+1<. n> and > Similar to n< and <, but the entire buffer is searched. On all search commands>>40<<. The line where the match is found immediately becomes the current line. The entire search command is then treated as if the current line number had been typed in its place, and may be used in numeric expressions. The string must be preceded by an >>56<< (overbar) for a limited search or an >>40<< (underbar) for an unlimited search. The number of characters from the beginning of the line to the beginning of the match is made the value of " (double quote). The number of characters from the beginning of the line to the end of the match, even if it is on another line, is made the value of ' (single quote). For example if the fifth line of the current page is abc, lac xyz typing >>56<>56<<= will cause ET to set the current line to 5 set the value of " to 9, set the value of ' to 12, and type 5. Typing >>56<>56<>13<<>>53<< B (break) To facilitate searching for strings containing an >>56<< (overbar), the break character can be changed by typing B followed by the new break character. ? (question mark) Print the current break character. Note>>40<<. The search may be terminated at the end of the current page by turning up Sense Switch 1. >>13<<>>14<< Miscellaneous Commands nu (put) This stores line n in a special buffer, which is changed constructively only by u and searches, and is destroyed by commands A, a, c, d, i, r, v, >>56<< , and >>40<< . m,nu (put) Puts lines m through n into the special buffer. ng (get) This inserts the special buffer mentioned above before line n in a manner similiar to the command i. m,nqS>>56<< (change) The m through n characters after the beginning of the current line are replaced by the character string S that is typed in. The string is terminated by the break character, not by backspace. The string S may contain carriage returns and the string that it replaces may contain carriage returns. If fewer than two arguments are given, the missing ones will be taken as zero, so that nq (one argument) will change the first n characters on the current line, and q (no arguments) will insert its following string at the beginning of the current line. For example, 2qfoo>>56<< changes the first 2 characters of the current line to foo. qbarf>>56<< inserts the word barf at the beginning of the current line. zS>>56<< (change) The string in the position found during the last search and on the current line, is changed to the string S. This is equivalent to ",'qS>>56<< . For example, >>56<>56<>56<< changes the first foo on the current page to bar. X (exchange) The user can have two text buffers, the main one occupying drum fields 2, 3, etc., and an auxiliary one occupying fields 7, 10, etc. All editing commands refer to the main text buffer. The command X physically exchanges the two text buffers, so that what was the auxiliary buffer becomes the main buffer occupying fields 2, 3, etc., and vice versa. If no auxiliary buffer exists, an empty one is created. E Load a new copy of ET. All parameters are reset to their initial values. The text buffer is unchanged. Q Invert the state of line number printing. Line numbers are normally not printed. >>13<<6 Transfer Commands nF (file) Causes the FILE SYSTEM on DECTAPE transport n to be loaded and started (see memo PDP-42). This command can also be used to call the FORTRAN compiler from tape transport n. N (Nightmare) Transfers control to the Nightmare version of the assembler CERTAINLY, which gets the source program directly from ET's text buffer. The resulting binary program is placed on drum field 1, the program is brought into the users core memory, ID is provided with the symbol table and control is returned to ID, where a P (proceed) command will start the newly assembled program running. M (Merged assembly) Transfer control to the merging version of CERTAINLY. CERTAINLY will listen for typed commands. (For a description of these commands, see memo PDP-45, CERTAINLY). C (Calculate, compile, or whatever) Transfers control to location 102 of whatever program the user has stored on drum field 15. This command is the same as the command 13C. nC Transfers control to location 102 of the program stored on drum field n. Note that n, like any other number typed to ET, is taken as decimal, as opposed to the usual octal convention for numbering drum fields. b (back) This causes control to be returned to ID. >>13<<>>13<< Iteration n[ (iterate) ET starts saving all characters that are typed. While this is happening, commands are executed normally. ] (end of iteration range) This command is only valid if preceeded by the [ (open bracket) command. When this command is typed, ET repeats the commands typed since the preceding [ n-1 times. If n is absent, it is assumed to be 262144. The occurrence of any error will cause iteration to be stopped. Iteration may also be stopped at any time by raising Sense Switch 1. For example, [>>40<>56<>56<>13<< SUMMARY OF COMMANDS TO EXPENSIVE TYPEWRITER a append to end of current page A append on new page at end of text b back to ID B set break character to immediately following character nc change line n to typed text m,nc change lines m through n to typed text nC start user program nd delete line n m,nd delete lines m through n ne type value of n (decimal) E get a fresh copy of ET nf feed n lines of paper tape nF enter file system on tape n ng get special buffer and insert before line n ni insert typed text before line n nI execute last [command] j jump to page 1 nj jump to page n k kill this page nk kill n pages beginning with this one K kill entire buffer nl print line n m,nl print lines m through n nL set lines per page M merged assembly n next page nn jump forward n pages N clear field 1, then assemble o combine this page with next no combine this page with next n pages P punch everything m,nq change characters m to n of current line to typed text Q invert state of printing line numbers r read entire paper tape nr read n pages from paper tape nS set total page size t punch this page nt punch n pages, beginning with this one T title punch following line nu put line n into special buffer m,nu put lines m through n into special buffer nv divide page before line n w print current page nw print n pages, beginning with this one W print everything x dismiss punch X exchange text buffers z replace characters in last search with typed text (same as ",'q) >>13<<2 ^ print preceding line backspace text mode - delete last character, or, if at left margin, return to control mode control mode - print next line n[ start of iteration range ] end of iteration range, begin iteration >>56<>56<< search for S on current page n>>56<>56<< search for S on current page, beginning at line n >>40<>56<< search for S in entire buffer n>>40<>56<< search for S in entire buffer, beginning at line n of current page < Continue search on current page > Continue search in entire buffer >>40<< (centerdot) cancel command / number of last line on page . number of last line typed (current line) >>20<< number of last page >>04<< number of current page " number of first character of match in last search ' number of last character of match + 1 space add + add - subtract n= print value of n (decimal) ( begin a comment ) end a comment tab or c.r. terminate and execute lower case command ? print break character SS1 stop printout, punchout, searching, or iteration SS3 cause backspace to be quoted in text mode SS6 suppress parity check when reading paper tape t