Post Reply 
[Saturn Asm] Plot routine
11-10-2021, 04:17 PM
Post: #1
[Saturn Asm] Plot routine
Code:

         NIBASC  /HPHP48-A/      Binary download header
    CON(5)    =DOCODE
    REL(5)    Fin

* bottom menu off
    D0=(5) #00128
    LCHEX 3F
    DAT0=C B
* video address
    GOSBVL    =D0->Row1    * D0,A[A] -> top left corner of display
    R0=A.F    A
    D0=A
* clear screen
    LCHEX    87
    A=0 W
CL    DAT0=A W
    D0=D0+ 16
    C=C-1 B
    GONC CL

* test plot
    LAHEX 00000
    B=A A
* LL    GOTO LL
TP
    A=0 M
    A=B A
    C=B A
    GOSUB PLT  * C=y,A=x
    B=B+1 B
    LCHEX 40
    ?B<C B
    GOYES TP
KK    GOTO KK
    RTN
PLT * destroys A,C,D
    D=C A
    DSL A * D*16
    D=D+C A * D*17
    D=D+D A * D*34
    C=R0 A
    D=D+C A
* X
    LCHEX 00003
    C=C&A A
    CBIT=1  3
    P=C 0
    LCHEX #12481248
    P= 0
    CDEX A
    ASRB A
    ASRB A
    A=A+C A
    D0=A
    CDEX A
    A=DAT0 S
    A=A!C S
    DAT0=A S
    RTN

Fin
    END
Find all posts by this user
Quote this message in a reply
11-23-2021, 10:42 PM
Post: #2
RE: [Saturn Asm] Plot routine
What does it draw?

2xHP48GX, HP 50g, two Retrotronik ram cards, DM42
/Daniel Lidström
Find all posts by this user
Quote this message in a reply
11-25-2021, 07:25 PM
Post: #3
RE: [Saturn Asm] Plot routine
(11-23-2021 10:42 PM)dlidstrom Wrote:  What does it draw?

As far as I can tell it draws a 45 degree angle diagonal line starting from the top left corner of the screen down to the bottom.

Regards,

Jonathan

Aeternitas modo est. Longa non est, paene nil.
Find all posts by this user
Quote this message in a reply
Post Reply 




User(s) browsing this thread: 2 Guest(s)