2024-02-06 09:56 PM
Hi,
Now I am trying to port the rfal library for an ST25R3920B.
I have defined all mandatory part of platform.h and rfal_defConfig.h file.
And I enabled the flags ST25R_SELFTEST, ST25R_SELFTEST_TIMER to find out issues of initializing.
The ST25R_SELFTEST is passed without any error, but for ST25R_SELFTEST_TIMER it fails in st25r3916WaitForInterruptsTimed function
st25r3916EnableInterrupts( ST25R3916_IRQ_MASK_GPE );
st25r3916SetStartGPTimer( (uint16_t)ST25R3916_TEST_TMR_TOUT_8FC, ST25R3916_REG_TIMER_EMV_CONTROL_gptc_no_trigger);
if( st25r3916WaitForInterruptsTimed( ST25R3916_IRQ_MASK_GPE, (ST25R3916_TEST_TMR_TOUT - ST25R3916_TEST_TMR_TOUT_DELTA)) != 0U )
{
platformErrorHandle();
return RFAL_ERR_SYSTEM;
}
And then, I looked closely at the if conditional sentence, and I don't understand it.
The return value of st25r3916WaitForInterruptsTimed() function is not 0 when an interrupt occured without a timeout. right?
So it means when it's an abnormal state, return is zero...
I don't understand why it's an error when the st25r3916WaitForInterruptsTimed() output value is not zero.
Is there something wrong with my understanding? If so, please let me know
best regards,
Solved! Go to Solution.
2024-02-06 11:52 PM
Hi,
the ST25R_SELFTEST_TIMER is testing two conditions:
I think you are looking at the second case: In this case no interrupt should yet be received.
BR, Ulysses
2024-02-06 11:52 PM
Hi,
the ST25R_SELFTEST_TIMER is testing two conditions:
I think you are looking at the second case: In this case no interrupt should yet be received.
BR, Ulysses