I am trying to locate the UART in RAM and it is not working. I have a '486 running windows 3.1.1 and using Microsoft quick basic.
This code prints numbers which are supposed to change when the com2 uart sees a change to its handshake lines. It does not respond when I apply a minus 3V to the four handshaking lines.
REM Psnoop.bas looks at serial port addresses
'WARNING AVOID location 238 = hex EE it causes a shutdown and restart. I do not know why.
'com1 03f8, com2 02f8, com3 3e8, com4 2e8
'Pick COM2 since COM1 is broken..
'Ports directory: 8 data, 9 irc, a irdat, b lc, c handshake t, d handshake t, e handshake r, f scratch
DEF SEG = 0
'com2 &H2F8= 760, KBD= &H60= 96, Clock &H70 = 112 None of these work.
PRINT "Reading RAM."
a = 760
FOR j = 1 TO 40 'Keep looking 40 times for a change while I plug in wires to pins.
FOR i = 0 TO 7 ' Reads all 8 registers in the UART
x% = INP(a + i) 'PEEK does not work here. Input does
SLEEP 2 'Give me a chance to look at the screen.