Hello
I have a BASIC program in &170 address. I want to invoque it from ASM code. How can I do it?
Thank you.
There's no simple way of doing that. Check out the March 89 issue of Amstrad Computer User for the gory details if you must.
Amstrad Computer User 52 (https://acpc.me/ACME/LITTERATURE_REVUES/%5BENG%5DENGLISH_UK/%5BENG%5D%5BAMSTRAD%5DAMSTRAD_COMPUTER_USER/AMSTRAD_COMPUTER_USER_52%5BOCR%5D.pdf)
From BASIC you had to make a CALL to the ASM code. You just need to come back with a RET.
Hello.
Try with this ... ;)
CALL #B900
SCF
JP #EA7B
:D pressing buttons on the keyboard
call &bd19 ;wait v-sync
ld a,2
ld (&b8bF),a ;set scan keyboard two interrupt after v-sync
call &bd19 ;wait v-sync
ld a,255-4
ld (&b645),a ;pressed R
call &bd19 ;wait v-sync
ld (&b644),a ;pressed U
call &bd19 ;wait v-sync
ld a,255-64
ld (&b644),a ;pressed N
call &bd19 ;wait v-sync
ld (&b63F),a ;pressed ENTER
RET ;return to BASIC
possible GOTO 123
>:( correction
org #4000
call &bd19 ;wait v-sync
ld a,3
ld (&b8bF),a ;set scan keyboard two interrupt after v-sync
call &bd19 ;wait v-sync
halt
ld a,255-4
ld (&b645),a ;pressed R
call &bd19 ;wait v-sync
halt
ld (&b644),a ;pressed U
call &bd19 ;wait v-sync
halt
ld a,255-64
ld (&b644),a ;pressed N
call &bd19 ;wait v-sync
halt
ld (&b63F),a ;pressed ENTER
RET ;return to BASIC