cancel
Showing results for 
Search instead for 
Did you mean: 

Reading tag data does not work when disabling IRQ for protection, using platformProtectST25RComm().

KKjel.1
Senior

I have a problem when I try to read the tag content.

Detecting the NFCA tag and reading UID etc. works fine.

But then I want to read the content of the tag using:

C_NFC_DataExchange( u8RxBankNumber) 

This always just returns all 0's.

I have found a way to make it work though:

If I don't use the protection of the ST25 communication, it works well.

The ST25 IRQ is wired to MCU EXTI 14, which is part of EXTI15..10 interrupt.

When I disable this interrupt during communication to protect the device (see below), it does not work.

If I disable a random unused EXTI, and thus NOT protecting the ST25, it works well:

In platform.h:

Defining the NFC IRQ as a random/wrong unused EXTI, it works:

#define IRQ_ST25R_EXTI_IRQn   EXTI0_IRQn

But when I define the correct EXTI used, it doesnot work, and I read all 0x00's:

#define IRQ_ST25R_EXTI_IRQn   EXTI15_10_IRQn

I have no other EXTI on the EXTI15..10 ISR.

I can't figure out why this happens.

Thanks

NFC device: ST25R3918

MCU: STM32H730

Ps.: It worked well using EXTI10, which was used on the first revision PCB

The problem is on a new PCB revision where we use EXTI14.

I am not sure this is important, but maybe...

This discussion is locked. Please start a new topic to ask your question.
1 ACCEPTED SOLUTION

Accepted Solutions
KKjel.1
Senior

Problem not solved, but moved to a new thread, because of new knowledge about the problem.

New thread

View solution in original post

4 REPLIES 4
KKjel.1
Senior

OK, wait a minute !

After testing some more, it shows that it was just a coincidence that I suddenly could read the data, just after changing the IRQ.

It just happened that single time.

After a lot of fiddling around, it does not work.

And then suddenly it worked 1 time again.

And then failed afterwards.

Right now, I have absolutely no idea why it does not work.

It has worked fine for 6 months on the first revision PCB.

The made a lot of changes to PCB, and total new STM32CubeMX project for the new wiring.

NFC SPI moved from SPI5 to SPI4

NFC IRQ moved from EXTI10 to EXTI14.

No changes to NFC source and RFAL library.

Hi,

you are claiming EXTI14 but above IRQ_ST25R_EXTI_IRQn points to EXTI15?!

Maybe the initial enable state of the interrupt is not correct? Start with rfalInitialize(), enable ST25R_SELFTEST and step through to get the initialization operational as a first step.

Best Regards, Ulysses

Hi

The external interrupts from 10 to 15 are all handled as the same interrupt: EXTI15_10_IRQn.

The IRQ works fine, as I can detect the card and read UID perfectly. It is only the data that can't be read (reads as 0's from bank 4 and forth).

I have seen the data read correctly 3 times in two days testing, with several hundreds of tests. So sometimes the data is read.

Next week I will try with another PCB: After days of debugging through the code and library, but everything looks exactly as on the former version of the PCB, it may be a hardwareproblem,.

KKjel.1
Senior

Problem not solved, but moved to a new thread, because of new knowledge about the problem.

New thread