Hello,
the SPI slave mode is not working on my TX1.
I already activated the master mode with the guide http://elinux.org/Jetson/TX1_SPI and verifed it with a loopback test on the pin header J21.
The is my current device entry spi@7000d400:
spi@7000d400 {
compatible = "nvidia,tegra210-spi";
reg = <0x0 0x7000d400 0x0 0x200>;
interrupts = <0x0 0x3b 0x4>;
nvidia,dma-request-selector = <0x5d 0xf>;
iommus = <0x46 0xe>;
#address-cells = <0x1>;
#size-cells = <0x0>;
dmas = <0x5d 0xf 0x5d 0xf>;
dma-names = "rx", "tx";
nvidia,clk-parents = "pll_p", "clk_m";
status = "okay";
prod-settings {
prod {
prod = <0x4 0xfffff000 0x0>;
};
prod_c_flash {
status = "disabled";
prod = <0x4 0xffffffc0 0x7>;
};
prod_c_loop {
status = "disabled";
prod = <0x4 0xfffff000 0x44b>;
};
};
spi0_0 {
#address-cells = <0x1>;
#size-cells = <0x0>;
compatible = "spidev";
reg = <0x0>;
spi-max-frequency = <20000000>;
nvidia,enable-hw-based-cs;
nvidia,cs-setup-clk-count = <0x1e>;
nvidia,cs-hold-clk-count = <0x1e>;
nvidia,rx-clk-tap-delay = <0x1f>;
nvidia,tx-clk-tap-delay = <0x0>;
};
};
Also, I activated SPI master mode on the J23 with the following device entry spi@7000d600. (Loopback worked, too)
spi@7000d600 {
compatible = "nvidia,tegra210-spi";
reg = <0x0 0x7000d600 0x0 0x200>;
interrupts = <0x0 0x52 0x4>;
nvidia,dma-request-selector = <0x5d 0x10>;
iommus = <0x46 0xe>;
#address-cells = <0x1>;
#size-cells = <0x0>;
dmas = <0x5d 0x10 0x5d 0x10>;
dma-names = "rx", "tx";
nvidia,clk-parents = "pll_p", "clk_m";
status = "okay";
prod-settings {
#prod-cells = <0x3>;
prod {
prod = <0x4 0x0 0x16>;
};
prod_c_flash {
status = "disabled";
prod = <0x4 0xffffffc0 0x6>;
};
prod_c_loop {
status = "disabled";
prod = <0x4 0xfffff000 0x44b>;
};
};
spi1_0 {
#address-cells = <0x1>;
#size-cells = <0x0>;
compatible = "spidev";
reg = <0x0>;
spi-max-frequency = <20000000>;
nvidia,enable-hw-based-cs;
nvidia,cs-setup-clk-count = <0x1e>;
nvidia,cs-hold-clk-count = <0x1e>;
nvidia,rx-clk-tap-delay = <0x1f>;
nvidia,tx-clk-tap-delay = <0x0>;
};
“ls /dev” shows, that there are two nodes: spi0.0 and spi1.0.
Now i want to change the SPI mode on the J21 pin header (device tree entry spi@7000d400) to slave mode, but when i make the changes as stated in https://devtalk.nvidia.com/default/topic/982253/jetson-tx1/tx1-in-spi-slave-mode-to-an-adc-/post/5061002/#5061002, the node spi0.0 disappears. (Something that might be intereseting is that i can’t use references like &apbdma. When I want the recompile the dts, it says, that this reference is unknown.) I made several other changes in the device tree (as mentioned in this thread) but i doesn’t work.
Currently the TX1 runs L4T R24 REVISION 2.1.
Thanks in advance!