Re: A86: Re: getting _randint to work


[Prev][Next][Index][Thread]

Re: A86: Re: getting _randint to work




'FPS' = floating point stack. 'FPST' = floating point stack top


                        ram page 1
                    -------------------------
                   |       fps               |
                   |        |                |
                   |        v                |
                   |                         |
                   |        ^                | 
                   |        |                |                     
                   |       ops               |
                    -------------------------

      The FPS is mainly used to hold pending operands when executing. The OPS =
operator stack.
      Each entry on the FPS is 10 bytes, the size of a floating point # or var
name. 
      Each entry on the OPS is a byte.
      The FPS can also be used as temp storage during computations. The user of
the stack
      is responsible for removing what they put on.
      (FPS) is the pointer to the byte after the last entry of the stack, next
place for entry.
      Here are some routins that use the stack 

	pushrealo1 equ 4813h - push op1 onto FPS 10 bytes
        poprealo1  equ 47B7h - pop FPS into op110 bytes

      There are others that allow copying entries to and from the stack.

      If anyone needs these let me know.

Later,
Pat  
                       

------------------
Original text

From: "Jeremy Goetsch" <jeremy@stupidzone.com>, on 3/21/98 6:45 PM:

Ahh, now I understand. Store the lower bound in OP1 and the upper bound in
OP2 and it works perfectly. It has absolutely nothing to do with the
floating point stack.

It's anyone's guess what he meant by FPST.

-----Original Message-----
From: Dux Gregis <assets@eden.rutgers.edu>
To: assembly-86@lists.ticalc.org <assembly-86@lists.ticalc.org>
Date: Saturday, March 21, 1998 12:42 PM
Subject: Re: A86: Re: getting _randint to work


>
>
>
>Jeremy Goetsch wrote:
>
>> The value stored in _FPS is the 16-bit address in RAM page 1 of the top
of
>> the floating point stack. E.g., if there are no floating point operations
in
>> progress, the value is the same as in _FPBASE, which is $0000, since the
>> floating point stack starts at the beginning of ram page 1.
>>
>> I assume that he does not mean for you to load the value into (_FPS)
itself,
>> but into the top of the floating point stack on RAM page 1.
>> I guess it would be stored in the same format as an OP, not sure though.
>
>The call came from one of the Pede files.  Pat refers to the second end
point as
>FPST and I just assumed he meant _FPS.  Look at the ti86math.inc that comes
with
>pede; there might even be an example.
>



Follow-Ups: References: