Is there any terminial command I can use to set the polling interval on an elm327 device? I know that for example obdwiz allows setting the polling interval through it's graphical interface, but I want to do it manually from the command terminal.


So it seems that it's only Elm327 adapters that use a FTDI serial to usb adapter chip that have these latency problems:

The FTDI can’t send a USB packet to the computer for every byte that comes from the Arduino’s microcontroller. Instead, it stores the serial data in an internal buffer and only sends a USB packet when the buffer is full, or after a period of time has elapsed. This period of time is determined by the FTDI Latency Timer, which is the reason why FTDI chips can give bad latency characteristics.

On Linux & Windows, the default latency timer setting is 16ms.

So basically, taking into account both the data request and the response you are automatically taking a 32ms hit round trip.

Luckily, the latency can be reduced to 1ms. The above link explains how to do that for a variety of operating systems.

The ForScan software has a visual tutorial on how to do it in Windows.

| improve this answer | |
  • How is this related, this is for reducing the time an actual request-response cycle takes, not for increasing the polling rate. – I have no idea what I'm doing Nov 13 '15 at 14:22

Polling interval is simply how often you request data from the port. There is a hardware side baud rate that you must meet (probably 38400bps for ELM327) and usually you cannot change that as it is determined by the protocol.

The software you mentioned simply lets you set the rate at which you send/receive data bits to meet this requirement (there are multiple standards). If you use a terminal application then it should let you set the baudrate.

EDIT: If it actually lets you set the polling interval then it simply changes the frequency at which it inquires the port, it is fully software dependent.

| improve this answer | |
  • So if my vehicle uses J1850 PWM at 41.6 Kb/s. If you're monitoring a single pid using this protocol, how often does a data sample go by on the wire? It seems like about 2 bytes would go by on the wire every millisecond. So really, there's going to be a new data sample available on the wire at least every few milliseconds taking into account packet overhead. So basically the adapter needs to be able to take samples around every 5ms to get the full use of the bus. And I guess the software controls how often the adapter takes a sample? – Robert S. Barnes Nov 9 '15 at 10:31
  • The actual data sampling rate is independent from the baud rate, but obviously should be lower than it. Baud rate is basically how fast data bits are sent, but pid data makes up multiple bits and is only part of the protocol. You should be free to sample as fast as you want as long as you are not approaching the baud rate, which should be difficult to do at 41.6 Kb/s. No commercial software I've used lets the user choose the sampling rate, it simply does it several times a second by default. – I have no idea what I'm doing Nov 9 '15 at 11:35
  • The scantool.net OBDWiz software let's you set the data polling interval. – Robert S. Barnes Nov 9 '15 at 20:16
  • That's great, I might give it a try myself, the software I use is too slow for me. Basically what it does is when you set a higher polling interval it sends the commands more often, but not at a faster baudrate. The baudrate should always be the same on both the sending and receiving side. – I have no idea what I'm doing Nov 10 '15 at 8:45
  • Basically the polling interval is a software side parameter that is accomplished using timers. You'll have to write a basic program if you want to poll at a certain rate. – I have no idea what I'm doing Nov 10 '15 at 8:53

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.