Dear List, This is a libserialport question, so I hope it is not out of place.
I am communicating with a proprietary device, and have a question about how to obtain responses. The device communicates in "messages", and each message from the device is a delimited string, separated by '\r'. I am trying to only read only one message at a time. I see that I can use a blocking read to obtain up to a certain number of chars, and within a timeout, from the port via sp_blocking_read. The problem is I don't know how many characters will be coming from the device in advance (I know the maximum, but it can be less). Is there any way I can have the read function return when a delimiter is reached? Either I have to implement my own buffer where we can detect and split up messages, or I've missed something in the docs. Thanks in advance! ------------------------------------------------------------------------------ BPM Camp - Free Virtual Workshop May 6th at 10am PDT/1PM EDT Develop your own process in accordance with the BPMN 2 standard Learn Process modeling best practices with Bonita BPM through live exercises http://www.bonitasoft.com/be-part-of-it/events/bpm-camp-virtual- event?utm_ source=Sourceforge_BPM_Camp_5_6_15&utm_medium=email&utm_campaign=VA_SF _______________________________________________ sigrok-devel mailing list sigrok-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/sigrok-devel