Hi,
I am trying to design a nfc reader with trf7970 and am437x-gp-evm.Communication between processor and trf7970 is provided with spi using chip select. In addition I am using 4. spi channel and spi mode 1 in am437x-gp-evm. device tree is below.
&spi4 {
status = "okay";
nfc@0 {
pinctrl-names = "default";
pinctrl-0 = <&spi4_pins>;
compatible = "ti,trf7970a";
reg = <0>;
spi-max-frequency = <2000000>;
interrupts = <16 0>;
interrupt-parent = <&gpio1>;
ti,enable-gpios = <&gpio5 29 GPIO_ACTIVE_LOW>,
<&gpio0 7 GPIO_ACTIVE_LOW>;
vin-supply = <&vmmcsd_fixed>;
vin-voltage-override = <5000000>;
autosuspend-delay = <30000>;
irq-status-read-quirk;
en2-rf-quirk;
status = "okay";
};
};
In linux kernel, I am writing a data the trf7970's registers and reading this data with using spi_write and spi_write_then_read functions. when I was observed the miso, mosi, chip select and data clock pins with oscilloscope , I don't see a problem. But I don't receive correct data in kernel. What causes this problem?