13.07.2015 Views

apple-pascal-1.3-manual

apple-pascal-1.3-manual

apple-pascal-1.3-manual

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

yte = The address of the byte whose bits are to be set .. MACRO SETLDA #%1ORA %2STA %2.ENDMThe RESET MacroThis macro resets specific bits within a byte.Form: RESET (bits ),(byte)bits= The bits to be reset (set to 0).byte = The address of the byte whose bits are to be reset..MACRO RESETMASK .EQU FFLDA N%1"MASK is EXCLUSIVE DRAND %2STA %2.ENDMThe SWITCH MacroThis macro performs an n-way branch based on a switch index. Themaximum value of the switch index is 127 with bounds checking providedas an option. The A and Y registers, and the C, Z, and N status flags, aredestroyed by the macro. The X register is not modified by the macro.Form: SWITCH , ,( address table),index = The variable that is to be used as the switch index. If it is omitted,the accumulator is used as the index.bounds = The maximum allowable value for the index. If the indexexceeds this value, the carry bit is set and execution continues. If thisparameter is omitted, then no bounds checking is performed.address table = A table of addresses used by the switch. Note that theaddress -1 is used, because of the RTS instruction.The SWITCH MacroIII-335

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!