CR95HF Nucleo baord SPI MISO issues
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
โ2021-02-19 1:53 AM
Hi,
I am using the X-NUCLEO-NFC03A1 board with an Atmega328p MCU and atmel studio.
I have been trying to communicate with the CR95HF via SPI but I cant seem to get any reply on the MISO line. The MISO line never drops below a certain voltage level (around 100mV).
Any idea what might be causing this? I checked that the SCK, MOSI and CS signals all have good integrity on the CR95HF chip. I have attached a picture of the SCK and MISO signals.
Thanks in advance for your help
Solved! Go to Solution.
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
โ2021-02-19 7:22 AM
Hi,
on your scope screenshot, I see only nIRQ_IN rising once from 0 to 3V3. Can you confirm that you follow the startup sequence as described in ST25R95 datasheet ยง3.2
- after the initial t0 delay after power on, there must be an initial interrupt for the interface selection (t1 duration) i.e nIRQ_IN going from 3V3 to 0
- then after t1, rising nIRQ_IN will cause the oscillator to start
Can you provide a screenshot of the full startup sequence from power on to t3?
If this startup sequence is properly followed and the X-NUCLEO-NFC03A1 still not replying, can you plug this board on a NUCLEO-L476RG, NUCLEO-F401RE or NUCLEOF103RB board and run the firmware from X-CUBE-NFC3 (binary are provided). This will help to verify that the X-NUCLEO-NFC03A1 has not been damaged.
How is powered the X-NUCLEO-NFC03A1? External power supply?
Can you provide the interconnection between your MCU mother board and the X-NUCLEO-NFC03A1 daughter board? make sure to follow UM2479 table 1 and table 2 for the interconnection?
Rgds
BT
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
โ2021-02-19 3:49 AM
Hi @SMahm.2โ ,
on CR95HF side, can you check that the Interface selection is correct (SSI_0=1 and SS_1=0) and that the powering is correct.
On MCU side, can you check that the alternate function for the MISO (PB4) is properly configured and that the SPI is properly configured (Motorola format, 8 bits data, MSB first, clock polarity low, clock phase 1 edge. For the baud rate, the driver in X-CUBE-NFC3 uses 1.5 Mbits/s)?
Rgds
BT
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
โ2021-02-19 3:55 AM
Hi Brian,
The correct interface is selected on CR59HF.
I have the following settings on the MCU side:
CPOL = CPHA = 0
All pins are correctly configured
Fsck = 2MHz
8 bits data format, MSB first
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
โ2021-02-19 4:25 AM
Hi,
can you probe the IRQ_IN during the startup sequence (see ST25R95 datasheet ยง3.2) and share the startup sequence with me.
I would also suggest to check that after the completion of the startup sequence:
- the 27.12 MHz cristal is properly clocking the device (just probe and one should see something similar to figure 3 from AN3433)
- the nIRQ_OUT is high (i recommand to use IRQ_OUT during SPI communication)
How is the MISO connected to the X-NUCLEO-NFC03A1: is there any pull up resistor on MCU PCB side? Can you disconnect the MISO on MCU side and probe the MISO on X-NUCLEO-NFC03A1 side (i.e. with MISO being left floating)?
Rgds
BT
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
โ2021-02-19 5:32 AM
Hi Brian,
Please see the attached image, it seems that there is no output form the crystal. I measured the signal on XIN and XOUT pins individually with no resultant clock.
I disconnected the MISO from the MCU and the result was the same as seen in the previous image.
Any suggestions?
Regards,
Salman
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
โ2021-02-19 5:35 AM
IRQ_OUT is also high
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
โ2021-02-19 7:22 AM
Hi,
on your scope screenshot, I see only nIRQ_IN rising once from 0 to 3V3. Can you confirm that you follow the startup sequence as described in ST25R95 datasheet ยง3.2
- after the initial t0 delay after power on, there must be an initial interrupt for the interface selection (t1 duration) i.e nIRQ_IN going from 3V3 to 0
- then after t1, rising nIRQ_IN will cause the oscillator to start
Can you provide a screenshot of the full startup sequence from power on to t3?
If this startup sequence is properly followed and the X-NUCLEO-NFC03A1 still not replying, can you plug this board on a NUCLEO-L476RG, NUCLEO-F401RE or NUCLEOF103RB board and run the firmware from X-CUBE-NFC3 (binary are provided). This will help to verify that the X-NUCLEO-NFC03A1 has not been damaged.
How is powered the X-NUCLEO-NFC03A1? External power supply?
Can you provide the interconnection between your MCU mother board and the X-NUCLEO-NFC03A1 daughter board? make sure to follow UM2479 table 1 and table 2 for the interconnection?
Rgds
BT
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
โ2021-02-22 3:36 AM
HI Brian,
I followed the startup sequence you indicated and its working now, thanks.
Regards,
Salman
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
โ2021-02-22 3:39 AM
Hi Salman,
Well done.
Thanks for the update.
Rgds
BT
