Part Number: AM3359
Other Parts Discussed in Thread: PROFIBUS, , ISO1050
Tool/software: Linux
Hello,
I am trying to set up the CAN bus can0 on my AM3359 Ice V2 but I can't send or write a message. I send a CAN message with PCAN-View app through the profibus/can port (J9) and try to read it on the board and inversely.
I have no SPI1, UART0, I2C2, or PWM device connected (on the device tree). My device tree is the following (parts concerning can0):
&am33xx_pinmux {
[...]
dcan0_pins_default: dcan0_pins_default {
pinctrl-single,pins = <
0x174 ( PIN_INPUT | MUX_MODE2 ) /* (E16) uart0_txd.dcan0_rx */
0x170 ( PIN_OUTPUT | MUX_MODE2 ) /* (E15) uart0_rxd.dcan0_tx */
>;
};
[...]
};
&dcan0 {
status = "okay";
pinctrl-names = "default";
pinctrl-o = <&dcan0_pins_default>;
};
I put the jumpers on J6 and on pin 2 and 3 of J8 (but alternatively I also tried to add one on J7 as it seems that, following the datasheet, the gndprofi signal is used by the CAN bus).
To set up the can0 I used the following commands on the target:
ip link set can0 type can bitrate 50000 triple-sampling on (50 KHz set on PCan view)
ip link set can0 up
Then I use the following commands to write and read:
cansend can0 5A1#11.22.33.44.55.66.77.88
candump can0
When I try to read the signal that comes from PCan-view, I can see the signal on the Rx pin of the ISO1050 CAN transceiver on the board but when I write a message from the am3359, I can't find it on the Tx pin.
Do you have any idea of what I do wrong?
Best regards
Vincent