![]() |
I'm hoping to get the money together soon to start building mine and figuring out mounting location. I also need to get an obd2 splitter so i can hopefully keep the use of my p3 gauge
Sent from my iPhone using Tapatalk |
I think I figured out the oil temp thing.
I think I send it "07E02101" and get back a 29 byte answer and use the 29th byte (aka "AC" (which, as an aside was something I was being dense about until last night. The numbering system for returns is documented as A=1, B=2,...,AA=27, AB=28, AC=29) and subtract 40 to get oil temp in C. I'll try it later tonight. (If this works then I can also probably get that fuel tank level thing working as well.) |
Hi robot,
it should be the last byte in the message, see my code: http://mbed.org/users/chrta/code/Obd...emperature.cpp Since i do the CAN message decoding on my own, my packet data length may differ from yours. BTW: I will use this display http://www.adafruit.com/products/1431 (1,5" OLED) |
|
Quote:
It turns out the PID is actually a CAN one and I was reading it wrong because the ELM command set returns it with numbered "stanzas" and not just in one long string. |
Quote:
When I plug it into the Arduino Leonardo, I can get it to work fine for my application, but I dont have enough EEPROM for the SDCard library. So I got a Mega, and the shield doesnt "just work" like it did with the Leo & UTFT Lib. So now I want to get it to work in serial mode, but havent messed with it much. If I could get that working I would try to get the touchscreen to work for very basic gestures. |
Quote:
https://learn.adafruit.com/1-8-tft-d...eed-spi-wiring Shows you the different pins. The rest of the tutorial is probably not helpful for your setup. "On Atmega 328/168/8 type Arduinos ('classic' type) the hardware SPI pins are 11 (MOSI), 13 (SCK) and 10 (CS). For Megas it is 51 (MOSI), 52 (SCK), and 53 (CS). The CS pin can be a different pin but if you use any other pin you must still have the hardware SPI CS pin (10 or 53) as an output!" |
I got oil temp working. It was a pain.
Code:
Serial1.println("AT SH 7E0"); |
http://www.gps-laptimer-forum.de/vie...hp?f=20&t=1364
The one jpg link in the thread is a screenshot of someone with a prog querying the ecu for what pids it supports. ECT is supported. ECT is engine coolant temp. I must be doing something wrong. I bet there is still data in a buffer or something when I start reading the coolant temp and the offset messes it all up. |
robot,
Curious - Have you looked at using a droid phone as the interface/display unit for the arduino? I see that there is a USB HOST library for Droid, but I havent dug into it much. I think that would be an excellent choice for these purposes as almost everyone has an old droid smart phone laying around. Then from the Arduino's poit of view, all IO is just through the Serial IF (no need for the UTFT lib.) |
If anyone is interested I could use some help. I'm stuck on the timing of the OBD II UART device. I sort of, almost have readings working from all of the PIDs. They just aren't working one after the other.
|
How fast is your refresh rate? I'm polling at around 30ms period for rpm without any issues.
Sent from my Nexus 4 using Tapatalk |
Quote:
Depending on how I have things set up I start of with no readings and then after looping through several pages I get readings ok. OR I get readings from everything but the water temp. I'm kind of confused at the moment and should probably do some code cleanup to help things out. I did find this...and it was extremely helpful: https://forum.sparkfun.com/viewtopic...32457&start=60 (it's the post by rocketboy...it's basically a way for you to type commands in from a serial monitor and see the responses.) http://forum.arduino.cc/index.php?topic=258730.0 is my call for help on the Arduino forums. I should have studied more CS in school. |
Anytime I have timing issues, I usually relax all timings. For CAN, the identifier ID also relates to priority. The higher the number, the lower the priority. If you're reading all values by sending out a request for each value, I suggest increasing your loop delay.
Sent from my Nexus 4 using Tapatalk |
| All times are GMT -4. The time now is 01:26 AM. |
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
User Alert System provided by
Advanced User Tagging v3.3.0 (Lite) -
vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.