FlexCAN_T4.h - Detecting If Canbus Chip Is present

donperryjm

Well-known member
Hey guys, I have a device with some menu items and one of them is a canbus menu.
I want only the devices that have the SN65H CAN chip to see that menu.

Is there any way I can code this?
 
I'd look for some signal on the SN65H that is "active" only when the chip is present & route that into a Teensy input pin (be aware of 3.3V levels), thus detecting the presence of the SN65H. I haven't looked at the pins on that chip, so I can't give a specific recommendation.

Mark J Culross
KD5RXT
 
OK, but there is no way to make changes to hardware at this point. It's in production and in use. I have a firmware update that only canbus devices should get. Don't want to be doing two firmware and leaving it up to the client to decide.
 
Not totally sure if this will work, so just brainstorming here.

The CAN bus transceiver receive pin going to the Teensy is always being driven either HIGH or LOW. If there is no CAN bus activity or it is disconnected, the output is driven LOW.

Perhaps in your software, you can set the pin as input with pullup. If it reads HIGH there is no transceiver installed because the weak pullup can pull the signal high and if it reads LOW there is a transceiver on board pulling the signal LOW.
 
Not totally sure if this will work, so just brainstorming here.

The CAN bus transceiver receive pin going to the Teensy is always being driven either HIGH or LOW. If there is no CAN bus activity or it is disconnected, the output is driven LOW.

Perhaps in your software, you can set the pin as input with pullup. If it reads HIGH there is no transceiver installed because the weak pullup can pull the signal high and if it reads LOW there is a transceiver on board pulling the signal LOW.

I believe this is the best way.
 
A scope is an absolute necessity sometimes, glad I have one.
Fixed using the solution suggested above. When the pin is present the CRX pin is high.
 
Back
Top