mbed CAN-Bus Demo board

14 Jul 2010 . Edited: 21 Jul 2010

This board is to demonstrate the CAN-Bus feature of the mbed module. The CAN connection is via a standard 9-way sub-D for use with OBDII cable. Ideal for automative CAN application. It also has a connector for a GPS module and an uSD card holder. On board 5v regulator, no need to power from USB.

http://www.skpang.co.uk/catalog/product_info.php?products_id=741

 

Features

  • 2x16 LED backlit display
  • On board 5v regulator
  • Can be power from 9pin sub-D connector or external 9v, no need for USB power
  • 5 way joystick menu navigation
  • Socket for EM406 GPS module
  • uSD card holder

 

14 Jul 2010

Looks great!

Two questions:

  1. Which cable is used in the shown setup?
  2. Is there a source code example for the shown setup?
15 Jul 2010

This board looks very nice.  Is there a CAN termination resistor on this board?

15 Jul 2010

The schematics shows a 120R jumper selectable resistor.

http://www.skpang.co.uk/catalog/images/mbed/mbed_rev_B.pdf

15 Jul 2010

Yes, there is a 120R resistor via a jumper but the default is not made.

29 Sep 2010

Hello

I've a question about the program. Evertime i want to start it (in the car) there is no message or anything on the display. I hope you can help me.

 

Ps. I'm sorry if my English is not very well (I'm from Austria)

29 Sep 2010

What is the make/model/year of your car?

Have you checked the connection to your car?

29 Sep 2010

It's a Citroen Xsara Picasso and it was built between 2005 and 2006.

29 Sep 2010

I have a new Citroen C3 Picasso. I develop a program that read the rpm of the engine.

The problem is that citroen use other can bus message protocol.

I have more info about citroen canbus , please send me a private message if you want.

it is a demo, with dirty code.sorry

I hope that helps you

C3picasso

30 Sep 2010

Ok might this is the problem but your programm doesn't work too.

31 Dec 2010

Ok so first of all I'm a complete noob.

I have very little C++ experience, so thought that this would be a good hands on project to try and get my head around learning more about the MBED. (can't believe how easy most stuff is on the MBED and can't recommend it high enough)

I've managed to get this working sort of with my car, but can't get the throttle position to work, or any other alternatives. I've also tried setting for the fuel level using the PID table but all I get is a blank area on the LCD.

It would appear that the IF statement is not trigerring.

At first I thought that it was down to a missing break statement in the ecu_reader.cpp file but that didn't fix it. I haven't changed any of the other parameters i.e Baud rate, and haven't tried disconnecting the Jumper as I'm not sure what its purpose is.

Has anyone else experienced this and got any suggestions as to why the RPM, Temp and Speed would work but not throttle.

03 Jan 2011

It would appear that this has nothing to do with the MBED or the code but which PID's are supported by the vehicle.

Mode
(hex)
PID
(hex)
Data bytes returned Description Min value Max value Units Formula
01 00 4 PIDs supported [01 - 20] Bit encoded [A7..D0] == [PID 0x01..PID 0x20]

I managed in the end to understand the hex reply for the above and it would appear that the functions I was trying to pull were not supported.

I've checked against other supported functions, which appear to be working correctly, so just looks like BMW decided not to support these as standard codes and have probably put them in as non standard PID's which I can find very little info on. So if anyone has any info on non standard PID's it would be much appreciated.

04 Jan 2011

Greetings

Over the weekend I tried to connect my CAN-bus demo board to my 2004 Audi A4 (B6) .... The board powered up, I moved the joy stick forward to break the loop, the screen goes blank and I don't get any readings.

After a lot of surfing I discovered my Audi does not have a direct OBDII CAN connection, it uses an apparently older ISO 9141-2 (K & L) lines (pin 7 and pin15)






Pin 2 - J1850 Bus+
Pin 4 - Chassis Ground
Pin 5 - Signal Ground
Pin 6 - CAN High (J-2284)
Pin 7 - ISO 9141-2 K Line
Pin 10 - J1850 Bus
Pin 14 - CAN Low (J-2284)
Pin 15 - ISO 9141-2 L Line
Pin 16 - Battery Power


Looking at the OBD connector on my Audi, the red circles are where the CAN_H and CAN_L lines are missing...and the green circles are where the "K Lines" are present.



 

 

 

 

 

 

.

Any ideas how I would capture the OBD data using my mbed CAN-bus demo board? Is it even possible?

Thanks

 

17 Jan 2011

Your 2004 A4 probably uses the KWP-1821 protocol. You still can use the CAN-demo board you need to add a ISO9141 driver chip such as SI9241 or MC33290D. This driver chip will give you the K line output. You need to connect the chip to the UART of the mbed.

I've done a project many years ago using the PIC16F877. http://www.skpang.co.uk/content/view/12/32/

http://www.skpang.co.uk/images/group4.jpg http://www.skpang.co.uk/images/group115.jpg http://www.skpang.co.uk/images/group117.jpg

19 Jan 2011

Hi Sukkin

Thanks for the reply!!, will give it a go over the weekend

Cheers

Bruce

14 Feb 2011

Hi Sukkin,

I would like to ask you for your idea to use CAN application above for connection directly on engine ECU. I am thinking to use mbed for reading CAN from there because I would like to use it on two different cars where one is SKODA OCTAVIA 2000 (no CAN in diag connector) and SKODA FABIA RS 2007 where is CAN in diag but I will use also "direct" CAN of engine ECU.

Thanks for your help

PS: I tried your CAN-BUS Arduino shield and wasn´t able to see any value (tested on 5 different cars WV,AUDI,SKODA from 2005 mfg).

15 Feb 2011

I have one more question:

Is it possible to use mbed with PCA82C250 instead of MCP2551 with same Example code?

Thanks for help Pavel

15 Feb 2011

Hi Pavel,

For non-CAN cars you need to port this project to the mbed. http://www.skpang.co.uk/content/view/12/32/

The CAN-Bus might not work on all cars if they are not OBDII compliant. I don't have access to a VAG car at the moment so I can't try it out. Try it on another make.

You should be able to use the PCA82C250 but make sure you tie the control pins to the correct level.

16 Mar 2011

hello there

Is there any way to correct the accuracy of the EM406 GPS module which could work with this board.

thanks

03 Nov 2011

Hi there, I've tried to connect this to a "53" plate skoda fabia and a "02" corsa. I'm getting the same problem with both. The menu comes up but when I select the CAN option I just get black screen. Need some series help with this.

Thanks in advance Louis

08 Apr 2012

Hi Sukkin,

Regarding the can bus demo board, I need to use mbed pin 18 for analog output and mbed pins 15-17, and pin 19 for analog input. I intend to set pin 20 low so nothing gets clocked into the display. Unfortunately, the pins I need for analog I/O are currently tied to the display (which I don't need). If I don't link in the display libraries, is there any problem with me using the other pins that are hooked up to the CAN-Bus demo board LED display for my own purposes as described? In other words, will the display harm analog signals on those lines. So long as the LED board doesn't harm the inputs of the aforementioned pins, I don't care what the display does while I am using the system.

Thank you.