8-Bit Software

The BBC and Master Computer Public Domain Library

Back to 8BS Or Back to Disassembly

Page Last Altered:


Submitted by Steve Fewell


Set A to #&05. This is the PLOT type (i.e. the first parameter of the VDU 25 command) for the DRAW command.
[&97A8] Push A to the 6502 Stack.
Call &9D2F to get the result of the expression after the 'DRAW' keyword (at the BASIC text Pointer B location).
Call &96BC to convert the result value to Integer (if it is a Floating-Point value), or to issue a 'Type mismatch'
error if the result is a String value.
Jump to the PLOT routine to execute the appropriate VDU 25 command for DRAW.

Disassembly for the DRAW routine

97A6   169 005 A9 05 LDA#&05
97A8 H 072 48 PHA
97A9 / 032 047 157 20 2F 9D JSR &9D2F Ptr B = Ptr A & Get result of expression
97AC   032 188 150 20 BC 96 JSR &96BC Check result type (location &27) - if Float then convert to Integer
97AF   128 009 80 09 BRA 9 --> &97BA Call PLOT routine


 Back to 8BS