I made changes in the mbed WncController library to support unsolicited message "@SOCKDATAIND" for indicating availability of data on a socket for subsequent read. It seems that the modem never sends the unsolicited message "@SOCKDATAIND". I have to explicitly call "AT@SOCKREAD" to read data from a socket which blocks the calling function until data is available or a timeout. In my application, there are 2 separated RTOS threads, one writing to the WNC socket and the other reading from the same WNC socket. When the read thread is blocked on a read WNC socket operation (waiting for data or timeout), the write thread does not get a chance to send any data on that WNC socket. To get around this problem, I wanted to implement support for unsolicited "@SOCKDATAIND" message, so that I could call a read on the socket only when data is actually available, which ensures that the read thread won't block until timeout.
Thu, 06/01/2017 - 20:09