Closed hayden-t closed 9 years ago
This will not cause OBD-II connection at all. It's a function provided by the data logger itself.
what i meant is that it is still trying to send ODB requests and interpret them regardless of if the ODB is connected or not.
int COBD::getVoltage()
{
char buf[OBD_RECV_BUF_SIZE];
write("ATRV\r");
byte n = receive(buf, 100);
ATRV is a custom command we implemented which does not initiate any OBD-II communication
so where is write("ATRV\r"); sending to ?
The battery voltage meter and GPS data is provided by the data logger hardware itself instead of vehicle ECU. We implement custom AT command like ATRV, ATGPS, ATGRR on top of standard ELM327 comamnd set.
Ok then why query it if its not connected ? (the battery voltage meter that is)
No OBD connection does not mean physically disconnected. This typically happens when ignition is off.
So are you saying its sampling the cars battery voltage from obd port pins other than the can bus ?
Yes I meant that.
ah ok, i get it now. though im thinking it should still have a config.h define to opt out if you dont want it filling up your logs ? like you do for the MEMS sensor. as i imagine it will be logging constantly even if the car is off ?
The sketch is provided as a demo/testing purpose. So it is good to let something work (LED flashing) even if OBD/GPS/MEMS is absent.
MEMS is always present ? and what do you mean demo/testing purposes ? its the only datalogger sketch that you provide ?
Also it can still be on by default like the it now and the MEMS is too, but there should be an option to turn it off in config.h
actually what would be even better would be to be able to specify the poll frequency as well
Hi, in commit 4efef6855a0a966cac896e194c1c626e303090e8 you uncommented
this is in the loop without any checks to see if obd active or not, this it is constantly being run and logged with an incorrect voltage ~ 0.398v
likely it doesnt need to be checked this regularly either
also curious why it needs its own function and isnt collected by logger.logOBDData();