; ; PROGRAM: SLM20.Z80 ; AUTHOR: Fred Haines ; PURPOSE: This program sets the left margin on ; printers using the Diablo 1610 command ; set. ; DATE: August 30, 1986 ; This program has only one command, SLM n, where n is a ; column number from 1-255, and it sets a left margin on ; your Diablo 1610 compatible daisywheel printer in that ; column. ; ; general equates bdos equ 05h fcp equ 5dh ; fcb + 1 esc equ 1bh tab equ 09h ; ; external syslib routines ext print ext crlf ext eval10 ext lout ; ; print program banner and help screen call crlf call print db 'SLM v2.0 - usage:',0 call crlf call print db ' SLM n set left margin at',0 call crlf call print db ' column n [1-255]',0 call crlf ; ; send prefix string to printer ld a,esc call lout ld a,tab call lout ; ; get offset, convert, send to printer ld hl,fcp ; point hl at column position call eval10 ; convert to hex, result in a and e call lout ; ; set left margin ld a,esc call lout ld a,'9' call lout ret ; finished ; end