I’m having a problem with an application I’m developing.
I’ve got a PIC microcontroller circuit (motor controller) that I’m communicating with my QNX c++ code. Occasionally the QNX application locks up. I’ll Cntrl-C out, try and restart it and still nothing. If I restart the serial port device driver (devc-ser8250 -b 9600), then it works fine for a while.
My guess is there’s something in my circuit that is sending a bad signal/voltage spike that is locking up the serial port (anything that’s home brewed is usually my first guess). I don’t seem to have this problem with other serial port devices. But the PIC circuit is running fine (still streaming data over the serial port), it’s just that the serial port driver stops, which sounds like a QNX issue.
I’m not sure if it’s a PIC/hardware issue or QNX issue (or both).
So I have a couple of questions:
- Any ideas on what sort of communication problem would cause the serial port to lock up (so I can see if there is a problem on the PIC side)?
- Alternately, is there a way in the c++ code to check if there is a problem with the driver and restart it?
Thanks,
Mike