It feels SO good to make progress... Finally!UPDATE NOV. 12 - 2007 - 11:30am - ELM Communication is working! It was as simple as sending the data inverted to the ELM. The ELM323 is intended to be hooked directly to a PC's serial port. serial data from a pc is sent inverted, and thus the ELM is set internally to deal with this data. The MAX232 converts the data back to non-inverted, so i simply needed to r-invert data in teh PIC. The board is SO close to actual in-car testing. I am still having issues with the MAX233 interface chip. I have spent hours trying to track down the gremlin in this chip, and i have come to the conclusion that the chip may just be bad. i have a few of them laying around, so i will switch it this week before in-car testing. The LCD is functioning. This was an easy fix. At one point, while trying to get the PIC working, i cut all the traces to the LCD. Once i discovered this, i simply resoldered all the cut sections, and blamo, it works. The initial code is certinly nothing fancy. Just a few test items to test the LCD and get output from the ELM. I have an e-mail out to elm electronics at the moment because i am having trouble getting coherent messages back from the ELM323. The only message i can recieve that makes sense is the startup message, which is "ELM323 V2.0 >." In theory, i should be able to send "ATI," followed by a carriage return, to the ELM and recieve its identification message back. I recieve data back, and for any given command it is always the same data, but it just makes no sense. Hopefully this is an easy fix. I feel it may be something in the transmission to the ELM, although i have checked this wiring plenty of times, and even cut out the trace and attached it with a jumper wire. I get the same results when using a direct connection to the PC via the max232. I REALLY hope this is not a problem with the ELM chip. This is a relatively expensive chip, and it has been sitting around for some time now. We shall see what they have to see.
Test CodeINITIAL TESTING CODE (PICBASIC PRO) (NOTE: must save with extension .pbp for use in PICBASIC Pro) If interested, here is the assembly language code generated after compilation, before compilation into HEX: INITIAL TEST CODE ASM FILE (NOTE: File extension changed from .asm to .txt) The initial test code is done in PICBASIC Pro. It is very simple to w ork with, and is a language i am farmiliar with. I am using this language for testing purposes only, as i know certain things work. The intention is to write the actual software for the OBD2 LCD in C. However, time constraints may force me to write the code in picbasic. Also, the more low-level nature of PICBASIC PRO is more fun then the higher level C. For more info on the PICBASIC Pro compiler, click here. Click READ MORE for a short video of the LCD starting up, and me talking about it! |