Spi.open() have error2 : No such file or directory on JetPack 4.6 and Jetpack 5.0

Hi team,
I test SPI in two case : case 1 - {Jetpack 4.6 on Jetson Nano B01 Kit} , and case 2 - {Jetpack 5.0 on Jetson Xavier NX Module}.

  • I have setup SPI DONE with sudo /opt/nvidia/jetson-io/jetson-io.py
  • I have install py-spidev library DONE
    Setup SPI done with jetson-io

But have same error with my python code for SPI:
spi.open() have error2 : No such file or directory

Can you guide me how to fix it?
Thank you so much!

My python code for test SPI:
#!/usr/bin/python3

import spidev
import time
import binascii

spi = spidev.SpiDev() # Tạo đối tượng cho SPI
spi.open(0, 0) # mở port 0, device (CS) 0
spi.max_speed_hz = 500000

try:
while True:
print(“abc”)
resp = spi.xfer2([0x61,0x62,0x63,0xA]) # [‘a’,‘b’,‘c’,‘\n’]
time.sleep(1) # sleep for 1 seconds
except KeyboardInterrupt:
spi.close()

Load the spidev driver by below command first.

sudo modprobe spidev

Hi @ShaneCCC ,
Thank you for your support.
My test result for SPI connnect on Jetson Nano B01 Kit with Jetpack 4.6.

Does the test result positive?

hi @ShaneCCC ,
Good test results.
I have a data transfer connection via SPI with Jetpack 4.6 on Jetson Nano B01 Kit.
When I have test results with Jetpack 5.0 on Jetson Xavier NX Module I will let you know.
Thank you for your support.

hi @ShaneCCC ,
Good test results.
I have a data transfer connection via SPI with Jetpack 5.0 on Jetson Xavier NX Module.
Thank you for your support!

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.