Using Parallel Port for Switch Input
Posted on 1998-08-02
I'm trying to read switch input from the parallel port and am having trouble getting the input. I've opened the port using FILE streams on "PRN", and also tried to read from the port with _inp(), but I don't seem to be able to read any changes on the port when I activate the switch. I also havn't been able to verify that I've actually read the port since the uninitialized data in the buffer was not overwritten by the call to the read functions. This also might not be a programming problem, but a hardware problem. Right now, I'm just making connection between pins 2-9 and pin 25 trying to see a change on the port, but I'm not seeing it. Any suggestions on how to do this. Thanks.