mirror of
https://github.com/KarolS/millfork.git
synced 2024-09-27 12:57:41 +00:00
28 lines
541 B
Plaintext
28 lines
541 B
Plaintext
// Routines from C16 and Plus/4 KERNAL ROM
|
|
#if not(CBM_264)
|
|
#warn c264_kernal module should be only used on C264-compatible targets
|
|
#endif
|
|
|
|
// CHROUT. Write byte to default output. (If not screen, must call OPEN and CHKOUT beforehands.)
|
|
// Input: A = Byte to write.
|
|
asm void chrout(byte a) @$FFD2 extern
|
|
|
|
asm void putchar(byte a) {
|
|
JSR chrout
|
|
LDA #0
|
|
STA $CB
|
|
? RTS
|
|
}
|
|
|
|
noinline asm byte readkey() {
|
|
__read_key__start:
|
|
LDA $EF
|
|
BEQ __read_key__start
|
|
LDX #0
|
|
JMP $D8D5
|
|
}
|
|
|
|
inline void new_line() {
|
|
putchar(13)
|
|
}
|