I am trying to receive Data from the PC side by the Megadrive but I have not been able to get the Megadrive to respond to the Data sent to it.
I am using the Ext-Port (port 3) on a German VA4 Megadrive 1.
I have the MD set as Baud 1200.
I have no problems at all when the MD transmits Data to the PC so that part works at the very least.
I call the SerialRxChar Routine in a continuous Loop.
I have used my Logic-Analyser and I can see that the Characters are transmitted from the PC side with no corruption of framing errors.
My Code performs these steps:
Code: Select all
md_io_port3_ser_sctrl: equ $A1001F
md_io_port3_ser_tx: equ $A1001B
md_io_port3_ser_rx: equ $A1001D
md_io_port3_par_data: equ $A10007
md_io_port3_par_ctrl: equ $A1000D
...
SeriaInit:
move.B #$B0,axl_md_io_port3_ser_sctrl
...
SerialRxChar:
SerialRxCharInit:
SerialRxCharExec:
Serial_RxChar_RxRdyWait:
move.B md_io_port3_ser_sctrl,d1
btst #3,d1
bne Serial_RxChar_RdDError
btst #2,d1
beq Serial_RxChar_RxRdyWait
move.B md_io_port3_ser_rx,d0
;Serial_RxChar_INFIN_RxRdyGot:
; lea Dummy_MsgGotRxRdy,a5
; jsr Serial_TxString
; bra Serial_RxChar_INFIN_RxRdyGot
Serial_RxChar_RdDError:
lea Dummy_MsgGotRxDErrory,a5
jsr Serial_TxString
bra Serial_RxChar_RdDError
Serial_RxChar_Exit:
rts
Does anyone have any Ideas? I can further elaborate on my pins and circuitry if you think that might be something to consider.
Many thanks,
Minty.