[Coco] Coco Digest, Vol 143, Issue 69
Stephen Pereira
spereira1952 at comcast.net
Sun Nov 16 10:48:59 EST 2014
Thanks very much for the tip, Art!
I’ll take a look at that.
smp
--
Stephen M. Pereira
Bedford, NH 03110
KB1SXE
> ------------------------------
>
> Message: 4
> Date: Sat, 15 Nov 2014 16:36:13 -0500
> From: Arthur Flexser <flexser at fiu.edu>
> To: CoCoList for Color Computer Enthusiasts <coco at maltedmedia.com>
> Subject: Re: [Coco] [CoCo] Re: Basic Lisp
> Message-ID:
> <CA+LuDcdJaewDR12QL8_Sx0kamRdM_Yg-LEKhRk4YyZrfoXJxqA at mail.gmail.com>
> Content-Type: text/plain; charset=UTF-8
>
> It seems possible that ERR is an intrinsic error-trapping function in
> TRS-80 Basic that returns an error number that would be specific to that
> machine. (Equivalent to ERNO in the CoCo 3's Basic.) You might want to
> check out that possibility in the docs for the TRS-80 Basic.
>
> Art
>
> On Sat, Nov 15, 2014 at 2:52 PM, Stephen Pereira <spereira1952 at comcast.net>
> wrote:
>
>> Here is an update of my investigation of Basic Lisp:
>>
>> I have scoured the code and continued to clean up OCR issues. I added all
>> the spaces back into the code, so I can better understand what the code is
>> doing. I believe that I found one typo from the original listing in 80
>> Microcomputing magazine:
>>
>> 26013 IF ERR/2+1=9 THEN IF A>350 OR J1>15 OR J2>15 OR J>15 PRINT"; STACK
>> OVERFLOW" : GOTO 27000
>>
>> There is no variable called ERR in the program. The is a variable ER,
>> however, so I am assuming that the IF statement should be something like IF
>> ER*R/2+1=9, or some other operation like that. But, this is how the
>> magazine printed it, so more analysis of the code will be needed to
>> determine what the IF statement should be.
>>
>> My system is a stock CoCo 3 with an HDB DOS cartridge and using Drivewire
>> as the mass storage. When I power up, PRINT MEM provides 22824. After I
>> load the program, PRINT MEM provides 12571. With this little memory left
>> available, the CLEAR and DIM statements in line 15 look problematic:
>>
>> 15 CLS : CLEAR 325 : DEF INT A-E,G-V,X-Z : DEF STR O : DIM
>> LM(1100),PL(1100),OB(90),PT(90),ST(350),FP(50),T1(15),X1(15) : N=3000
>>
>> Indeed, when I type RUN, I am greeted by OM ERROR IN 15 (well, actually,
>> that came after the SN ERRORs, because of the DEFINT and DEFSTR statements
>> that I had to eliminate).
>>
>> I reduced both LM and PL to 100 elements each, in order to see if I could
>> get the code to go at all. Following that, I found that I had to make
>> array OB(90) to be OB$(90) because it?s a string array. I also found that
>> the CoCo does not like a variable to be named AS for some reason, and I
>> needed to change the ON ERROR command to be ONERR.
>>
>> With these changes, I am able to get the program to go through
>> initialization and show the $ prompt as it should. Then, it will take an
>> initial (, but it hangs on the next character I type.
>>
>> So, that?s my progress so far. I am thinking that I will have to
>> explicitly indicate that all the numeric variables and arrays (except F and
>> W) are integer by using the % marker on them. Then, perhaps I will be able
>> to lengthen the LM and PL arrays. But first, I?ll have to figure out where
>> the code is hanging up, so I can actually enter an entire line for
>> evaluation by the interpreter.
>>
>> That?s all so far...
>>
>> smp
>> --
>> Stephen M. Pereira
>> Bedford, NH 03110
>> KB1SXE
>>
>>
More information about the Coco
mailing list