Dec 172017
Generates CRC value for a string. All in Quick Basic.
File CRCBAS.ZIP from The Programmer’s Corner in
Category BASIC Language
Generates CRC value for a string. All in Quick Basic.
File Name File Size Zip Size Zip Type
CRCTEST.BAS 3354 1662 deflated
CRCTEST.DOC 1293 717 deflated
TPCREAD.ME 199 165 deflated

Download File CRCBAS.ZIP Here

Contents of the CRCTEST.DOC file

Somehow I became interested in writing a terminal program in
QuickBASIC and also wanted to include Xmodem. So I searched around
and found all the information I could on Xmodem. I downloaded several
text files from CIS which were extremely helpful. I also bought
"Mastering Serial Communications" by Peter W. Gofton (Sybex). This book
was very helpful and I highly recommend it.
At any rate, I discovered that to implement Xmodem I had to do
checksum and, alternatively, CRC on the 128 byte data block. The ADVAS
library (also available on CIS) has assembly routines for both and I tried
them (successfully). But I also wanted to see if I could implement Xmodem
in 'pure' BASIC.
Subsequently, I ran across an IBM PC BASIC implementation of a CRC
algorithm. It was in Peter Boswell's "Xmodem, CRC Xmodem, Wxmodem File
Transfer Protocols" (available on CIS, IBMCOM dl10). This is an excellent
discussion and I recommend it to anyone trying to learn more about
Xmodem. The next step was to modify his BASIC code to QuickBASIC, which
I did. The result is CRCTEST.BAS. Anyone wondering what in the world the
DATA statements are all about, I would refer to Peter Boswell's discussion.
Comments are welcome.

Lyle Jensen
CIS 71511,2072

 December 17, 2017  Add comments

Leave a Reply