TITL PTDOS XMODEM DRIVER VERS.1.02 BY Martin Eberhard ******************************************************* * COMBINED SOURCE CODE FOR XMODEM AND TXTMODEM * WITH SWITCHES SET FOR XMODEM * * XMODEM: XMODEM DEVICE DRIVER FOR PTDOS * (Assemble with XMODM = TRUE) * Send/receive serial port data using XMODEM protocol. * * By MARTIN EBERHARD * Supports both checksum and CRC error checking. * Written to be assembled with PT's ASSM * * Note: PTDOS expects file lengths to be exact - there * is no real EOF character, even for library files * created by the SAVE command. Unfortunately, the * Xmodem protocol only allows 128-byte blocks - so * every file will be a multiple of 128 bytes. This * program pads the end with 0's. This works fine with * text files, and is harmless for programs, aside from * making them a little longer. However, when you read * a library file with GET, these pad characters at the * end will cause a PTDOS error message on the console, * though no harmful outcome results from this error. * * The Sol-20 LOCAL key will cause its serial port data * output to be shunted to its input, rather than to * the external connector. This code tests for the LOCAL * key 'ON' by looking for serial port output echoed at * its input at the beginning of the Xmodem transfer. If * the LOCAL appears to be 'ON', the user is asked to * turn it off. * * VERS DATE NOTE * 1.01 11FEB2013 CREATED * 1.02 02MAR2015 Improved LOCAL key message * ******************************************************* TRUE EQU 1 FALSE EQU 0 COPY XMODHD.A ;GATHER HEADER FILE COPY XMODMN.A ;XMODEM MAIN ROUTINES COPY XMODSB.A ;XMODEM SUBROUTINES COPY XMODST.A ;XMODEM STRINGS END