Hi
I’m using 9210ME and HTTPS Server Sample using the AWS.
By using the function tcgetbuffers(1, &BufferSERIAL) I can read the RX buffer count, but now I want to read the data in the RX buffer.
Is there a function that can return me those bytes received from serial port?
HI,
You should be able to get the data using read() as follows
int SIO_Receive(int hPort, unsigned int wSize, void *pData)
{
int iBytesRead;
/* Attempt to read from the serial port */
iBytesRead = read(hPort, pData, wSize);
/* If there are no characters ready read will return -1 so change it to 0 */
if (iBytesRead > 0) {
return iBytesRead;
}
return 0;
}
Is there a way to increase the RX buffer (it’s storing about 20 bytes, but I need at lest 30 bytes)?
Thanks rdeabill it’s work.