several IEC routines now properly preserve X/Y registers
This commit is contained in:
1 parent
eb8eefff82
commit
f26431b502
14 files changed
+96
-83
No files matched your search
@@ -73,18 +73,18 @@ NOTE: Even the 'DONE' routines won't support features described as missing in on
|
|||||||
| $FF8A | RESTOR | PARTIAL | CBINV, NMINV, and USRCMD missing |
|
| $FF8A | RESTOR | PARTIAL | CBINV, NMINV, and USRCMD missing |
|
||||||
| $FF8D | VECTOR | DONE | |
|
| $FF8D | VECTOR | DONE | |
|
||||||
| $FF90 | SETMSG | DONE | |
|
| $FF90 | SETMSG | DONE | |
|
||||||
| $FF93 | SECOND | PARTIAL | * work in progress |
|
| $FF93 | SECOND | DONE | |
|
||||||
| $FF96 | TKSA | PARTIAL | should probably also do a turnaround |
|
| $FF96 | TKSA | PARTIAL | should it do a turnaround? |
|
||||||
| $FF99 | MEMTOP | DONE | |
|
| $FF99 | MEMTOP | DONE | |
|
||||||
| $FF9C | MEMBOT | DONE | |
|
| $FF9C | MEMBOT | DONE | |
|
||||||
| $FF9F | SCNKEY | DONE | could be better integrated with ROM |
|
| $FF9F | SCNKEY | DONE | could be better integrated with ROM |
|
||||||
| $FFA2 | SETTMO | NOT DONE | |
|
| $FFA2 | SETTMO | NOT DONE | |
|
||||||
| $FFA5 | ACPTR | NOT DONE | * work in progress |
|
| $FFA5 | ACPTR | NOT DONE | * work in progress |
|
||||||
| $FFA8 | CIOUT | PARITAL | * work in progress |
|
| $FFA8 | CIOUT | DONE | |
|
||||||
| $FFAB | UNTLK | PARITAL | * work in progress |
|
| $FFAB | UNTLK | PARITAL | * work in progress |
|
||||||
| $FFAE | UNLSN | PARITAL | * work in progress |
|
| $FFAE | UNLSN | DONE | |
|
||||||
| $FFB1 | LISTEN | PARTIAL | * work in progress |
|
| $FFB1 | LISTEN | DONE | |
|
||||||
| $FFB4 | TALK | PARTIAL | * work in progress |
|
| $FFB4 | TALK | PARTIAL | should it do a turnaround? |
|
||||||
| $FFB7 | READST | DONE | |
|
| $FFB7 | READST | DONE | |
|
||||||
| $FFBA | SETFLS | DONE | |
|
| $FFBA | SETFLS | DONE | |
|
||||||
| $FFBD | SETNAM | DONE | |
|
| $FFBD | SETNAM | DONE | |
|
||||||
|
|||||||
+1
-3
@@ -8,7 +8,6 @@
|
|||||||
;; CPU registers that has to be preserved (see [RG64]): .X, .Y
|
;; CPU registers that has to be preserved (see [RG64]): .X, .Y
|
||||||
;;
|
;;
|
||||||
|
|
||||||
;; XXX currently does not preserve registers, to be fixed!
|
|
||||||
|
|
||||||
ciout:
|
ciout:
|
||||||
|
|
||||||
@@ -31,9 +30,8 @@ ciout_store_in_buffer:
|
|||||||
|
|
||||||
ciout_send_byte:
|
ciout_send_byte:
|
||||||
|
|
||||||
;; Send previous data
|
|
||||||
lda BSOUR
|
|
||||||
clc ; don't send with EOI
|
clc ; don't send with EOI
|
||||||
jsr iec_tx_byte
|
jsr iec_tx_byte
|
||||||
|
inc C3PO ; iec_tx_byte sets it to 0, but we still have something to send
|
||||||
jmp ciout_store_in_buffer
|
jmp ciout_store_in_buffer
|
||||||
|
|
||||||
@@ -0,0 +1,38 @@
|
|||||||
|
|
||||||
|
;;
|
||||||
|
;; Helper routines to return with error/success
|
||||||
|
;;
|
||||||
|
;; All of them restore X/Y registers from stack,
|
||||||
|
;; they take care about Carry flag,
|
||||||
|
;; error return reeset IEC line to default state,
|
||||||
|
;; take care about .A and IOSTATUS
|
||||||
|
;;
|
||||||
|
|
||||||
|
iec_return_success:
|
||||||
|
|
||||||
|
;; BSOUR is certainly not valid anymore
|
||||||
|
lda #$00
|
||||||
|
sta C3PO
|
||||||
|
;; Restore registers
|
||||||
|
pla
|
||||||
|
tay
|
||||||
|
pla
|
||||||
|
tax
|
||||||
|
;; Report success
|
||||||
|
clc
|
||||||
|
rts
|
||||||
|
|
||||||
|
iec_return_DEVICE_NOT_FOUND:
|
||||||
|
|
||||||
|
;; Set IEC line to normal idle state
|
||||||
|
jsr iec_set_idle
|
||||||
|
;; BSOUR is certainly not valid anymore
|
||||||
|
lda #$00
|
||||||
|
sta C3PO
|
||||||
|
;; Restore registers
|
||||||
|
pla
|
||||||
|
tay
|
||||||
|
pla
|
||||||
|
tax
|
||||||
|
;; Report error
|
||||||
|
jmp kernalerror_DEVICE_NOT_FOUND
|
||||||
+10
-13
@@ -1,11 +1,16 @@
|
|||||||
|
|
||||||
;; Implemented based on https://www.pagetable.com/?p=1135, https://github.com/mist64/cbmbus_doc
|
;; Implemented based on https://www.pagetable.com/?p=1135, https://github.com/mist64/cbmbus_doc
|
||||||
|
|
||||||
;; Carry flag set = signal EOI
|
;; Expects byte to send in BSOUR; Carry flag set = signal EOI
|
||||||
|
;; Preserves .X and .Y registers
|
||||||
|
|
||||||
|
|
||||||
iec_tx_byte:
|
iec_tx_byte:
|
||||||
|
|
||||||
;; Store byte to send on the stack
|
;; Store .X and .Y on the stack - preserve them
|
||||||
|
txa
|
||||||
|
pha
|
||||||
|
tya
|
||||||
pha
|
pha
|
||||||
|
|
||||||
;; Notify all devices that we are going to send a byte
|
;; Notify all devices that we are going to send a byte
|
||||||
@@ -15,10 +20,9 @@ iec_tx_byte:
|
|||||||
;; Common part of iec_txbyte and iec_tx_common - waits for devices
|
;; Common part of iec_txbyte and iec_tx_common - waits for devices
|
||||||
;; and transmits a byte
|
;; and transmits a byte
|
||||||
|
|
||||||
pla
|
|
||||||
jsr iec_tx_common
|
jsr iec_tx_common
|
||||||
|
|
||||||
;; All done - give device time to tell if they are busy by pulling DATA
|
;; Give device time to tell if they are busy by pulling DATA
|
||||||
;; They should do it within 1ms
|
;; They should do it within 1ms
|
||||||
ldx #$FF
|
ldx #$FF
|
||||||
* lda CIA2_PRA
|
* lda CIA2_PRA
|
||||||
@@ -27,15 +31,8 @@ iec_tx_byte:
|
|||||||
bpl +
|
bpl +
|
||||||
dex
|
dex
|
||||||
bne -
|
bne -
|
||||||
bpl iec_tx_byte_error
|
bpl iec_return_DEVICE_NOT_FOUND
|
||||||
*
|
*
|
||||||
;; All done
|
jmp iec_return_success
|
||||||
clc
|
|
||||||
rts
|
|
||||||
|
|
||||||
iec_tx_byte_error:
|
|
||||||
|
|
||||||
jsr iec_set_idle
|
|
||||||
jmp kernalerror_DEVICE_NOT_FOUND
|
|
||||||
|
|
||||||
|
|
||||||
+12
-10
@@ -1,9 +1,16 @@
|
|||||||
|
|
||||||
;; Implemented based on https://www.pagetable.com/?p=1135, https://github.com/mist64/cbmbus_doc
|
;; Implemented based on https://www.pagetable.com/?p=1135, https://github.com/mist64/cbmbus_doc
|
||||||
|
|
||||||
|
;; Expects command to send in BSOUR; Carry flag set = signal EOI
|
||||||
|
;; Preserves .X and .Y registers
|
||||||
|
|
||||||
|
|
||||||
iec_tx_command:
|
iec_tx_command:
|
||||||
|
|
||||||
;; Store command to send on the stack
|
;; Store .X and .Y on the stack - preserve them
|
||||||
|
txa
|
||||||
|
pha
|
||||||
|
tya
|
||||||
pha
|
pha
|
||||||
|
|
||||||
;; Notify all devices that we are going to send a byte
|
;; Notify all devices that we are going to send a byte
|
||||||
@@ -19,10 +26,7 @@ iec_tx_command:
|
|||||||
beq +
|
beq +
|
||||||
|
|
||||||
;; No devices present on the bus, so we can immediately return with device not found
|
;; No devices present on the bus, so we can immediately return with device not found
|
||||||
pla
|
jmp iec_return_DEVICE_NOT_FOUND
|
||||||
|
|
||||||
jsr iec_set_idle
|
|
||||||
jmp kernalerror_DEVICE_NOT_FOUND
|
|
||||||
*
|
*
|
||||||
;; At least one device responded, but they are still allowed to stall
|
;; At least one device responded, but they are still allowed to stall
|
||||||
;; (can be busy processing something), we have to wait till they are all
|
;; (can be busy processing something), we have to wait till they are all
|
||||||
@@ -35,7 +39,6 @@ iec_tx_command:
|
|||||||
;; and transmits a byte
|
;; and transmits a byte
|
||||||
|
|
||||||
clc ; Carry flag set is used for EOI mark
|
clc ; Carry flag set is used for EOI mark
|
||||||
pla
|
|
||||||
jsr iec_tx_common
|
jsr iec_tx_common
|
||||||
|
|
||||||
;; According to https://www.pagetable.com/?p=1135 there is some complicated and dangerous
|
;; According to https://www.pagetable.com/?p=1135 there is some complicated and dangerous
|
||||||
@@ -50,8 +53,7 @@ iec_tx_command:
|
|||||||
;; to wait for the DATA being pulled, as confirmation is expected from
|
;; to wait for the DATA being pulled, as confirmation is expected from
|
||||||
;; a single device only - but not sure if it's worth the trouble
|
;; a single device only - but not sure if it's worth the trouble
|
||||||
|
|
||||||
jsr iec_set_idle
|
jmp iec_return_DEVICE_NOT_FOUND
|
||||||
jmp kernalerror_DEVICE_NOT_FOUND
|
|
||||||
*
|
*
|
||||||
;; All done
|
;; All done
|
||||||
|
|
||||||
@@ -60,5 +62,5 @@ iec_tx_command:
|
|||||||
;; jsr iec_wait20us
|
;; jsr iec_wait20us
|
||||||
;; jsr iec_set_idle
|
;; jsr iec_set_idle
|
||||||
|
|
||||||
clc
|
jmp iec_return_success
|
||||||
rts
|
|
||||||
@@ -3,15 +3,15 @@
|
|||||||
;; Implemented based on https://www.pagetable.com/?p=1135, https://github.com/mist64/cbmbus_doc
|
;; Implemented based on https://www.pagetable.com/?p=1135, https://github.com/mist64/cbmbus_doc
|
||||||
;; and http://www.zimmers.net/anonftp/pub/cbm/programming/serial-bus.pdf
|
;; and http://www.zimmers.net/anonftp/pub/cbm/programming/serial-bus.pdf
|
||||||
|
|
||||||
|
;; Expects byte to send in BSOUR; Carry flag set = signal EOI
|
||||||
|
|
||||||
|
|
||||||
iec_tx_common:
|
iec_tx_common:
|
||||||
|
|
||||||
;; Timing is critical here - execute on disabled IRQs
|
;; Timing is critical here - execute on disabled IRQs
|
||||||
php
|
php
|
||||||
sei
|
sei
|
||||||
|
|
||||||
;; Store the byte to send on a stack
|
|
||||||
pha
|
|
||||||
|
|
||||||
;; Wait till all receivers are ready, they should all release DATA
|
;; Wait till all receivers are ready, they should all release DATA
|
||||||
jsr iec_wait_for_data_release
|
jsr iec_wait_for_data_release
|
||||||
|
|
||||||
@@ -38,13 +38,14 @@ iec_tx_common:
|
|||||||
|
|
||||||
;; Now, we can start transmission of 8 bits of data
|
;; Now, we can start transmission of 8 bits of data
|
||||||
ldx #7
|
ldx #7
|
||||||
pla
|
|
||||||
|
|
||||||
iec_tx_common_sendbit:
|
iec_tx_common_sendbit:
|
||||||
;; Is next bit 0 or 1?
|
;; Is next bit 0 or 1?
|
||||||
|
lda BSOUR
|
||||||
lsr
|
lsr
|
||||||
pha
|
sta BSOUR
|
||||||
bcs +
|
bcs +
|
||||||
|
;; XXX we are actually destroying BSOUR here... is it allowed?
|
||||||
|
|
||||||
;; Bit is 0
|
;; Bit is 0
|
||||||
jsr iec_release_clk_pull_data
|
jsr iec_release_clk_pull_data
|
||||||
@@ -65,13 +66,8 @@ iec_tx_common_bit_is_sent:
|
|||||||
|
|
||||||
;; More bits to send?
|
;; More bits to send?
|
||||||
dex
|
dex
|
||||||
bpl iec_tx_common_nextbit
|
bpl iec_tx_common_sendbit
|
||||||
pla
|
|
||||||
|
|
||||||
plp
|
plp
|
||||||
rts ; Flow continues differently for data/command
|
rts ; Flow continues differently for data/command
|
||||||
|
|
||||||
iec_tx_common_nextbit:
|
|
||||||
|
|
||||||
pla
|
|
||||||
jmp iec_tx_common_sendbit
|
|
||||||
+2
-3
@@ -4,16 +4,15 @@
|
|||||||
;;
|
;;
|
||||||
;; - [RG64] C64 Programmer's Reference Guide - page 285
|
;; - [RG64] C64 Programmer's Reference Guide - page 285
|
||||||
;; - [CM64] Compute's Mapping the Commodore 64 - page 223
|
;; - [CM64] Compute's Mapping the Commodore 64 - page 223
|
||||||
|
;; - https://www.pagetable.com/?p=1031, https://github.com/mist64/cbmbus_doc
|
||||||
;;
|
;;
|
||||||
;; CPU registers that has to be preserved (see [RG64]): .X, .Y
|
;; CPU registers that has to be preserved (see [RG64]): .X, .Y
|
||||||
;;
|
;;
|
||||||
|
|
||||||
;; XXX currently does not preserve registers, to be fixed!
|
|
||||||
|
|
||||||
listen:
|
listen:
|
||||||
|
|
||||||
;; This trivial routine is documented in 'Compute's Mapping the Commodore 64', page 223 and
|
|
||||||
;; https://www.pagetable.com/?p=1031, , https://github.com/mist64/cbmbus_doc
|
|
||||||
and #$1F ; make sure bits encoding the command are cleared out
|
and #$1F ; make sure bits encoding the command are cleared out
|
||||||
ora #$20
|
ora #$20
|
||||||
|
sta BSOUR
|
||||||
jmp iec_tx_command
|
jmp iec_tx_command
|
||||||
+5
-9
@@ -67,22 +67,16 @@ load_send_filename:
|
|||||||
jsr peek_under_roms
|
jsr peek_under_roms
|
||||||
iny
|
iny
|
||||||
|
|
||||||
;; Save Y because iec_tx_byte will corrupt it
|
|
||||||
tax
|
|
||||||
tya
|
|
||||||
pha
|
|
||||||
|
|
||||||
;; Set Carry flag on the last file name character, to mark EOI
|
;; Set Carry flag on the last file name character, to mark EOI
|
||||||
cmp FNLEN
|
cpy FNLEN
|
||||||
clc
|
clc
|
||||||
bne +
|
bne +
|
||||||
sec
|
sec
|
||||||
*
|
*
|
||||||
txa
|
;; Transmit one character
|
||||||
|
sta BSOUR
|
||||||
jsr iec_tx_byte
|
jsr iec_tx_byte
|
||||||
|
|
||||||
pla
|
|
||||||
tay
|
|
||||||
jmp load_send_filename
|
jmp load_send_filename
|
||||||
|
|
||||||
load_filename_sent:
|
load_filename_sent:
|
||||||
@@ -98,6 +92,7 @@ load_filename_sent:
|
|||||||
bcs lvs_load_verify_error
|
bcs lvs_load_verify_error
|
||||||
|
|
||||||
lda #$60 ; open channel / data (p3) , required according to p13
|
lda #$60 ; open channel / data (p3) , required according to p13
|
||||||
|
sta BSOUR
|
||||||
jsr iec_tx_command
|
jsr iec_tx_command
|
||||||
bcs lvs_load_verify_error
|
bcs lvs_load_verify_error
|
||||||
|
|
||||||
@@ -156,6 +151,7 @@ load_loop:
|
|||||||
jsr listen
|
jsr listen
|
||||||
|
|
||||||
lda #$E0
|
lda #$E0
|
||||||
|
sta BSOUR
|
||||||
jsr iec_tx_command
|
jsr iec_tx_command
|
||||||
|
|
||||||
;; Tell drive to unlisten
|
;; Tell drive to unlisten
|
||||||
|
|||||||
+1
-10
@@ -82,12 +82,6 @@ open_iec:
|
|||||||
;; XXX note: this is only a temporary test implementation, real 'open' does not send anything to IEC,
|
;; XXX note: this is only a temporary test implementation, real 'open' does not send anything to IEC,
|
||||||
;; see http://www.zimmers.net/anonftp/pub/cbm/programming/serial-bus.pdf
|
;; see http://www.zimmers.net/anonftp/pub/cbm/programming/serial-bus.pdf
|
||||||
|
|
||||||
;; Disable IRQs, since timing matters!
|
|
||||||
sei
|
|
||||||
|
|
||||||
;; Begin sending under attention
|
|
||||||
;; XXX jsr iec_assert_atn
|
|
||||||
|
|
||||||
;; Request device to talk
|
;; Request device to talk
|
||||||
lda current_device_number
|
lda current_device_number
|
||||||
jsr talk
|
jsr talk
|
||||||
@@ -107,8 +101,5 @@ open_iec:
|
|||||||
clc
|
clc
|
||||||
|
|
||||||
open_iec_error:
|
open_iec_error:
|
||||||
;; Re-enable interrupts and return
|
;; Carry flag will be set by low-level routines
|
||||||
;; (iec_tx_byte will have set/cleared C flag and put result code
|
|
||||||
;; in A if it was an error).
|
|
||||||
cli
|
|
||||||
rts
|
rts
|
||||||
+2
-3
@@ -4,16 +4,15 @@
|
|||||||
;;
|
;;
|
||||||
;; - [RG64] C64 Programmer's Reference Guide - page 296
|
;; - [RG64] C64 Programmer's Reference Guide - page 296
|
||||||
;; - [CM64] Compute's Mapping the Commodore 64 - page 223/224
|
;; - [CM64] Compute's Mapping the Commodore 64 - page 223/224
|
||||||
|
;; - https://www.pagetable.com/?p=1031, , https://github.com/mist64/cbmbus_doc
|
||||||
;;
|
;;
|
||||||
;; CPU registers that has to be preserved (see [RG64]): .X, .Y
|
;; CPU registers that has to be preserved (see [RG64]): .X, .Y
|
||||||
;;
|
;;
|
||||||
|
|
||||||
;; XXX currently does not preserve registers, to be fixed!
|
|
||||||
|
|
||||||
second:
|
second:
|
||||||
|
|
||||||
;; see also https://www.pagetable.com/?p=1031, , https://github.com/mist64/cbmbus_doc
|
|
||||||
|
|
||||||
and #$1F ; make sure bits encoding the command are cleared out
|
and #$1F ; make sure bits encoding the command are cleared out
|
||||||
ora #$60
|
ora #$60
|
||||||
|
sta BSOUR
|
||||||
jmp iec_tx_command
|
jmp iec_tx_command
|
||||||
+3
-4
@@ -4,18 +4,17 @@
|
|||||||
;;
|
;;
|
||||||
;; - [RG64] C64 Programmer's Reference Guide - page 301/302
|
;; - [RG64] C64 Programmer's Reference Guide - page 301/302
|
||||||
;; - [CM64] Compute's Mapping the Commodore 64 - page 223
|
;; - [CM64] Compute's Mapping the Commodore 64 - page 223
|
||||||
|
;; - https://www.pagetable.com/?p=1031, https://github.com/mist64/cbmbus_doc
|
||||||
;;
|
;;
|
||||||
;; CPU registers that has to be preserved (see [RG64]): .X, .Y
|
;; CPU registers that has to be preserved (see [RG64]): .X, .Y
|
||||||
;;
|
;;
|
||||||
|
|
||||||
;; XXX currently does not preserve registers, to be fixed!
|
|
||||||
;; XXX shouldn't this do a turnaround?
|
;; XXX shouldn't this do a turnaround?
|
||||||
|
|
||||||
talk:
|
talk:
|
||||||
|
|
||||||
;; See also https://www.pagetable.com/?p=1031, https://github.com/mist64/cbmbus_doc
|
|
||||||
|
|
||||||
and #$1F ; make sure bits encoding the command are cleared out
|
and #$1F ; make sure bits encoding the command are cleared out
|
||||||
ora #$40
|
ora #$40
|
||||||
|
sta BSOUR
|
||||||
jmp iec_tx_command
|
jmp iec_tx_command
|
||||||
|
|
||||||
+3
-3
@@ -4,18 +4,18 @@
|
|||||||
;;
|
;;
|
||||||
;; - [RG64] C64 Programmer's Reference Guide - page 302
|
;; - [RG64] C64 Programmer's Reference Guide - page 302
|
||||||
;; - [CM64] Compute's Mapping the Commodore 64 - page 224
|
;; - [CM64] Compute's Mapping the Commodore 64 - page 224
|
||||||
|
;; - https://www.pagetable.com/?p=1031, https://github.com/mist64/cbmbus_doc
|
||||||
;;
|
;;
|
||||||
;; CPU registers that has to be preserved (see [RG64]): .X, .Y
|
;; CPU registers that has to be preserved (see [RG64]): .X, .Y
|
||||||
;;
|
;;
|
||||||
|
|
||||||
;; XXX currently does not preserve registers, to be fixed!
|
|
||||||
;; XXX shouldn't this do a turnaround?
|
;; XXX shouldn't this do a turnaround?
|
||||||
|
|
||||||
tksa:
|
tksa:
|
||||||
|
|
||||||
;; See also https://www.pagetable.com/?p=1031, , https://github.com/mist64/cbmbus_doc
|
|
||||||
|
|
||||||
and #$1F ; make sure bits encoding the command are cleared out
|
and #$1F ; make sure bits encoding the command are cleared out
|
||||||
ora #$F0
|
ora #$F0
|
||||||
|
sta BSOUR
|
||||||
jmp iec_tx_command
|
jmp iec_tx_command
|
||||||
|
|
||||||
+3
-6
@@ -4,11 +4,11 @@
|
|||||||
;;
|
;;
|
||||||
;; - [RG64] C64 Programmer's Reference Guide - page 303
|
;; - [RG64] C64 Programmer's Reference Guide - page 303
|
||||||
;; - [CM64] Compute's Mapping the Commodore 64 - page 224
|
;; - [CM64] Compute's Mapping the Commodore 64 - page 224
|
||||||
|
;; - https://www.pagetable.com/?p=1031, , https://github.com/mist64/cbmbus_doc
|
||||||
;;
|
;;
|
||||||
;; CPU registers that has to be preserved (see [RG64]): .X, .Y
|
;; CPU registers that has to be preserved (see [RG64]): .X, .Y
|
||||||
;;
|
;;
|
||||||
|
|
||||||
;; XXX currently does not preserve registers, to be fixed!
|
|
||||||
|
|
||||||
unlsn:
|
unlsn:
|
||||||
|
|
||||||
@@ -17,15 +17,12 @@ unlsn:
|
|||||||
;; First check whether we have something to be sent in the buffer
|
;; First check whether we have something to be sent in the buffer
|
||||||
lda C3PO
|
lda C3PO
|
||||||
beq +
|
beq +
|
||||||
lda BSOUR
|
|
||||||
sec ; send it with EOI
|
sec ; send it with EOI
|
||||||
jsr iec_tx_byte ; XXX what about the status of this operation?
|
jsr iec_tx_byte ; XXX what about the status of this operation?
|
||||||
;; Mark the buffer as invalid
|
|
||||||
lda #$00
|
|
||||||
sta C3PO
|
|
||||||
*
|
*
|
||||||
;; Buffer empty send the command
|
;; Buffer empty, send the command
|
||||||
lda #$3F
|
lda #$3F
|
||||||
|
sta BSOUR
|
||||||
jmp iec_tx_command
|
jmp iec_tx_command
|
||||||
|
|
||||||
|
|
||||||
+3
-2
@@ -4,16 +4,17 @@
|
|||||||
;;
|
;;
|
||||||
;; - [RG64] C64 Programmer's Reference Guide - page 304
|
;; - [RG64] C64 Programmer's Reference Guide - page 304
|
||||||
;; - [CM64] Compute's Mapping the Commodore 64 - page 224
|
;; - [CM64] Compute's Mapping the Commodore 64 - page 224
|
||||||
|
;; - https://www.pagetable.com/?p=1031, , https://github.com/mist64/cbmbus_doc
|
||||||
;;
|
;;
|
||||||
;; CPU registers that has to be preserved (see [RG64]): .X, .Y
|
;; CPU registers that has to be preserved (see [RG64]): .X, .Y
|
||||||
;;
|
;;
|
||||||
|
|
||||||
;; XXX currently does not preserve registers, to be fixed!
|
|
||||||
;; XXX shouldn't this do a turnaround?
|
;; XXX shouldn't this do a turnaround?
|
||||||
|
|
||||||
untlk:
|
untlk:
|
||||||
|
|
||||||
;; This trivial routine is documented in 'Compute's Mapping the Commodore 64', page 224
|
|
||||||
lda #$5F
|
lda #$5F
|
||||||
|
sta BSOUR
|
||||||
jmp iec_tx_command
|
jmp iec_tx_command
|
||||||
|
|
||||||
Reference in new issue
Block a user