SW3683-v05.07.01和SW3683-v05.19.00 PN7462AU_ex_phExCcid关于ISO15693的bug

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

SW3683-v05.07.01和SW3683-v05.19.00 PN7462AU_ex_phExCcid关于ISO15693的bug

1,326 Views
onlineit
Contributor II

单步执行发现在这里出现了问题:

            /** Assign the General Slot as CL and CL Slot as ICODE Card. */
            gphExCcid_sUsb_SlotInfo.bSlotType   = PH_EXCCID_USBCCID_CL_CHANNEL_NO;
            gphExCcid_sUsb_SlotInfo.bCLSlotType = PH_EXCCID_USBCCID_CL_TYPE_V;

            /** Get the ATR Information. */
            //phExCcid_UsbCcid_ATR_Felica_Mifare_ICode(0);

            /** Call the USB Processing Functions of the CCID Class. */
            phExCcid_Handle_USB_Process(psDiscLoopParams);

程序执行phExCcid_Handle_USB_Process(psDiscLoopParams)语句后将gphExCcid_sUsb_SlotInfo.bSlotType清零了,所以又不断地循环读卡,停不下来。但mifare和1443A-4的卡片又是正常的,不知道是什么问题???

SW3683-v05.07.01这个版本也是一样的结果,和SW3683-v05.19.00结果一样,在PN7462B开发板上,放上ISO15693的卡片,能读到8字节UID号,但四个指示灯(红绿黄蓝)停不下来,一直在闪,放mifare1卡和ISO14443A-4的CPU卡就可以停下来。感觉代码当中有错误,破坏了变量gphExCcid_sUsb_SlotInfo,让gphExCcid_sUsb_SlotInfo.bSlotType变成了0x00。

官方的PN7462AU_ex_phExCcid例程只测试了TypeA,其它都有点问题,bug挺多,有些地方莫名的错误。

比如:

 phExCcid_Handle_USB_Process(psDiscLoopParams);

在执行TypeA时,这条语句就没有问题,在执行ISO15693时,把结构体变量gphExCcid_sUsb_SlotInfo的值清零了,造成寻卡时卡放上去还是不断地读卡,

gphExCcid_sUsb_SlotInfo.bSlotType   被赋值为 PH_EXCCID_USBCCID_CHANNEL_NONE。

希望NXP官方能解决这个问题!!!

Tags (2)
0 Kudos
Reply
3 Replies

1,181 Views
Kan_Li
NXP TechSupport
NXP TechSupport

I looked into the code, and found it is cleared only when the card is removed.

pastedImage_1.png

maybe your sample card has some issue?


Have a great day,
Kan

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos
Reply

1,181 Views
onlineit
Contributor II

是因为执行函数phExCcid_Check_Presence_TypeV_Card时检测不到卡然后才执行phExCcid_UsbCcid_CardRemoved,问题出在卡检测函数检测不到卡,单步执行发现调用phpalSli15693_Inventory函数第一次、第二次都返回0x0000,第三次返回0x0201,需要将射频重新开关或调用phhalHw_FieldReset才能每次检测到卡,这个问题国外也有人遇到过,好象也没有解决。

链接如下:

https://community.nxp.com/thread/440898

引用如下:

To be more precise after phhalHw_FieldReset() I first called phpalSli15693_Inventory() and I got UID.

Then I call phpalSli15693_StayQuiet() - it is fine also, and I'm assuming this command is received only by "winner" tag.

Then I call phpalSli15693_Inventory again and got 0x0201 error. 

Maybe I should send phpalSli15693_StayQuiet only for UID received by inventory but there is no phpalSli15693_StayQuiet with UID parameter... 

0 Kudos
Reply

1,181 Views
Kan_Li
NXP TechSupport
NXP TechSupport

Thanks for the report! I am checking with the expert team for this issue, and will let you know when I have any more info.

Thanks for your patience!


Have a great day,
Kan

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos
Reply