Help with M84, Arduino and CAN bus

Discussion and support for MoTeC's previous generation of entry level ECUs

Help with M84, Arduino and CAN bus

Postby acca on Fri Mar 01, 2024 2:42 am

Hello,
I'm trying to make a dashboard using an esp32 (arduino) and SN65HVD230DR can transceiver, using Twai library :
https://docs.espressif.com/projects/esp ... /twai.html

In CAN normal mode, i can read and decode CAN data and write it to serial console, but as soon as i plug the CAN UTC, the serial becomes very slow and M84 software says 'ECU not connected", if i unplug the arduino, ECU can connect to M84 software.

I tried listen_only mode, but it doesn't seems to work at all.

Could someone help me to find the solution please ?
Thanks
acca
 
Posts: 31
Joined: Tue Apr 30, 2013 4:08 am

Re: Help with M84, Arduino and CAN bus

Postby David Ferguson on Fri Mar 01, 2024 5:18 am

A CAN UTC has a built-in terminating resistor. I suspect your CAN bus is over-terminated. With everything connected (including UTC, M84 and Arduino), what resistance do you measure between CAN Hi and CAN Lo?

What do you measure when the UTC is removed?

Are their possibly other devices on the CAN bus that could have a termination resistor connected between CAN Hi and CAN Lo?
David Ferguson
Veracity Racing Data
David Ferguson
Pro User
 
Posts: 1383
Joined: Fri Nov 07, 2008 2:45 am
Location: Paso Robles, California

Re: Help with M84, Arduino and CAN bus

Postby acca on Fri Mar 01, 2024 6:11 am

I'll measure resistance tomorrow, but I already removed resistor from esp32
I have three things on the canbus : m84, UTC and esp32
If I just power down the esp32, the esp32 communicates
If I close m84 software, esp32 communicates
Does it looks like a resistor problem ?
acca
 
Posts: 31
Joined: Tue Apr 30, 2013 4:08 am

Re: Help with M84, Arduino and CAN bus

Postby acca on Fri Mar 01, 2024 6:58 am

Could my problem come from incorrect bitrate ?
I'm using 500KBITS
acca
 
Posts: 31
Joined: Tue Apr 30, 2013 4:08 am

Re: Help with M84, Arduino and CAN bus

Postby Stephen Dean on Fri Mar 01, 2024 1:20 pm

Hi,

If you connect just the UTC without the M84 Manager running, does it slow the CAN bus down? Running the M84 Manager on a 500K bus will work, but a fair percentage of the available bandwidth is used by the communications between the M84 Manager and the M84, Is there a reason why you are using 500K?
Stephen Dean
MoTeC Research Centre Melbourne, Australia
User avatar
Stephen Dean
Site Admin
 
Posts: 1726
Joined: Tue Dec 02, 2014 10:29 am
Location: Melbourne

Re: Help with M84, Arduino and CAN bus

Postby acca on Fri Mar 01, 2024 6:37 pm

Hi,
The problem was the bus speed, setting bus speed to 1MBps solved this problem
Thank you very much
acca
 
Posts: 31
Joined: Tue Apr 30, 2013 4:08 am


Return to M84 ECUs

Who is online

Users browsing this forum: No registered users and 2 guests