This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

AM3352: CAN bus short recovery

Part Number: AM3352

Just wondering if anyone can shed any light on can short bus H and L for long period of time (2-10 min) then correcting short does not recover automatically. If we short for a quicker period of time it recovers. Upon further investigation the can0 through ip -d -s link show can0 show ERROR-PASSIVE and it does not proceed to buss off state and auto recover.

It is configured to autorecover via:

ip link set can0 up type can bitrate 500000 restart-ms 1000

Which is definitely working as every second I get:

c_can_platform 481cc000.can can0: setting BTR=1c02 BRPE=0000

It eventually stops printing this out and then I get:

Send failed: No buffer space available

ip -d -s link show can0 

can0: <NOARP,UP,LOWER_UP,ECHO> mtu 16 qdisc pfifo_fast state UP qlen 128
link/can
can <TRIPLE-SAMPLING> state ERROR-PASSIVE (berr-counter tx 248 rx 0) restart-ms 1000
bitrate 500000 sample-point 0.875
tq 125 prop-seg 6 phase-seg1 7 phase-seg2 2 sjw 1
c_can: tseg1 2..16 tseg2 1..8 sjw 1..4 brp 1..1024 brp-inc 1
clock 24000000
re-started bus-errors arbit-lost error-warn error-pass bus-off
2707 0 0 2709 2709 2707
RX: bytes packets errors dropped overrun mcast
91897 11554 0 0 0 0
TX: bytes packets errors dropped carrier collsns
1524 198 0 2707 0 0

According to this the BERR tx is 248 so it goes to buss off and restarts (248 - 127 time). But it gets stuck in this case at the (248 -127 times).

At the command line a ip link can0 up will restart the bus.

Anyone seen a similar problem? I have looked into the socket layer and am looking into the DCAN layer. Anyone got a hint of where to look? Or is this at the silicon level?