MBASIC Blues

Author(s): David Baulch
Publication: The Data Expansion
Pub Details: The Data Expansion v5 n6 (Volume 5, Issue 6)
Date: June 1988
Pages: 22-23

I like having MBASIC to work with in RP/M. It is close enough to most BASICs on the market that I can transpose most programs to fit, including IBM programs. However, I have run into some difficulty at the present.

To use a spectacular grading program provided by the computer science teacher at school, I had to take one of his early versions meant to work on the TRS-80 Model 4 and convert TRS-DOS BASIC to MBASIC. Most of this was straight forward keying in. Some things, like the CLS, which TRS-DOS has and MBASIC does not, had to be fixed. The PRINT AT statements are also different. Obviously, after keying in some 12 pages (approximately 24K) of BASIC, I needed to “debug” the prorgam. Many of the errors were in typing, but those were soon cleared up. The changing of the /DAT extension to .DAT was simple as the changing of the CLS to PRINT CHR$ (12) was. (Isn’t the global search and replace found on most text editors and word processors great!) However, the program uses sequential files, and I am not upto using sequential files, let alone random files. I still had problems.

The program works, but will not send the file to the disk. The information gets written to the screen and is still in memory, but for some unknown reason, it never makes it out to the file. The file gets opened, but I have had to “break” the program and CLOSE the file by hand every time so far. I will still continue to work with it and maybe next time I will have found the solution.

I am certain that you will have noticed the absence of the PASCAL column, I am trying to get this program working first, then transpose it to PASCAL for faster working. I do have a friend that has TURBO PASCAL for the CP/M machines that might try to “compile” it as a stand alone program and a .COM file. That would be nice, but that gives me a great deal of work to do.

The BLUES part of the MBASIC is because I hav yet to figure out the bug in the program. Also because I am not familiar enough with sequential and random file disk access. I will eventually get there, but that does not mean that I like the “trek”.