I want to integrate the Beaglebone AI with the Xavier AGX bus using CAN interface. I am using “MCP2515 CAN Bus Breakout Board With SPI Interface” for this. The JetPack version I am using is 4.4. Can anyone please help me with the steps to enable the SPI interface on Xavier AGX board?
I am confused whether this should be done on the host machine or the NVIDIA AGX target board.
Can you please clarify the following points:
a) Do I need to create a .cfg file for spi interface with the pinmux modifications?
b) Can you please point me to the data sheet which contains the address of the spi device?
c) Do I need to modify/create a new device tree blob file?
Thanks for the update.
I have applied the Rt linux patch to make the kernel real time. I did this by downloading the BSP source code (on Nvidia AGX board)and then compiling the kernel image using Rt linux patch.
How can I flash the Jetson xavier with RT linux patch and the SPI interface enabled?
I downloaded the nvidia target source code using the sdk manager.
The JetPack version is “JetPack_4.4_Linux_JETSON_AGX_XAVIER”. However, the bsp version in nv_tegra folder show the JetPack version as 32.4.3.
Here are the steps that I performed:
Downloaded the nvidia_host and nvidia_target source code using sdk manager.
Ran the script source_sync.sh with tag tegra-l4t-32.4.4. This downloads the source in the new folder created with the name “sources” containing kernel/kernel-4.9, u-boot and hardware sub directory.
Go to directory kernel/kernel-4.9 and applied the rt-linux patch and modified the pinmux settings.
Built the kernel.
make ARCH=arm64 O=$TEGRA_KERNEL_OUT -j8
Copied the image and dts directory to Linux_for_Tegra/kernel/Image and Linux_for_Tegra/kernel/dtb.
Installed the kernel modules.
Flashed the image using sudo ./flash.sh jetson-xavier mmcblk0p1.
When I execute the uname -a command it does not reflect the RT Linux and rather reflects the normal Linux image.
The byte size of the Image built does not match with the byte size of the Image flashed.
The /dev/ directory shows two files spidev0.0 and spidev0.1.
and insmod shows that the spidev is installed.
After running the spidev_test(downloaded from linux open source) with /dev/spidev0.0 I do see the packets being send and received. I connected to MISO and MOSI pins (pin 19 and 21).
My further question is :
How do I modify the transmission speed?
What is the reason that the RT-Linux is not enabled?