ST25R3916B Initialization Issue on Nucleo-h563ZI (Zephyr) - MISO always reads 0x00
Hello,
I am currently working on initializing ST25R3916B (X-NUCLEO-NFC08A1) with Nucleo-H563ZI microcontroller, using the Zephyr RTOS and the zephyr-st25r driver.
My primary goal is to successfully initialize the ST25R3916B chip to a state where it can respond to basic SPI commands and eventually perform NFC operations.
I am encountering an issue during the initialization phase where the STM32 appears to be correctly sending write and read commands via SPI, but the MISO line consistently reads 0X00 , indicating that the ST25R3916B is not responding or not driving the MISO line with expected data.
Hardware Setup:
This is the content my overlay file:
/ {
chosen {
zephyr,spi-st25r3916 = &st25r3916_nfc;
};
};
For the physical hardware connections:
CN5(PIN5) -> SCK (D13)
CN5(PIN6) -> MISO (D12)
CN5(PIN7) -> MOSI (D11)
CN5(PIN8) -> CS (D10)
CN8(PIN1/MCU_IRQ) -> D2
CN6(PIN4) -> 3.3V
CN6(PIN6) -> GND
Software Setup:
RTOS: Zephyr (version: 4.1.99)
ST25R Driver: Utilized the zephyr-st25r driver from the Zephyr project. (https://github.com/ptournoux/zephyr-st25r/tree/main)
SPI Configuration: Mode: SPI Mode 1
I did some modifications to the driver especially st25r3916Initialize function in st25r3916.c and the st25r_spi.c file too. I'll attach the function modifications and st25r_spi.c file. I'll also attach a section of my output log below.Are there any common hardware-related pitfalls with the ST25R3916B that would cause it to not drive MISO, even if power and crystal seem okay? or could it be a software issue?
Thank you in advance
