pyserial to read from DS1615 temperature recorder chip

Joe Knapka jk.usenet at kneuro.net
Mon Jul 24 18:07:06 EDT 2006


Grant Edwards wrote:

> On 2006-07-24, alexandre_irrthum at yahoo.com <alexandre_irrthum at yahoo.com> wrote:
> 
> 
>>>Logs of the serial traffic would be helpful.
>>
>>Here they are. First a log of the traffic generated by the
>>T-logger GUI program, abtained with Portmon.
> 
> 
> I try to avoid Windows as much as humanly possible, but one
> thing that appears to be different is that Tlogger clears RTS
> and your program sets it.  Try clearing RTS in your program
> when you set up the serial port.
> 
> If clearing RTS doesn't help, I guess I'd try different flow
> control settings (try enabling and disabling RTS/CTS flow
> control).
> 
> Since you're dealing with binary data, make sure that Xon/Xoff
> flow control is disabled.

It could also be a timing issue or handshaking problem.
Having to write to the chip "a byte at a time" implies
that it could take it a little while to digest each byte;
longer than the natural character time for the baud rate,
that is. I'm not sure if I'm reading the portmon output
correctly, but it looks like the "T-logger" program
is waiting for CTS (or possibly some other condition)
before sending each byte. The Python program does not
appear to be doing so, it's just sending the three bytes,
bang bang bang.

-- JK



More information about the Python-list mailing list