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 / M7FT-1.ASM < prev    next >
Assembly Source File  |  2000-06-30  |  9KB  |  246 lines

  1.  
  2. ; M7FT-1.ASM -- Facit DTC 6500 overlay file for MDM7xx.  02/17/85
  3. ;
  4. ; This overlay adapts the MDM7xx program to the Facit DTC 6500 computers
  5. ; with the Z80A SIO/2 chip for the serial port called channel "B".
  6. ; You will want to look this file over carefully. There are a number of
  7. ; options that you can use to configure the program to suit your taste.
  8. ; This file places particular emphasis on using an external modem that
  9. ; does not match one of the other special overlays.  You would use the
  10. ; Facit CP/M "INIT.COM"" program to set port "B" to whatever baud rate
  11. ; you would normally use (such as 300 or 1200, etc.)  Then perhaps just
  12. ; make a second .COM file if you need both 300 and 1200 and do not wish
  13. ; to write your own initialization or "set baud" routine.  For instance,
  14. ; you would say "A>INIT B:VSA30A60.2" to set 300 baud or "A>INIT B:
  15. ; VSA30B60.4" to set 1200 baud or "VSA30A60.5" for 2400 baud.
  16. ;
  17. ; You could look at other overlay files to see how the GOODBYE and/or
  18. ; SETUPR areas are handled.  You could then adapt one of those, if ap-
  19. ; propriate for your equipment in this overlay.  Some examples:
  20. ;
  21. ;     "XE"  Xerox 820II overlay for Z80-SIO intialization, etc.
  22. ;     "AMPRO" Ampro Little Board for Z80 work, etc.
  23.  
  24. ; Edit this file for your preferences then follow the "TO USE:" example
  25. ; shown below.
  26. ;
  27. ;    TO USE: First edit this file filling in answers for your own
  28. ;        equipment.  Then assemble with ASM.COM or equivalent
  29. ;        assembler.  Then use DDT to overlay the the results
  30. ;        of this program to the original .COM file:
  31. ;
  32. ;        A>DDT MDM7xx.COM (or .BIN)
  33. ;        DDT VERS 2.2
  34. ;        NEXT  PC
  35. ;        4A00 0100
  36. ;        -IM7FT-1.HEX        (note the "I" command)
  37. ;        -R            ("R" loads in the .HEX file)
  38. ;        NEXT  PC
  39. ;        4A00 0000
  40. ;        -G0            (return to CP/M)
  41. ;        A>SAVE 74 MDM7xx.COM    (now have a modified .COM file)
  42. ;
  43. ; =   =   =   =   =   =   =   =   =   =   =   =   =   =   =   =   =   =
  44. ;
  45. ; 02/17/85 - Modified for Facit DTC 6500 - Harlan Gustafson
  46. ; 11/11/83 - Renamed to M7GP-1.ASM, no changes    - Irv Hoff
  47. ; 07/27/83 - Renamed to work with MDM712    - Irv Hoff
  48. ; 07/01/83 - Revised to work with MDM711    - Irv Hoff
  49. ; 07/01/83 - Revised to work with MDM710    - Irv Hoff
  50. ; 05/27/83 - Updated to work with MDM709    - Irv Hoff
  51. ; 05/15/83 - Revised to work with MDM708    - Irv Hoff
  52. ; 04/11/83 - Updated to work with MDM707    - Irv Hoff
  53. ; 04/04/83 - First version of this file        - Irv Hoff
  54. ;
  55. ; =   =   =   =   =   =   =   =   =   =   =   =   =   =   =   =   =
  56. ;
  57. BELL:        EQU    07H        ;bell
  58. CR:        EQU    0DH        ;carriage return
  59. ESC:        EQU    1BH        ;escape
  60. LF:        EQU    0AH        ;linefeed
  61. ;
  62. YES:        EQU    0FFH
  63. NO:        EQU    0
  64. ;
  65. ;
  66. ; Change the following information to match your equipment
  67. ;
  68. MODCTL1:    EQU    41H        ;MODEM CONTROL PORT
  69. MODCTL2:    EQU    41H        ;MODEM STATUS PORT
  70. MODDATP:    EQU    40H        ;MODEM DATA PORT
  71. MODRCVB:    EQU    1        ;BIT TO TEST FOR RECEIVE
  72. MODRCVR:    EQU    1        ;VALUE WHEN READY
  73. MODSNDB:    EQU    4        ;BIT TO TEST FOR SEND
  74. MODSNDR:    EQU    4        ;VALUE WHEN READY
  75. ;
  76.         ORG    100H
  77. ;
  78. ;
  79. ; Change the clock speed to suit your system
  80. ;
  81.         DS    3    ;(for  "JMP   START" instruction)
  82. ;
  83. PMMIMODEM:    DB    NO    ;yes=PMMI S-100 Modem            103H
  84. SMARTMODEM:    DB    YES    ;yes=HAYES Smartmodem, no=non-PMMI    104H
  85. TOUCHPULSE:    DB    'P'    ;T=touch, P=pulse (Smartmodem-only)    105H
  86. CLOCK:        DB    40    ;clock speed in MHz x10, 25.5 MHz max.    106H
  87.                 ;20=2 MHh, 37=3.68 MHz, 40=4 MHz, etc.
  88. MSPEED:        DB    1    ;0=110 1=300 2=450 3=600 4=710 5=1200    107H
  89.                 ;6=2400 7=4800 8=9600 9=19200 default
  90. BYTDLY:        DB    0    ;0=0 delay  1=10ms  5=50 ms - 9=90 ms    108H
  91.                 ;default time to send character in ter-
  92.                 ;minal mode file transfer for slow BBS.
  93. CRDLY:        DB    0    ;0=0 delay 1=100 ms 5=500 ms - 9=900 ms 109H
  94.                 ;default time for extra wait after CRLF
  95.                 ;in terminal mode file transfer
  96. NOOFCOL:    DB    5    ;number of DIR columns shown        10AH
  97. SETUPTST:    DB    NO    ;yes=user-added Setup routine        10BH
  98. SCRNTEST:    DB    NO    ;Cursor control routine         10CH
  99. ACKNAK:        DB    YES    ;yes=resend a record after any non-ACK    10DH
  100.                 ;no=resend a record after a valid-NAK
  101. BAKUPBYTE:    DB    YES    ;yes=change any file same name to .BAK    10EH
  102. CRCDFLT:    DB    YES    ;yes=default to CRC checking        10FH
  103. TOGGLECRC:    DB    YES    ;yes=allow toggling of CRC to Checksum    110H
  104. CONVBKSP:    DB    YES    ;yes=convert backspace to rub        111H
  105. TOGGLEBK:    DB    YES    ;yes=allow toggling of bksp to rub    112H
  106. ADDLF:        DB    NO    ;no=no LF after CR to send file in    113H
  107.                 ;terminal mode (added by remote echo)
  108. TOGGLELF:    DB    YES    ;yes=allow toggling of LF after CR    114H
  109. TRANLOGON:    DB    YES    ;yes=allow transmission of logon    115H
  110.                 ;write logon sequence at location LOGON
  111. SAVCCP:        DB    YES    ;yes=do not overwrite CCP        116H
  112. LOCONEXTCHR:    DB    NO    ;yes=local command if EXTCHR precedes    117H
  113.                 ;no=external command if EXTCHR precedes
  114. TOGGLELOC:    DB    YES    ;yes=allow toggling of LOCONEXTCHR    118H
  115. LSTTST:        DB    YES    ;yes=printer available on printer port    119H
  116. XOFFTST:    DB    YES    ;yes=checks for XOFF from remote while    11AH
  117.                 ;sending a file in terminal mode
  118. XONWAIT:    DB    YES    ;yes=wait for XON after CR while    11BH
  119.                 ;sending a file in terminal mode
  120. TOGXOFF:    DB    YES    ;yes=allow toggling of XOFF checking    11CH
  121. IGNORCTL:    DB    YES    ;yes=CTL-chars above ^M not displayed    11DH
  122. EXTRA1:        DB    0    ;for future expansion            11EH
  123. EXTRA2:        DB    0    ;for future expansion            11FH
  124. BRKCHR:        DB    '@'-40H    ;^@ = Send 300 ms. break tone        120H
  125. NOCONNCT:    DB    'N'-40H    ;^N = Disconnect from the phone line    121H
  126. LOGCHR:        DB    'L'-40H    ;^L = Send logon            122H
  127. LSTCHR:        DB    'P'-40H    ;^P = Toggle printer            123H
  128. UNSAVE:        DB    'R'-40H    ;^R = Close input text buffer        124H
  129. TRANCHR:    DB    'T'-40H ;^T = Transmit file to remote        125H
  130. SAVECHR:    DB    'Y'-40H    ;^Y = Open input text buffer        126H
  131. EXTCHR:        DB    '^'-40H    ;^^ = Send next character        127H
  132. ;
  133. ;
  134.         DS    2        ;                128H
  135. ;
  136. IN$MODCTL1:    IN    MODCTL1 ! RET    ;in modem control port        12AH
  137.         DS    7
  138. OUT$MODDATP:    OUT    MODDATP ! RET    ;out modem data port        134H
  139.         DS    7
  140. IN$MODDATP:    IN    MODDATP ! RET    ;in modem data port        13EH
  141.         DS    7
  142. ANI$MODRCVB:    ANI    MODRCVB    ! RET    ;bit to test for receive ready    148H
  143. CPI$MODRCVR:    CPI    MODRCVR    ! RET    ;value of rcv. bit when ready    14BH
  144. ANI$MODSNDB:    ANI    MODSNDB    ! RET    ;bit to test for send ready    14EH
  145. CPI$MODSNDR:    CPI    MODSNDR    ! RET    ;value of send bit when ready    151H
  146.         DS    12        ;                154H
  147. ;
  148. ;
  149. LOGONPTR:    DW    LOGON        ;for user message.        160H
  150.         DS    6        ;                162H
  151. JMP$GOODBYE:    JMP    GOODBYE        ;                168H
  152. JMP$INITMOD:    JMP    INITMOD        ;go to user written routine    16BH
  153.         RET  !    NOP  !    NOP    ;(by-passes PMMI routine)    16EH
  154.         RET  !    NOP  !    NOP    ;(by-passes PMMI routine)    171H
  155.         RET  !    NOP  !    NOP    ;(by-passes PMMI routine)    174H
  156. JMP$SETUPR:    JMP    SETUPR        ;                177H
  157. JMP$SPCLMENU:    JMP    SPCLMENU    ;                17AH
  158. JMP$SYSVER:    JMP    SYSVER        ;                17DH
  159. JMP$BREAK:    JMP    SENDBRK        ;                180H
  160. ;
  161. ;
  162. ; Do not change the following six lines.
  163. ;
  164. JMP$ILPRT:    DS    3        ;                183H
  165. JMP$INBUF:    DS    3        ;                186H
  166. JMP$INLNCOMP:    DS    3        ;                189H
  167. JMP$INMODEM:    DS    3        ;                18CH
  168. JMP$NXTSCRN:    DS    3        ;                18FH
  169. JMP$TIMER:    DS    3        ;                192H
  170. ;
  171. ;
  172. ; Routine to clear to end of screen.  If using CLREOS and CLRSCRN, set
  173. ; SCRNTEST to YES at 010AH (above).
  174. ;
  175. CLREOS:        CALL    JMP$ILPRT    ;                195H
  176.         DB    0,0,0,0,0    ;                198H
  177.         RET            ;                19DH
  178. ;
  179. CLRSCRN:    CALL    JMP$ILPRT    ;                19EH
  180.         DB    0,0,0,0,0    ;                1A1H
  181.         RET            ;                1A6H
  182.     
  183. ;
  184. SYSVER:        CALL    JMP$ILPRT    ;                1A7H
  185.         DB    'Version for Facit DTC w/preset baud'
  186.         DB    CR,LF
  187.         DB    'Modified by Harlan Gustafson (c)1985'
  188.         DB    CR,LF,0
  189.         RET
  190. ;.....
  191. ;
  192. ;
  193. ;-----------------------------------------------------------------------
  194. ;
  195. ; NOTE:  You can change the SYSVER message to be longer or shorter.  The
  196. ;     end of your last routine should terminate by 0400H (601 bytes
  197. ;     available after start of SYSVER) if using the Hayes Smartmodem
  198. ;     or by address 0C00H (2659 bytes) otherwise.
  199. ;
  200. ;-----------------------------------------------------------------------
  201. ;
  202. ; You can put in a message at this location which can be called up with
  203. ; CTL-L if TRANLOGON has been set TRUE.  You can use several lines if
  204. ; desired.  End with a 0.
  205. ;
  206. LOGON:        DB    'B-HG5',CR,LF,0
  207. ;.....
  208. ;
  209. ;
  210. ; Add your own routine here to send a break tone to reset some time-share
  211. ; computers, if desired.
  212. ;
  213. SENDBRK:    RET
  214. ;.....
  215. ;
  216. ;
  217. ; Add your own routine here to put DTR low and/or send a break tone.
  218. ; Check other routines such as MDM709DP.ASM which is using this feature.
  219. ;
  220. GOODBYE:    RET
  221. ;.....
  222. ;
  223. ;
  224. ; You can use this area for any special initialization or setup you may
  225. ; wish to include.  Each must stop with a RET.    You can check the other
  226. ; available overlays for ideas how to write your own routines if that
  227. ; may be of some help.
  228. ;
  229. INITMOD:  RET
  230. ;
  231. SETUPR:      RET
  232. ;
  233. ;
  234. ; If using the Hayes Smartmodem this is unavailable without a special
  235. ; change.
  236. ;
  237. SPCLMENU:  RET
  238. ;
  239. ;
  240. ; NOTE:  MUST TERMINATE PRIOR TO 0400H (with Smartmodem)
  241. ;                 0C00H (without Smartmodem)
  242. ;.....
  243. ;
  244.       END
  245. ;
  246.