My starting point for the kernel is the source provided by freescale
with their P1010RDB board's SDK which is based upon the 2.6.35 kernel.
I have applied all the changes in the 2.6.35.y stable tree maintained
by Greg K-H. I have configured both the flexcan interface statically
linked into the kernel and the vcan driver as a loadable module.
I also have the can-utils installed in rootfs.
I have built a simple 3-meter cable with Pins 2, 3, and 7 connected
together on both ends and pins 2 and 7 terminated with 120 ohm resistors
on each end.
Following boot, I do/see:
# ip link set can0 type can bitrate 125000 triple-sampling on
# ifconfig can0 up
# ip link set can1 type can bitrate 125000 triple-sampling on
# ifconfig can1 up
# ip -d -s link show can0
2: can0: <NOARP,UP,LOWER_UP,ECHO> mtu 16 qdisc pfifo_fast state UNKNOWN qlen 10
link/can
can <TRIPLE-SAMPLING> state ERROR-ACTIVE (berr-counter tx 0 rx 0)
restart-ms 0
bitrate 125000 sample-point 0.875
tq 500 prop-seg 6 phase-seg1 7 phase-seg2 2 sjw 1
flexcan: tseg1 4..16 tseg2 2..8 sjw 1..4 brp 1..256 brp-inc 1
clock 200000000
re-started bus-errors arbit-lost error-warn error-pass bus-off
0 0 0 0 0 0
RX: bytes packets errors dropped overrun mcast
0 0 0 0 0 0
TX: bytes packets errors dropped carrier collsns
0 0 0 0 0 0
# ip -d -s link show can1
3: can1: <NOARP,UP,LOWER_UP,ECHO> mtu 16 qdisc pfifo_fast state UNKNOWN qlen 10
link/can
can <TRIPLE-SAMPLING> state ERROR-ACTIVE (berr-counter tx 0 rx 0)
restart-ms 0
bitrate 125000 sample-point 0.875
tq 500 prop-seg 6 phase-seg1 7 phase-seg2 2 sjw 1
flexcan: tseg1 4..16 tseg2 2..8 sjw 1..4 brp 1..256 brp-inc 1
clock 200000000
re-started bus-errors arbit-lost error-warn error-pass bus-off
0 0 0 0 0 0
RX: bytes packets errors dropped overrun mcast
0 0 0 0 0 0
TX: bytes packets errors dropped carrier collsns
0 0 0 0 0 0
# candump -e any,0:0,#FFFFFFFF &
# cansend can0 123#1122334455667788
# can0 20000044 [8] 00 10 00 00 00 00 00 00 ERRORFRAME
controller-problem{rx-error-passive}
bus-off
# ip -d -s link show can0
2: can0: <NO-CARRIER,NOARP,UP,ECHO> mtu 16 qdisc pfifo_fast state DOWN qlen 10
link/can
can <TRIPLE-SAMPLING> state BUS-OFF (berr-counter tx 0 rx 0) restart-ms 0
bitrate 125000 sample-point 0.875
tq 500 prop-seg 6 phase-seg1 7 phase-seg2 2 sjw 1
flexcan: tseg1 4..16 tseg2 2..8 sjw 1..4 brp 1..256 brp-inc 1
clock 200000000
re-started bus-errors arbit-lost error-warn error-pass bus-off
0 0 0 1 1 1
RX: bytes packets errors dropped overrun mcast
8 1 0 0 0 0
TX: bytes packets errors dropped carrier collsns
8 0 0 0 0 0
# ip -d -s link show can1
3: can1: <NOARP,UP,LOWER_UP,ECHO> mtu 16 qdisc pfifo_fast state UNKNOWN qlen 10
link/can
can <TRIPLE-SAMPLING> state ERROR-ACTIVE (berr-counter tx 0 rx 0)
restart-ms 0
bitrate 125000 sample-point 0.875
tq 500 prop-seg 6 phase-seg1 7 phase-seg2 2 sjw 1
flexcan: tseg1 4..16 tseg2 2..8 sjw 1..4 brp 1..256 brp-inc 1
clock 200000000
re-started bus-errors arbit-lost error-warn error-pass bus-off
0 0 0 0 0 0
RX: bytes packets errors dropped overrun mcast
0 0 0 0 0 0
TX: bytes packets errors dropped carrier collsns
0 0 0 0 0 0
Any help/guidance will be greatly appreciated.
Robin Holt
_______________________________________________
Socketcan-core mailing list
[email protected]
https://lists.berlios.de/mailman/listinfo/socketcan-core