简体   繁体   English

Android PN532不再起作用

[英]Android PN532 not working anymore

I am working on a project, and I'm trying to send/receive data through a PN532 connected to an Arduino Uno and an Android smartphone. 我正在研究一个项目,并且正在尝试通过连接到Arduino Uno和Android智能手机的PN532发送/接收数据。 I'm using an HTC One M8 and Seeed-Studio library https://github.com/Seeed-Studio/PN532 . 我正在使用HTC One M8和Seeed-Studio库https://github.com/Seeed-Studio/PN532

The problem is that P2P mode was working, but since I've upgraded my phone from Android 4.4 (KitKat) to Android 5.0 (Lollipop) it didn't work any more. 问题是P2P模式可以正常工作,但是由于我已经将手机从Android 4.4(KitKat)升级到了Android 5.0(Lollipop),因此无法再使用了。 I've tried to switch to I²C and UART, but it didn't work. 我试图切换到I²C和UART,但是没有用。

When I'm using the "p2p_with_ndef_library" example, the PN532 seems to detect my phone but it prints "Failed.". 当我使用“ p2p_with_ndef_library”示例时,PN532似乎可以检测到我的电话,但它会显示“失败”。


Update: Finally I've tried with another NFC module, and it works. 更新:最后,我尝试了另一个NFC模块,它可以工作。 My module was broken for some reason. 我的模块由于某种原因而损坏。

I was doing this by Samsung Galaxy S III and Xperia L, and it was done prefect. 我是由Samsung Galaxy S III和Xperia L来做的,这是完美的。 It should done by SPI mode only. 它只能通过SPI模式完成。 And your data should be less than 128 byte or 139 byte. 并且您的数据应小于128字节或139字节。 But it's better that less than 128 bytes. 但是最好少于128个字节。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM