Hi there,
I have been trying to sort out a couple of home made 68000 boards i have built them both on protoboard ( the sort with just round holes not strips )
There one is 68000 and the other is 68010 both at 10 mhz, Both have a pair of 28C256 eeproms for rom and a pair of 128K static ram chips they both have
a pair of 74ls374 wired to 16 leds from vcc, and both have an MC68681 Duart for i/o with has a 74ls138 for address decode and the other a gal chip.
both have dtack driven from a 74ls121 rom/ram/latches direct from the address decoder and the duart from the duarts dtack output which does have a pullup on it.
The Problem i can write to the duart without any problem i have 8 leds on the output port and can turn them on and off at will.
i can write to the transmit buffer and have chars show up on a connected pc but any attempt to read from the duart always returns 0xff so for instance to send a string
i have to insert short delays between chars or either nothing comes out or its garbled. trying to read any readable register also only ever returns 0xff
I have gone over the circuit several times and can find nothing wrong. R/W is wired directly to the cpu as are the address and data lines,
obviously the address decoders work as i can write to the chip just not read from it. i can change the cpu clock from 5mhz to 16mhz and the only thing that changes is the
amount of time i have to pause before sending a new char.
I am utterly lost at this point. all the buss and handshake signals are very clean on the scope if that is of any help.
my init code is like this...
MOVE.B #$00,ACR ; for 9600 N81
MOVE.B #$BB,CSRA ;
MOVE.B #$13,MR1A ;
MOVE.B #$17,MR2A ;
MOVE.B #$BB,CSRB ;
MOVE.B #$82,MR1B ; This is done 'inline' so that if the memory
MOVE.B #$1F,MR2B ; does not work we can g'tee that the uart can
MOVE.B #$05,CRA ; send an error message.
MOVE.B #$05,CRB ;
my byte out routine is like this....
;--------------------------------------
; Writes a character to Port A, blocking if not ready (Full buffer)
OUTCHAR: ; Takes a character in D1
move.w #$ff,D5 ; short delay
dbf D5,* ; as reading the status byte does NOT presently work...
btst #2,SRA ; Check if transmitter ready bit is set
beq OUTCHAR ;
move.b D1,TBA ; Transmit Character
rts ; and return from whence we came.
;--------------------------------------
