Shop OBEX P1 Docs P2 Docs Learn Events
Basic stamp and OBD-2 — Parallax Forums

Basic stamp and OBD-2

RobbanRobban Posts: 124
edited 2006-11-16 15:17 in BASIC Stamp
Hi!

I am planning to attach a OBD-2 (Car diagnostic computer) to a basic stamp 2.
Whith the OBD-2 you can read errormessege..diagnostic of the car like speed,rpm,temp etc by attaching a laptop by the seriell port to the contact in the car.
I would now like to connect a basic stamp and "mask" out several values.

has anyone tried this?

regards
Robban
·

Comments

  • Kevin WoodKevin Wood Posts: 1,266
    edited 2006-10-02 13:08
    Will you be connecting the BS2 between the ODB-2 reader and a laptop? If so, and you only want to mask out certain values, it would probably be easier to use the laptop to do the masking. Using the laptop, you would need to write a program or script that would receive the input from the reader, then process it to take out what you don't want.

    If you are building a portable device with the BS2 to bypass the need for a laptop, you'll need to write 2 programs - one to interface the reader & BS2, and one to interface the BS2 & computer.

    But generally speaking, if you're dealing with a standard serial connection, you should be able to do it. The more info you have about the device you're using, the easier it will be to build the interface.
  • RobbanRobban Posts: 124
    edited 2006-10-03 17:19
    no,i would connect the basic stamp directly to the ODB...no laptop
  • Bruce BatesBruce Bates Posts: 3,045
    edited 2006-10-03 18:02
    Robban and Kevin -

    As far as I am aware, no PBASIC Stamp can read any OBD codes directly. Usually one uses an OBD to RS-232 converter, and then one reads the output from the RS-232 converter. There are a number of OBD interfaces available depending on the make/model of the vehicle, as each is different, depending on the original encoding. To my knowledge there is no Universal OBD to RS-232 interface.

    If you need more specific information, I can probably dig it up for you.

    Regards,

    Bruce Bates

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    <!--StartFragment -->
  • steve_bsteve_b Posts: 1,563
    edited 2006-10-04 16:14
    There are certainly some fancy IC's out there for interfacing to OBD2/CAN. I went the cheap way and picked up an RS232 to OBD2 (chrysler vehicles) from ELM electronics.
    http://www.elmelectronics.com/connect.html#ELM320

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    ·

    Steve

    "Inside each and every one of us is our one, true authentic swing. Something we was born with. Something that's ours and ours alone. Something that can't be learned... something that's got to be remembered."
  • HulkHulk Posts: 68
    edited 2006-10-05 00:33
    Thanks for posting that link, Steve!· It looks like they've made it easy for us to have access to the OBD system.

    I'm foggy on CAN, but interested.· Is the OBD2 a special instance of CAN implementation?· Could the chips from Elm Electronics be used to communicate on any CAN bus?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    8184265-56bd-00410041-.jpg

    Basic stamp Newbie
  • JonathanJonathan Posts: 1,023
    edited 2006-10-05 00:39
    I've used the ELM chips and am very happy with them and the docs that come with them. Last time I was on the site it said that they are developing a CAN chip, but it wasn't (at that time) out yet. The other chips will NOT work with CAN, for sure.

    Jonathan

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    www.madlabs.info - Home of the Hydrogen Fuel Cell Robot
  • RobbanRobban Posts: 124
    edited 2006-10-22 08:57
    i guess that you understood me...i will buy the nodule from elmelectronics and from this one connect a basic stamp 2.
    Is it possible to program the stamp to retrieve several data?
  • steve_bsteve_b Posts: 1,563
    edited 2006-11-16 15:17
    Robban,

    saw your post in the duplicate thread....

    You purchased the ELM IC for OBD2 interfacing....there is an associated circuit that goes with the IC...did you build this?
    You should be able to connect a laptop and through a terminal program (Hyperterminal) you should be able to get some communications with the IC (some sort of prompt...can't quite remember).
    This is the first step....the rest of it is serial handling between the stamp and the IC. Remember that nothing is buffered, so while you're processing a serial string in the stamp, you could be missing information. You might look at the propellor or even just an SX to get the speed advantage to 'hopefully' avoid missing data.

    I bought my ELM IC....built the interface circuit and connect it to my laptop. But I never did get around to plugging it in to my Jeep (winter had arrived and the project got shelved)....
    It's still shelved and not likely to make it out as the crappy weather is here for us up north!

    Have you done much for Stamp programming?
    Go through the sample code and free online documents/tutorials. There's a wealth of information there to help you get started (although not directly related to your project).
    If you have more than one stamp, set up one stamp to output a serial message....then work on the 2nd stamp to try and ingest it and do something with it and then go back for more. Gets your timing down.

    Let us know how you do!

    cheers

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    ·

    Steve

    "Inside each and every one of us is our one, true authentic swing. Something we was born with. Something that's ours and ours alone. Something that can't be learned... something that's got to be remembered."
Sign In or Register to comment.