
BANKSWITCHER:
PUSH CURBANK       ;a DATA space variable
MOV A,#1C          ;these make a return
PUSH ACC           ;address on the stack for the UNBANK code
PUSH DPL           ;make DPRT into addr on stack
PUSH DPH
MOV CURBANK,#NEWBANK ;set local var to new bank
MOV BANKREG,#NEWBANK ;set bank select hardware
RET                 ;transfer to target function
