I'm a member of a Formula SAE team and we use the Performance Electronics ECU which uses the CAN protocol with a speed of 250 kbit/s and works fine with our 2D Recording Systems Data logger, but we're trying to build a telemetry system which gathers the same data from the CAN bus using an Arduino Uno and CAN shield provided by SparkFun Electronics.
However the CAN shield we're trying to use has failed to initialise the communication with the bus. Kindly help me out on what can be done or are there any alternatives of communicating using CAN with Arduino?
P.S. The link for the CAN shield: CAN-Bus Shield Hookup Guide
-
Have you shecked the shield pins match the ECU connector pins? The shield is configured to match the pins on their OBDII->DB9 cable and may not match the "vanilla" CAN pinout. This will require desoldering jumperscrasic– crasic2016年02月18日 23:33:43 +00:00Commented Feb 18, 2016 at 23:33
-
You may also try to add termination to the BUScrasic– crasic2016年02月18日 23:50:12 +00:00Commented Feb 18, 2016 at 23:50
-
Hi Crasic, according to the schematic of the shield already has termination resistance to the bus, and regarding the connections, yes the ECU Connector pins match with the shield pins. Our data logger works fine but the shield isn't working. Also could you provide me with the info on ODBII-> DB9 cable and the "Vanilla" CAN Pinout. ThanksYashasvi Karnena– Yashasvi Karnena2016年02月20日 15:15:34 +00:00Commented Feb 20, 2016 at 15:15
-
I also forgot to tell that the communication protocol is SAEJ1939 and the Baud rate is 250KBPSYashasvi Karnena– Yashasvi Karnena2016年02月28日 19:41:26 +00:00Commented Feb 28, 2016 at 19:41
2 Answers 2
Beware, the industry standard pinout for CAN on DB9 connectors is different to what Sparkfun use on their shield:
- pin 3/5 CAN bus shield schematic
- pin 2/7 (Vector tools for example).
Which software have you been using on the Arduino? Any additional info on the ECU you're using, and the wiring in your system?
I found this wiki particularly useful: CAN-Bus Shield Wiki
And yes, like CQuinson said, you have to pay attention to the pins used. I know Sparkfun is known for having an issue with which pin the CS pin is assigned to (D9 or D10).