10-15-2008 11:31 AM
I have a problem reading a serial device with DasyLab.
The analyser does deliver a set of data when I send the following signal:
#M?<CR><LF> (the latter is produced using \r\n --> #M?\r\n
The RS232 monitor is giving me the following result:
7.345µg/l 10.5l/h 36.5°C<CR><LF>
When I repeat the reading by sending the data request, the result is getting somewhat more complicated. I get the following result:
7.345µg/l 10.5l/h 36.5°C<CR><LF>
<LF>7.345µg/l 10.5l/h 36.5°C<CR><LF>
<LF>7.345µg/l 10.5l/h 36.5°C<CR><LF>
i.e. I get two line feeds in sequence. But I have problems picking out the 3 sets of data
<LF>7.345µg/l 10.5l/h 36.5°C<CR><LF>
==== === ===
Ch0 -^
Ch1 ---------------^
Ch2 ------------------------^
Unfortunately, the sets are of variable length...
It would be great if somebody can help me to find the correct settings.
Thank you in advance
Rudolf
10-16-2008 07:17 AM
I think that you need to use the space as a delimiter.
try this
7.345µg/l 10.5l/h 36.5°C<CR><LF>
ch 0: a\x20
ch 1: a\x20
ch 2: a\r\n\n
That should scan, find the numbers, and also skip the extra <LF>