Hi,
I am porting an application from Windows, and in that application, I prefer NOT to read and send asynchronously. I want to control explicitly when to read and write to the serial port.
I can also tell the remote device to stop sending data, and at that time I flush all un-read data from the Serial Port.
So, my 2 questions are:
1
(a). How do I read data when I want (with blocking calls that I can set a TIMEOUT), and (if appropriate)
(b) send data when I want?
2. How do I flush all waiting data from the serial port?
Thanks
Dave
I am porting an application from Windows, and in that application, I prefer NOT to read and send asynchronously. I want to control explicitly when to read and write to the serial port.
I can also tell the remote device to stop sending data, and at that time I flush all un-read data from the Serial Port.
So, my 2 questions are:
1
(a). How do I read data when I want (with blocking calls that I can set a TIMEOUT), and (if appropriate)
(b) send data when I want?
2. How do I flush all waiting data from the serial port?
Thanks
Dave