Page 2 of 5 FirstFirst 12345 LastLast
Results 11 to 20 of 42

Thread: Hacking the Can Bus

  1. #11
    Raw Wave pierrotm777's Avatar
    Join Date
    May 2008
    Location
    Bordeaux, France
    Posts
    2,856
    Quote Originally Posted by rtgree01 View Post
    I have a 2007 Dodge Charger... I've decoded many of the CAN messages on the interior (comfort) bus. I got a lot of information at www.canhack.org.
    Here is my worklog

    I'm using an mbed microcontroller . I designed a breakout board that gives me access to most of the peripherals.
    Can you say us more about this project with by example a new thread ?

  2. #12
    Raw Wave pierrotm777's Avatar
    Join Date
    May 2008
    Location
    Bordeaux, France
    Posts
    2,856
    Quote Originally Posted by Goddy View Post
    I think I should get myself an Arduino + CAN bus shield and will play around with it.

    I gathered some helpful links

    http://www2.dasilvas.info/home/steering-wheel-buttons
    http://secuduino.blogspot.nl/2011/10...a-english.html

    As from the first link you can see it uses 2 wires only. Do you think it needs the CAN BUS low and high without the ground, it will it use only can low and ground?

    Is it also possible with the Arduino to write a code to receive AND send commands? It would be great if I'm able to read steering wheel control buttons and possible update the DIS with useful info.
    Very cool links !!!

  3. #13
    Constant Bitrate
    Join Date
    Jul 2009
    Posts
    176
    Nice job rtgree01 with your install. I was looking at the mbed stuff as well. There are many ways to work with CAN BUS, I even seen some CAN BUS stuff built with the Raspberry Pi. You're more than welcome to use this thread for details of your CAN BUS integration as it fits with the title and this thread wasn't meant to be just about my implementation.

    Goddy

    Yes there are different networks in the car. My car has the Drive train, Comfort and infortainment busses. Some other VW's just have Drive Train and Comfort busses. Also some information is shared between the busses. You will have to poke around to see what's available.

  4. #14
    Constant Bitrate Goddy's Avatar
    Join Date
    Dec 2004
    Location
    Netherlands
    Posts
    151
    Great, just ordered an Arduino One, a can bus shield and some kind of extended starters kit with tons of components. Can't wait to play around with it and start sniffing the bus. There are lots of possibilities with it.

  5. #15
    Low Bitrate
    Join Date
    Oct 2008
    Location
    Wiltshire, UK
    Posts
    63
    I've been doing the same with a BMW,
    I had also been doing all of my reverse engineering using an Arduino with a Canbus shield. I have now made my own version of this with the ATMEGA and CANBUS drivers.
    For more information on my BMW work please see these links:-

    http://www.mp3car.com/engine-managem...e84-k-can.html
    http://www.mp3car.com/road-runner/15...k-can-bus.html

    The little board I have made is shown below. I have been testing this for the past week in my car and it seems very stable. Essentially this is exactly the same as the Arduino with canbus shield, it's just a bit smaller



    If you are using an Arduino with the Sparkfun Canbus Stack then writing back to the can bus is quite simple, you only need to send the ID, length and the relevant data packets. I can strobe the interior light with the routine / loop below.

    Write 1E3 02 F1 FF
    Delay 100mS
    Write 1E3 02 F0 FF
    Delay 500mS

    If you are using the Sparkfun Can bus Stack with a BMW then you will need to add the line below to the Canbus.h file
    #define CANSPEED_100 9 // CAN speed at 100 kbps

    In case it is of use to anyone, I have uploaded the Arduino code and the library I use for streaming Canbus commands at the link below:-
    http://www.loopybunny.co.uk/temp/Kcan.zip
    The Canbus directory will need to be copied into the libraries directory of Arduino.

    This is working with Arduino 0022. (You will need to change the name of some of the includes if you want to work with Rev 1.01 or later)
    Note that I haven't included the code for writing back to the bus in this sketch. I haven't tidied that bit up yet!

  6. #16
    Constant Bitrate
    Join Date
    Jul 2009
    Posts
    176
    Nice board Trevor. Small and compact, I can see plenty of uses for it. I'm thinking of adding Can Bus to my monitor to control things like backlight settings, input selection for reverse camera and a few other things. A board that size would be perfect for that.

  7. #17
    Constant Bitrate Goddy's Avatar
    Join Date
    Dec 2004
    Location
    Netherlands
    Posts
    151
    Anyone knows where I can find the can.h library of the projects that's being used here: http://secuduino.blogspot.nl/2011/10...a-english.html ?

    Searched everywhere, downloaded tons of CAN libraries but they weren't the one. That library seems to be very easy and spot on.

  8. #18
    Constant Bitrate
    Join Date
    Jul 2009
    Posts
    176
    Quote Originally Posted by Goddy View Post
    Anyone knows where I can find the can.h library of the projects that's being used here: http://secuduino.blogspot.nl/2011/10...a-english.html ?

    Searched everywhere, downloaded tons of CAN libraries but they weren't the one. That library seems to be very easy and spot on.

    I contacted them about that file when I first started and was told that they only provide that file if you purchase their Can Bus shield. I believe someone did post a copy of it on the Arduino.cc forums a few months back but I don't have the exact link.

    Also I've seen good things about the Can Bus library from here too. It may be the same one from secuduino
    Last edited by that_kid; 01-19-2013 at 06:26 PM.

  9. #19
    Constant Bitrate Goddy's Avatar
    Join Date
    Dec 2004
    Location
    Netherlands
    Posts
    151
    If someone has that specific library I would be really thankful. It seems very easy and straightforward.

  10. #20
    Low Bitrate rtgree01's Avatar
    Join Date
    Aug 2007
    Location
    STL
    Posts
    98
    Here is some information about what I have done on my car...

    Originally, I used a CANUSB device. It worked well, but required the computer to do anything. I was able to record and decode all the messages required to control the OEM amplifier and Sirius satellite radio, and then I decoded some of the other messages as well. First, I used some software from canhack.org that recorded all the messages to a sql database. That helped me figure out most everything I know.... I was able to then write some messages back to the can bus. I can lock/unlock the car doors, pop the trunk open, among other things. I also wrote a plugin for RideRunner to do everything in an integrated way. It worked well, until I tried to fix a ground loop.... fried the CANUSB device...

    So I found the mbed microcontroller. It hardly needs any extra components to do CAN, and has a ton of other features.... USB host and device, ethernet, serial, i2c, digital in/outs, analog in/out.... All without really requiring many extra components. I breadboarded a design and got everything to work again.... Then I got to work making it work in a standalone manner... and then set about doing the communication over ethernet (multicast). I updated my plugins (amplifier control/steering wheel controls, sirius audio input). I also wrote a couple of apps to watch the data come in live... telling me when any value changes. I also wrote a utility that is similar to Wireshark... I can specify the what bits do what, and then chart them over time.

    There are a few downsides to my mbed design. It needs a regulated power supply. Also, it is not a low power device. It will run down the car battery over time. To fix that, I will need a smaller, lower power, simpler microcontroller. I'm not going to fix that in my next revision.... at least not yet.

    If people are interested, I have the eagle schematic and bill of materials for my current board. It is really only a break out board, but it has worked for nearly a year. I can also provide my RideRunner plugins.

Page 2 of 5 FirstFirst 12345 LastLast

Similar Threads

  1. hacking a printer's LCD
    By natedawgg in forum LCD/Display
    Replies: 3
    Last Post: 03-19-2009, 03:48 PM
  2. Hacking Iguidance
    By Peoples in forum GPS
    Replies: 74
    Last Post: 08-28-2005, 07:40 PM
  3. Hacking Irman
    By Cheekz185 in forum Input Devices
    Replies: 3
    Last Post: 07-13-2005, 01:18 PM
  4. no TS, no hacking, which to buy?
    By DaddyZ in forum LCD/Display
    Replies: 5
    Last Post: 12-09-2004, 11:55 AM
  5. Frodo: 1.0.9 Hacking.
    By hevnsnt in forum FrodoPlayer
    Replies: 7
    Last Post: 10-17-2004, 06:54 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •