iso15sim: init earlier to prevent other FPGA loading issue

This commit is contained in:
Yann GASCUEL 2024-01-25 08:54:10 +01:00
commit f4d4e975ee

View file

@ -2130,6 +2130,9 @@ void SimTagIso15693(uint8_t *uid, uint8_t block_size) {
// free eventually allocated BigBuf memory
BigBuf_free_keep_EM();
// Init early to be sure FPGA is loaded before any EML operation
// usefull when eml memory is empty (UID supplied)
Iso15693InitTag(); // to be sure FPGA is loaded before any EML operation
iso15_tag_t *tag = (iso15_tag_t *) BigBuf_get_EM_addr();
if (tag == NULL) {
@ -2176,8 +2179,6 @@ void SimTagIso15693(uint8_t *uid, uint8_t block_size) {
return;
}
Iso15693InitTag();
LED_A_ON();
if (g_dbglevel >= DBG_DEBUG) {