[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Read full 8-bit character from serial port?



I use these in the GameServer driver.  Seem to work for me just fine
even at 115.2k baud.

ACIA_Data = $c0a8
ACIA_Status = $c0a9
sendByte		;Sends byte to SSC (data is in X)
	.sendLoop	LDA ACIA_Status
				AND #$10
				BEQ .sendLoop
				STX ACIA_Data
				RTS
readByte		;Poll for next byte (returns in A)
				LDA ACIA_Status
				AND #$08
				BEQ readByte
				LDA ACIA_Data
				RTS