1
0
mirror of https://github.com/KarolS/millfork.git synced 2024-12-28 11:31:58 +00:00
millfork/include/c64_basic.mfk

31 lines
591 B
Plaintext
Raw Normal View History

2017-12-06 23:23:30 +00:00
// Routines from C64 BASIC ROM
#if not(CBM_64)
#warn c64_basic module should be only used on C64-compatible targets
#endif
2017-12-06 23:23:30 +00:00
import c64_kernal
2018-12-19 18:01:53 +00:00
import err
2017-12-06 23:23:30 +00:00
// print a 16-bit number on the standard output
asm void putword_basic(word register(xa) num) @$BDCD extern
2018-12-19 18:01:53 +00:00
2018-12-19 21:26:10 +00:00
alias putword = putword_basic!
2018-12-19 18:01:53 +00:00
asm void __readline_basic() @$A560 extern
pointer readline_basic() {
__readline_basic()
return readline_out
}
alias readline = readline_basic!
2018-01-20 21:03:56 +00:00
const pointer readline_out = $200
2018-12-19 18:01:53 +00:00
inline word readword_basic() {
return strz2word(readline_basic())
2018-01-20 21:03:56 +00:00
}
2018-12-19 18:01:53 +00:00
alias readword = readword_basic!