Other Parts Discussed in Thread: CC2640
Hi!
Trying to use HW flow control. Somewhat miffed with the HW flow control behaviour.
Currently, if flow control is enabled, then RTS is set low ("Accepting incoming data") as soon as UART_open() is called. This, however, is utter lies, as in reality, the peripheral is only ready to receive data when UART_read() has been called, and will automatically disable reading on many occasions: Timeout, break, etc. On all of these occasions, RTS will remain low, and the other party will happily send data into the void without anyone the wiser.
Also, this means that to receive URC-s (Unsolicited responses, i.e. I don't know when they will come) from an AT modem, I bloody well HAVE to keep the CC2640 out of standby (By keeping it "reading"), as there's no way to signal to the modem that "I'm not accepting data right now, wait until I'm ready" (aka: flow control).
Is modifying the driver to disable RTS flow control on disableRX and enabling it again on enableRX the only way to make it behave? Am I missing a better way to acieve low power AND ability to receive random messages?
I can't use the "wakeup on dummy byte" solution, as I don't control the protocol, and the wakeup time of the CC2640 (according to the datasheet at least) is on the order of char lengths at 115200 baud.