Jetson Orin NX CAN bus working at Listen-only/Silent mode

Hi All

Our customer need CAN bus working at Listen-only/Silent mode by BSP(DTS/driver etc…)/HW level.
(S/W level “sudo ip link set can0 type can bitrate 500000 listen-only on” was rejected by customer…)

We think about cut-off Jetson module CAN_TX pin as follows.
image
But no idea it correct/workable or not..

CAN transceiver: NXP TJA1043T
We consider control it for listen-mode also.

Any help would be greatly appreciated, thank all.

Hi nekochang,

Cutting off the Orin/Jetson CAN_TX pin is not our recommended approach for Listen-only/Silent mode.

For TJA1043/TJA1043T, the preferred HW-level method is to control the transceiver mode through STB_N and EN; Listen-only is selected by STB_N = High and EN = Low, which keeps the receiver active and disables the transmitter.

On Jetson, listen-only support exists in the CAN driver path, but this is typically not a DTS-only setting.

So our recommendation is to implement silent mode through transceiver mode control and validate it on the target board.

Hi @KevinFFF

Thanks you, I will use your TJA1043 method.
For this project, STB_N and EN pin connected to i2c GPIO expanded PCA6416APW and no driver occupy, therefore control both easily by i2cset

And your written about
On Jetson, listen-only support exists in the CAN driver path, but this is typically not a DTS-only setting.
If possible, can you teach me how to enable it?
Because in other project, H/W same above but STB_N and EN pin handle by CAN driver as follows

                mttcan@c310000 {
                        status = "okay";
+                       gpio_can_en-gpios = <&expand_gpio 1 GPIO_ACTIVE_LOW>;           /* Reference to the I2C GPIO expander @ 0-0020 (Pin 5(P0_1) -> CAN0_EN, Active High) */
+                       gpio_can_stb-gpios = <&expand_gpio 2 GPIO_ACTIVE_LOW>;          /* Reference to the I2C GPIO expander @ 0-0020 (Pin 6(P0_2) -> CAN0_STB_B, Active High) */
                };

So can’t control both as above project.

Thanks you very much.

Thanks for the update.
Yes, Jetson listen-only is enabled at the CAN controller level, not as a dedicated DTS property.

However, if gpio_can_stb and gpio_can_en are already owned by the mttcan driver, listen-only on will not automatically switch the TJA1043/TJA1043T transceiver into hardware listen-only mode.

So in this case, if you need true transceiver silent mode as well, you would need either to control STB_N/EN outside the driver, or modify the driver behavior for listen-only mode.

Hi @KevinFFF

Thanks your answer.

Follows your answer, interest code found @ m_ttcan_linux.c as follows

mttcan_controller_config()
...
        } else if (priv->can.ctrlmode & CAN_CTRLMODE_LISTENONLY) {
                /* silent mode : bus-monitoring mode */
                ttcan_set_bus_monitoring_mode(priv->ttcan, true);
...

ttcan_set_bus_monitoring_mode() control register directly.
And Google AI written CAN_CTRLMODE_LISTENONLY using for user-space code.

I have a idea…

  • Create DTS property like monitoring-mode,
  • If it set,
    1.Either call ttcan_set_bus_monitoring_mode() to set listen mode and reject enable/disable requirement from user-space.
    2 Or control STB_N/EN pin directly.

Thanks you very much.

Your idea is possible, but it requires a custom driver/BSP change, not DTS only.

mttcan already supports CAN_CTRLMODE_LISTENONLY for controller silent mode.
But if you need true TJA1043/TJA1043T hardware silent mode, I would also recommend controlling STB_N/EN to the proper listen-only state.

Hi @KevinFFF

I got it, thank your solution.