brendan-w / python-OBD

OBD-II serial module for reading engine data
GNU General Public License v2.0
1.02k stars 360 forks source link

Support slow OBD adapters #215

Closed Ircama closed 3 years ago

Ircama commented 3 years ago

Increase "0100" query (PIDS_A) timeout to support inexpensive/slow OBDII adapters.

This patch fixes the case in which "SEARCHING" is not shown after "0100", due to slow response of cheap devices.

[obd.elm327] write: '0100\r'
[obd.elm327] read: b'SEARCHING...\r...

It should also fix the case in which the debug mode needs to be active: in fact the debug logs might slow down the query timeout enough to be able to catch the query answer.

Reference #205

Reference #200

Reference #187