Thread View: alt.msdos.programmer
1 messages
1 total messages
Started by Don C. Hancock
Tue, 10 Nov 1992 01:52
Serial Driver Problems
Author: Don C. Hancock
Date: Tue, 10 Nov 1992 01:52
Date: Tue, 10 Nov 1992 01:52
38 lines
1813 bytes
1813 bytes
Serial Driver Problem I hope this is the right place for this. If not, please let me know. I'm trying to program the serial port to control some equipment. I can't seem to get it (i.e. the port) to generate interrupts (such as the data received, or transmitter empty) What am I doing wrong? Here's what I've done so far (briefly, sort of). 1. Replaced vector 0x0c with my interrupt service routine. I'm pretty sure this right, because a geninterrupt(0x0c) gets to my routine. 2. Set up the serial port to interrupt on everything but the modem status change by writing 0x07 to the interrupt enable register. 3. Set 8259 interrupt controller to enable interrupts from IRQ3 and IRQ4 with outp(0x21, inp(0x21) & 0xe7); 4. End my interrupt service routine with outp(0x20, 0x20). When I do a write followed by a read, I get the data I sent. I've done this using the loopback feature (set bit 4 of the modem control register) and by wiring pins 2 & 3 together, so the connections are right. I've also done the above for the second serial port, I just can't get the hardware to generate interrupts. Any ideas. I'll post (or email) code if it'll help me get an answer. Please email or post any replies (but email is preferred). Thanks for any help you can give me. I'm really troubled by this. I'm sure I'm doing something dumb here. Don
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads