home *** CD-ROM | disk | FTP | other *** search
/ ftp.barnyard.co.uk / 2015.02.ftp.barnyard.co.uk.tar / ftp.barnyard.co.uk / cpm / walnut-creek-CDROM / CPM / MODEMS / MODEM7 / M7OD-5.ASM < prev    next >
Assembly Source File  |  2000-06-30  |  15KB  |  584 lines

  1. ; M7OD-5.ASM - Overlay for Osborne-01 with the COMM-PAC Modem 05/07/84
  2. ;             Auto-dialing supported.
  3. ;
  4. ;       This overlay will work (ONLY) with MDM740.COM
  5. ;
  6. ;=======================================================================
  7. ;
  8. ; You will want to look this file over carefully.  There are a number of
  9. ; options that can be used to configure the program to suit your taste.
  10. ;
  11. ; Use the "SET" command to change the baudrate when desired.  It starts
  12. ; out at 300 baud when the program is first called up, but remember, the
  13. ; COMM-PAC only works at 300 baud.
  14. ;
  15. ;
  16. ;    TO USE: First edit this file filling in answers for your own
  17. ;        equipment.  Then assemble with ASM.COM or equivalent
  18. ;        assembler.  Then use DDT to overlay the the results
  19. ;        of this program to the original .COM file:
  20. ;
  21. ;        A>DDT MDM740.COM
  22. ;        DDT VERS 2.2
  23. ;        NEXT  PC
  24. ;        4A00 0100
  25. ;        -IM7OD-5.HEX        (note the "I" command)
  26. ;        -R            (loads in the .HEX file)
  27. ;        NEXT  PC
  28. ;        4A00 0000
  29. ;        -G0            (return to CP/M)
  30. ;        A>SAVE 73 MDM740.COM    (or MDM.COM )
  31. ;
  32. ;        You now have a modified .COM file.
  33. ;
  34. ;=======================================================================
  35. ;Rev. 5  05/07/84 - Modified to work with MDM740.COM
  36. ;                    - Irv Hoff
  37. ;
  38. ;Rev. 4  04/06/84 - Updated to work with MDM730.COM.
  39. ;                    - John Riehl, FOG #2836
  40. ;                      Days:  1-713-644-7070
  41. ;                      Home:  1-713-488-1257
  42. ;
  43. ;Rev. 3  03/17/84 - Updated to work with MDM727A.COM.
  44. ;                    - John Riehl
  45. ;
  46. ;
  47. ;Rev. 2  02/05/84 - Updated to work with MDM720.COM  Removed routines
  48. ;            which were already in the main program and made
  49. ;            an effort to retain the Smartmodem routines.    
  50. ;                    - John Riehl
  51. ;
  52. ;Rev. 1  12/08/83 - Changed from CTL-C to CTL-V to turn on carrier
  53. ;            after using telephone dialer in the Terminal mode.
  54. ;            Changed from CTL-^ to <ESC> for "Send next character"
  55. ;            function.        - John Riehl
  56. ;
  57. ;     12/05/83 - Original derived from M712OS.ASM
  58. ;            by Irv Hoff and Paul Kelly
  59. ;                    - John Riehl    
  60. ;=======================================================================
  61. ;
  62. BDOS:        EQU    5
  63. PRINT:        EQU    9
  64. ;
  65. BELL:        EQU    07H    ;bell
  66. CR:        EQU    0DH    ;carriage return
  67. ESC:        EQU    1BH    ;escape
  68. LF:        EQU    0AH    ;linefeed
  69. ;
  70. YES:        EQU    0FFH
  71. NO:        EQU    0
  72. ;
  73. ;
  74. PORT        EQU    2A00H
  75. MODCTLP:    EQU    PORT    ;status register for RS232
  76. MODDATP:    EQU    PORT+1    ;data resister for RS232
  77. MODSNDB:    EQU    2    ;bit to test for ready to send
  78. MODSNDR:    EQU    2    ;modem send ready when high
  79. MODRCVB:    EQU    1    ;bit to test for received data
  80. MODRCVR:    EQU    1    ;modem receive ready when high
  81. MODCARB:    EQU    4    ;modem carrier on when low
  82. ;
  83. ;
  84. ;+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
  85. ;             SPECIAL EQUATES FOR COMM-PAC
  86. ;
  87. MCBON:        EQU    40H    ;mask to turn on MCB
  88. MCBOFF:        EQU    0BFH    ;mask to turn off MCB
  89. ;
  90. WAITCTS:    EQU    150    ;number of seconds (x5) to wait for the
  91.                 ;computer to answer after PMMI auto-dial
  92.                 ;100=20 sec, 150=30 sec, 255=51 sec.
  93.                 ;any number 0-255 acceptable
  94. ;
  95. ;+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
  96. ;
  97. ; Change CLOCK to match your equipment
  98. ;
  99.         ORG    100H
  100. ;
  101.         DS    3    ;(for  "JMP   START" instruction)
  102. ;
  103. PMMIMODEM:    DB    NO    ;must be NO leave this alone        103H
  104. AUTODIAL:    DB    NO    ;yes=HAYES-type autodial modem        104H
  105. TOUCHPULSE:    DB    'P'    ;T=touch, P=pulse (Smartmodem-only)    105H
  106. CLOCK:        DB    20    ;clock speed in MHz x10, 25.5 MHz max.    106H
  107.                 ;20=2 MHh, 37=3.68 MHz, 40=4 MHz, etc.
  108. MSPEED:        DB    1    ;0=110 1=300 2=450 3=600 4=710 5=1200    107H
  109.                 ;6=2400 7=4800 8=9600 9=19200 default
  110. BYTDLY:        DB    5    ;0=0 delay  1=10ms  5=50 ms - 9=90 ms    108H
  111.                 ;default time to send character in ter-
  112.                 ;minal mode file transfer for slow BBS.
  113. CRDLY:        DB    5    ;0=0 delay 1=100 ms 5=500 ms - 9=900 ms 109H
  114.                 ;default time for extra wait after CRLF
  115.                 ;in terminal mode file transfer
  116. NOOFCOL:    DB    3    ;number of DIR columns shown        10AH
  117. SETUPTST:    DB    YES    ;yes=user-added Setup routine        10BH
  118. SCRNTEST:    DB    YES    ;cursor control routine         10CH
  119. RETRY:        DB    YES    ;yes=reset the error limit to try again 10DH
  120.                 ;no=abort after 10 consecutive errors
  121. BAKUPBYTE:    DB    NO    ;yes=change any file same name to .BAK    10EH
  122. CRCDFLT:    DB    YES    ;yes=default to CRC checking        10FH
  123. TOGGLECRC:    DB    YES    ;yes=allow toggling of CRC to Checksum    110H
  124. CONVRUB:    DB    YES    ;yes=convert rub to backspace        111H
  125. TOGGLERUB:    DB    YES    ;yes=allow toggling of rub to backspace 112H
  126. ADDLF:        DB    NO    ;no=no LF after CR to send file in    113H
  127.                 ;terminal mode (added by remote echo)
  128. TOGGLELF:    DB    YES    ;yes=allow toggling of LF after CR    114H
  129. TRANLOGON:    DB    YES    ;yes=allow transmission of logon    115H
  130.                 ;write logon sequence at location LOGON
  131. NOSAVE:        DB    NO    ;DO NOT CHANGE, MUST BE 'NO' FOR OS-1    116H
  132. LOCONEXTCHR:    DB    NO    ;yes=local command if EXTCHR precedes    117H
  133.                 ;no=external command if EXTCHR precedes
  134. TOGGLELOC:    DB    YES    ;yes=allow toggling of LOCONEXTCHR    118H
  135. LSTTST:        DB    YES    ;yes=printer available on printer port    119H
  136. XOFFTST:    DB    NO    ;yes=checks for XOFF from remote while    11AH
  137.                 ;sending a file in terminal mode
  138. XONWAIT:    DB    NO    ;yes=wait for XON after CR while    11BH
  139.                 ;sending a file in terminal mode
  140. TOGXOFF:    DB    YES    ;yes=allow toggling of XOFF checking    11CH
  141. IGNORCTL:    DB    YES    ;yes=CTL-chars above ^M not displayed    11DH
  142. COMMPAC:    DB    YES    ;yes=Osborne COMM-PAC modem        11EH
  143. EXTRA2:        DB    0    ;                    11FH
  144. CARRIER:    DB    'V'-40H    ;^V = Turn on carrier            120H
  145. NOCONNCT:    DB    'N'-40H    ;^N = Disconnect from the phone line    121H
  146. LOGCHR:        DB    'L'-40H    ;^L = Send logon            122H
  147. LSTCHR:        DB    'P'-40H    ;^P = Toggle printer            123H
  148. UNSAVE:        DB    'R'-40H    ;^R = Close input text buffer        124H
  149. TRANCHR:    DB    'T'-40H    ;^T = Transmit file to remote        125H
  150. SAVECHR:    DB    'Y'-40H    ;^Y = Open input text buffer        126H
  151. EXTCHR:        DB    ESC    ;ESC= Send next character        127H
  152. ;
  153. PULSERATE:    DB    125    ;125=20pps dialing, 1=10pps
  154. CHGBAUD:    DB    'B'-40H    ;^B = Used with PMMIMODEM in terminal
  155.                 ; mode to change baud rate on fly
  156. ;
  157. IN$MODCTLP:    CALL    OSTAT    ! RET    ;get the I/O status        12AH
  158. OUT$MODCTLP:    CALL    OSET    ! RET    ;setup I/O            12EH
  159.         DS    2
  160. ;
  161. OUT$MODDATP:    CALL    OSOUT    ! RET    ;send a character to the I/O    134H
  162.         DS    6
  163. ;
  164. IN$MODDATP:    CALL    OSIN    ! RET    ;get a character from the I/O    13EH
  165.         DS    6
  166. ;
  167. ANI$MODRCVB:    ANI    MODRCVB    ! RET    ;bit to test for receive ready    148H
  168. CPI$MODRCVR:    CPI    MODRCVR    ! RET    ;value of rcv. bit when ready    14BH
  169. ANI$MODSNDB:    ANI    MODSNDB    ! RET    ;bit to test for send ready    14EH
  170. CPI$MODSNDR:    CPI    MODSNDR    ! RET    ;value of send bit when ready    151H
  171. ;
  172. IN$BAUDRP:    JMP    IN$MODCTLP    ;check modem carrier status    154H
  173. ;
  174. ;
  175. ;====================== SPECIAL PMMI PORT ==============================
  176. ;
  177. OUT$BAUDRP:    RET  !    NOP  !    NOP    ;out baudrate port
  178. ;
  179. ;================== END OF SPECIAL PMMI PORT ===========================
  180. ;
  181. ;
  182. OUT$MODCTL1:    JMP    MODCTL1        ;turn on modem carrier        15AH
  183. OUT$MODCTL2:    JMP    MODCTL2        ;re-initialize modem        15DH
  184. ;
  185. LOGONPTR:    DW    LOGON        ;for user message.        160H
  186. JMP$DIAL:    JMP    DIAL        ;                162H
  187. JMP$DISCONNT:    DS    3        ;                165H
  188. JMP$GOODBYE:    DS    3        ;                168H
  189. JMP$INITMOD:    JMP    INITMOD        ;go to user written routine    16BH
  190. JMP$NEWBAUD:    RET  !    NOP  !    NOP    ;(by-passes PMMI routine)    16EH
  191. JMP$NOPARITY:    RET  !    NOP  !    NOP    ;(by-passes PMMI routine)    171H
  192. JMP$PARITY:    RET  !    NOP  !    NOP    ;(by-passes PMMI routine)    174H
  193. JMP$SETUPR:    JMP    SETUPR        ;                177H
  194. JMP$SPCLMENU:    RET  !    NOP  !    NOP    ;(by-passes PMMI routine)    17AH
  195. JMP$SYSVER:    JMP    SYSVER        ;                17DH
  196. JMP$BREAK:    JMP    MODCTL1        ;Turn on carrier        180H
  197. ;
  198. ;
  199. ; Do not change the following six lines.
  200. ;
  201. JMP$ILPRT:    DS    3        ;                183H
  202. JMP$INBUF    DS    3        ;                186H
  203. JMP$INLNCOMP:    DS    3        ;                189H
  204. JMP$INMODEM    DS    3        ;                18CH
  205. JMP$NXTSCRN:    DS    3        ;                18FH
  206. JMP$TIMER:    DS    3        ;                192H
  207. ;
  208. CLREOS:        CALL    JMP$ILPRT    ;                195H
  209.         DB    0,0,0,0,0    ;O-1 has no clear EOS.        198H
  210.         RET            ;                19DH
  211. ;
  212. CLRSCRN:    CALL JMP$ILPRT        ;                19EH
  213.         DB    1AH,0,0,0,0    ;O-1 clear screen, home cursor    1A1H
  214.         RET            ;                1A6H
  215. ;
  216. ;
  217. ;======================= SIGN-ON MESSAGE ============================== 
  218. ;
  219. ; Send version number and date
  220. ;
  221. SYSVER:      CALL    JMP$ILPRT
  222.       DB    'Version for Osborne COMM-PAC modem',CR,LF,0
  223.       RET
  224. ;.....
  225. ;
  226. ;
  227. ;-----------------------------------------------------------------------
  228. ;
  229. ; NOTE:  You can change the SYSVER message to be longer or shorter.  The
  230. ;     end of your last routine should terminate by address 0C00H
  231. ;
  232. ;-----------------------------------------------------------------------
  233. ;
  234. ; You can put in a message at this location which can be called up with
  235. ; CTL-O if TRANLOGON has been set TRUE.  You can put in several lines if
  236. ; desired.  End with a 0.
  237. ;
  238. LOGON:      DB    'Your 3 minutes is up, deposit 25 cents',CR,LF,0
  239. ;.....
  240. ;
  241. ;
  242. ACIACTLB: DB    56H    ;ACIA control byte
  243. ;.....
  244. ;
  245. ;
  246. ; This is the Osborne initialization routine.
  247. ;    
  248. INITMOD:  LDA    FINITFLG    ;flag set yet?
  249.       ORA    A
  250.       RNZ            ;if yes, already been this way once
  251.       INR    A        ;otherwise set flag..
  252.       STA    FINITFLG    ;..and initialize this routine
  253.       LHLD    BDOS+1        ;find start of bdos
  254.       LXI    D,-0100H    ;go to first page ahead of BDOS
  255.       DAD    D        ;HL now positioned one page below BDOS
  256.       PUSH    H        ;save the address
  257.       LXI    D,BDJ        ;point to our routine to put there
  258.       LXI    B,CDLEN+2    ;set length of code
  259.       XCHG
  260.       DB    0EDH,0B0H    ;Z80 LDIR
  261.       LHLD    BDOS+1        ;get BDOS address back once more
  262.       POP    D        ;get the starting address off stack
  263.       PUSH    D        ;put it back on the stack
  264.       INX    D        ;point to address position
  265.       XCHG            ;put into 'HL'
  266.       MOV    M,E        ;store 'LSP' address
  267.       INX    H        ;get 'LSP' location
  268.       MOV    M,D        ;store 'MSP' address
  269.       POP    H        ;get the address back once more
  270.       SHLD    BDOS+1        ;new address to protect for overwrite
  271.       LXI    D,OSIN-BDJ    ;get the length of routine to move
  272.       DAD    D        ;compute address of the 'OSIN' routine
  273.       SHLD    IN$MODDATP+1    ;patch call for "get char." routine
  274.       LXI    D,OSOUT-OSIN
  275.       DAD    D
  276.       SHLD    OUT$MODDATP+1    ;patch call for "send char." routine
  277.       LXI    D,OSTAT-OSOUT
  278.       DAD    D
  279.       SHLD    IN$MODCTLP+1    ;patch call for "get status" routine
  280.       LXI    D,OSET-OSTAT
  281.       DAD    D
  282.       SHLD    OUT$MODCTLP+1    ;patch jmp for "send ACIA ctl" routine
  283. ;
  284.       MVI    A,1        ;MSPEED 300 bps value
  285.       STA    MSPEED
  286. ;
  287. ;
  288. ; Set the initial baud rate to 300
  289. ;
  290.       MVI    A,56H        ;for 300 bps
  291. SETUPR1:  STA    ACIACTLB
  292. ;
  293. MODCTL2:  PUSH    B
  294.       MVI    C,3
  295. ;
  296. CNT:      MVI    B,6BH
  297.       LDA    ACIACTLB
  298.       ORI    MCBON
  299.       CALL    SETBAUD
  300.       CALL    DELAY
  301.       MVI    B,6BH
  302.       LDA    ACIACTLB
  303.       ANI    MCBOFF
  304.       CALL    SETBAUD
  305.       CALL    DELAY
  306.       DCR    C
  307.       JNZ    CNT
  308.       MVI    B,6BH
  309.       LDA    ACIACTLB
  310.       ORI    MCBON
  311.       CALL    SETBAUD
  312.       CALL    DELAY
  313.       MVI    B,6BH
  314.       MVI    A,3
  315.       CALL    SETBAUD
  316.       CALL    DELAY
  317.       LDA    ACIACTLB
  318.       ORI    MCBON
  319.       CALL    SETBAUD
  320.       POP    B
  321.       RET
  322. ;...
  323. ;
  324. ;
  325. SETBAUD:  PUSH    H
  326.       CALL    OUT$MODCTLP
  327.       POP    H
  328.       XRA    A        ;clear carry
  329.       RET
  330. ;.....
  331. ;
  332. ;
  333. ; change the baud rate with the set command
  334. ;
  335. SETUPR:      PUSH    H
  336. ;
  337. AGAIN:      LXI    D,BAUDBUF    ;point to input buffer
  338.       CALL    JMP$ILPRT
  339.       DB    'Input Baud Rate (300, 1200): ',0
  340.       CALL    JMP$INBUF
  341.       LXI    D,BAUDBUF+2
  342.       CALL    JMP$INLNCOMP    ;compare BAUDBUF+2 with characters below
  343.       DB    '300',0
  344.       MVI    A,1        ;mspeed 300 baud
  345.       STA    MSPEED
  346.       MVI    A,56H        ;Osborne 300 BPS
  347.       JNC    OK        ;go if got match
  348. ;
  349.       CALL    JMP$INLNCOMP
  350.       DB    '1200',0
  351.       MVI    A,5        ;MSPEED 1200 bps
  352.       STA    MSPEED
  353.       MVI    A,55H        ;Osborne 1200 baud
  354.       JNC    OK
  355.       CALL    JMP$ILPRT    ;all matches failed - tell operator
  356.       DB    '++ Incorrect entry ++',CR,LF,BELL,0
  357.       JMP    AGAIN        ;try again
  358. ;...
  359. ;
  360. ;
  361. OK:      POP    H
  362.       JMP    SETUPR1
  363. ;.....
  364. ;
  365. ;
  366. MODCTL0:  LDA    ACIACTLB
  367.       ORI    MCBON
  368.       CALL    SETBAUD
  369.       CALL    BIGDELAY
  370. ;.....
  371. ;
  372. ;
  373. MODCTL1:  LDA    ACIACTLB
  374.       ANI    MCBOFF
  375.       CALL    SETBAUD
  376.       RET
  377. ;.....
  378. ;
  379. ;
  380. DELAY:      DCR    B
  381.       JNZ    DELAY
  382.       RET
  383. ;.....
  384. ;
  385. ;
  386. BIGDELAY1:MOV    B,A
  387.       CALL    DELAY
  388.       DCR    C
  389.       JNZ    BIGDELAY1
  390.       RET
  391. ;
  392. BIGDELAY: PUSH    PSW
  393.       PUSH    B
  394.       MVI    B,40
  395.       MVI    C,0
  396.       MOV    A,B
  397.       CALL    BIGDELAY1
  398.       POP    B
  399.       POP    PSW
  400.       RET
  401. ;.....
  402. ;
  403. ;
  404. BAUDBUF:  DB    10,0
  405.       DS    10
  406. ;
  407. FINITFLG: DB    0
  408. ;.....
  409. ;
  410. ;
  411. ; Routines that get placed just under 'BDOS' overlaying 'CCP'
  412. ;
  413. BDJ:    JMP    $-$        ;this gets patched to jump to BDOS entry
  414. ;
  415. OSIN:    DI            ;disable interrupts
  416.     OUT    0        ;switch to alternate page
  417.     LDA    MODDATP        ;get data byte
  418.     OUT    1        ;switch pages back
  419.     EI            ;enable interrupts
  420.     RET
  421. ;.....
  422. ;
  423. ;
  424. OSOUT:    DI            ;disable interrupts
  425.     OUT    0        ;switch to alternate page
  426.     STA    MODDATP        ;send data byte
  427.     OUT    1        ;switch pages back
  428.     EI            ;enable interrupts
  429.     RET
  430. ;.....
  431. ;
  432. ;
  433. OSTAT:    DI            ;disable interrupts
  434.     OUT    0        ;switch to alternate page
  435.     LDA    MODCTLP        ;get status byte
  436.     OUT    1        ;switch pages back
  437.     EI            ;enable interrupts
  438.     RET
  439. ;.....
  440. ;
  441. ;
  442. OSET:    DI
  443.     OUT    0
  444.     STA    MODCTLP
  445.     OUT    1
  446.     EI
  447.     RET
  448. ;.....
  449. ;
  450. CDLEN:    EQU    $-BDJ        ;length of code to copy
  451. ;
  452. ;
  453. ;=======================================================================
  454. ;
  455. ;            COMM-Pac dialing routines
  456. ;
  457. ;=======================================================================
  458. ;
  459. ; Changes to dialing routines
  460. ;
  461.      ORG    0400H
  462. DIAL:    LDA    COMMPAC
  463. ;.....
  464. ;
  465. ;
  466. ; Change to DIAL19
  467. ;
  468.      ORG    05F7H
  469.     DB    0,0,0,0,0
  470. ;.....
  471. ;
  472. ;
  473. ; Change to DIALAGN
  474. ;
  475.      ORG    0633H
  476.     DB    'N): ',BELL,0,7CH,7CH
  477. ;.....
  478. ;
  479. ;
  480. ; Sends the digit to the modem and converts it to the correct number of
  481. ; pulses.  Waits 200 ms. after each digit dialed.
  482. ;
  483.      ORG    071BH
  484. DIALA4:    PUSH    B
  485.     CALL    MODCTL0
  486.     CALL    BIGDELAY
  487.     POP    B
  488.     DCR    C
  489.     JNZ    DIALA4
  490.     MVI    B,2
  491.     JMP    JMP$TIMER
  492. ;.....
  493. ;
  494. ;
  495. ; Disconnect from the line, reconnect and wait for the dialtone.
  496. ;
  497.      ORG    07A4H
  498.     CALL    DISCON0
  499.     MVI    B,2        
  500.     CALL    JMP$TIMER
  501.     CALL    OUT$MODCTL1
  502.     MVI    D,MODCARB
  503.     MVI    C,10
  504.     JMP    WAIT
  505. ;.....
  506. ;
  507. ;
  508. ; Change to DISCONNT:
  509. ;
  510.      ORG    0824H
  511. DISCON0:XRA    A
  512.     DB    0,0,0
  513. ;.....
  514. ;
  515. ;
  516. ; Smartmodem SPKRFLG:
  517. ;
  518.      ORG    089AH
  519.     DB    0FFH
  520. ;.....
  521. ;
  522. ;
  523. ; Changes to RINGBK:
  524. ;
  525.      ORG    0994H
  526.     DB    MODCARB        ;carrier detect mask
  527. ;.....
  528. ;
  529. ;    
  530. ; Change to HANGUP:
  531. ;
  532.      ORG    0A16H
  533.     RET
  534. ;.....
  535. ;
  536. ;
  537. WAIT:    EQU    0A51H
  538. ;
  539. ;=======================================================================
  540. ;
  541.      ORG    0E00H-2
  542. HEXSHOW:DB    NO        ;show hex length
  543. SAVSIZ:    DB    20H        ;buffer size = 4k
  544. ;.....
  545. ;
  546. ;
  547.      ORG    1426H
  548.     DW    COMMPAC        ;enable 'C' option in command line
  549. ;.....
  550. ;
  551. ;
  552.      ORG    152CH
  553.     DW    COMMPAC        ;accept 'C' option
  554. ;
  555.      ORG    20B2H
  556.     DB    0C3H        ;changes JZ to JMP
  557. ;.....
  558. ;
  559. ;
  560.      ORG    39A5H
  561.     DW    COMMPAC        ;disable 'NUM" desription in menu
  562. ;
  563.      ORG    3A1CH
  564.     DW    COMMPAC        ;enable 'CAL' description in menu
  565. ;.....
  566. ;
  567. ;
  568.      ORG    3B37H
  569.     DB    '  - Turn on MODEM carrier        ',CR,LF,0
  570. ;.....
  571. ;
  572. ;
  573.      ORG    3EF3H
  574.     DW    COMMPAC        ;disable 'NUM' in command mode
  575. ;.....
  576. ;
  577. ;
  578.      ORG    3F44H
  579.     DW    COMMPAC        ;enable 'CAL' in command mode
  580. ;.....
  581. ;
  582. ;
  583.     END
  584.