Jetson Nano eMMC MCP2515 Not Working

Hi. I’ve got a jetson nano with this shield: RS485 CAN for Jetson Nano - Waveshare Wiki

I initially flashed with sdk manager. To make the MCP2515 work i tried to follow Jetson nano and mcp2515 can module - #249 by andrew_h

  1. Downloaded the MCP251x.dts.txt & removed .txt extension
  2. git clone GitHub - Seeed-Studio/seeed-linux-dtoverlays: Device Tree Overlays for Seeed boards && cd seeed-linux-dtoverlays
  3. cp MCP251x.dts overlays/jetsonnano/
  4. make all_jetsonnano
  5. sudo make install_jetsonnano
  6. cp overlays/jetsonnano/MCP251x.dtbo /boot/
  7. changed /boot/extlinux/extlinux.conf to:
TIMEOUT 30
DEFAULT MCP251x CAN Controller

MENU TITLE L4T boot options

LABEL primary
      MENU LABEL primary kernel
      LINUX /boot/Image
      INITRD /boot/initrd
      APPEND ${cbootargs} quiet root=/dev/mmcblk0p1 rw rootwait rootfstype=ext4 console=ttyS0,115200n8 console=tty0 fbcon=map:0 net.ifnames=0 sdhci_tegra.en_boot_part_access=1 nv-auto-config

# When testing a custom kernel, it is recommended that you create a backup of
# the original kernel and add a new entry to this file so that the device can
# fallback to the original kernel. To do this:
#
# 1, Make a backup of the original kernel
#      sudo cp /boot/Image /boot/Image.backup
#
# 2, Copy your custom kernel into /boot/Image
#
# 3, Uncomment below menu setting lines for the original kernel
#
# 4, Reboot

# LABEL backup
#    MENU LABEL backup kernel
#    LINUX /boot/Image.backup
#    INITRD /boot/initrd
#    APPEND ${cbootargs}

LABEL MCP251x CAN Controller
      MENU LABEL MCP251x CAN Controller
      LINUX /boot/Image
      FDT /boot/MCP251x.dtbo
      INITRD /boot/initrd
      APPEND ${cbootargs}

Now when i boot my Nano the Nvidia logo is stuck and i can’t get in. Somewhere i must’ve made a misstake. I don’t mind reflashing the device but I’m stuck at what to do currently.

You can refer to CAN with Jetson Nano Production Module

1 Like

I’m quite new to linux overall so there are some things I’m quite unsure of.

In the post you referenced, he says:

When I switch to the production module, I get an error message during boot:
mcp251x spi0.0: MCP251x didn’t enter in conf mode after reset

i assume the error message is from running: dmesg | grep mcp ?
I don’t get anything related to MCP251x.

running : sudo cat /sys/kernel/debug/tegra_pinctrl_reg | grep -i spi
shows:


Bank: 1 Reg: 0x70003050 Val: 0x0000e015 -> spi1_mosi_pc0
Bank: 1 Reg: 0x70003054 Val: 0x0000e015 -> spi1_miso_pc1
Bank: 1 Reg: 0x70003058 Val: 0x0000e015 -> spi1_sck_pc2
Bank: 1 Reg: 0x7000305c Val: 0x0000e015 -> spi1_cs0_pc3
Bank: 1 Reg: 0x70003060 Val: 0x0000e015 -> spi1_cs1_pc4
Bank: 1 Reg: 0x70003064 Val: 0x00006016 -> spi2_mosi_pb4
Bank: 1 Reg: 0x70003068 Val: 0x00006016 -> spi2_miso_pb5
Bank: 1 Reg: 0x7000306c Val: 0x00006016 -> spi2_sck_pb6
Bank: 1 Reg: 0x70003070 Val: 0x00006016 -> spi2_cs0_pb7
Bank: 1 Reg: 0x70003074 Val: 0x00006015 -> spi2_cs1_pdd0
Bank: 1 Reg: 0x70003078 Val: 0x0000e015 -> spi4_mosi_pc7
Bank: 1 Reg: 0x7000307c Val: 0x0000e015 -> spi4_miso_pd0
Bank: 1 Reg: 0x70003080 Val: 0x0000e015 -> spi4_sck_pc5
Bank: 1 Reg: 0x70003084 Val: 0x0000e015 -> spi4_cs0_pc6
Bank: 1 Reg: 0x70003088 Val: 0x00002015 -> qspi_sck_pee0
Bank: 1 Reg: 0x7000308c Val: 0x00002015 -> qspi_cs_n_pee1
Bank: 1 Reg: 0x70003090 Val: 0x00002015 -> qspi_io0_pee2
Bank: 1 Reg: 0x70003094 Val: 0x00002015 -> qspi_io1_pee3
Bank: 1 Reg: 0x70003098 Val: 0x00002015 -> qspi_io2_pee4
Bank: 1 Reg: 0x7000309c Val: 0x00002015 -> qspi_io3_pee5
Bank: 0 Reg: 0x70000b70 Val: 0x00000001 -> drive_qspi_comp_control
Bank: 0 Reg: 0x70000b78 Val: 0x00000001 -> drive_qspi_lpbk_control
Bank: 0 Reg: 0x70000a78 Val: 0x00808000 -> drive_qspi_comp

seems like spi is fine,

running ls /dev/spidev*
shows:

/dev/spidev0.0 /dev/spidev0.1 /dev/spidev1.0 /dev/spidev1.1

Theres also a mention of
And modify those spi1_xxx_pc* to “spi1” like below in device tree.

Is it the tegra210-p3448-0002-p3449-0000-b00.dtb file?

And do i need to modify that before flashing the OS? Apparently jetson-io.py doesn’t work with the emmc version of the jetson nano.