Android 4.4。在VirtualBox下无法访问ACR122U阅读器
问题描述:
我使用连接了ACR122U NFC阅读器的VirtualBox下运行的Android 4.4。Android 4.4。在VirtualBox下无法访问ACR122U阅读器
我添加几行的体现:
<uses-permission android:name="android.permission.NFC" />
<uses-feature android:name="android.hardware.nfc" android:required="true" />
和:
<intent-filter>
<action android:name="android.nfc.action.TAG_DISCOVERED" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
,并尝试通过
nfcAdapter = NfcAdapter.getDefaultAdapter(this);
if(nfcAdapter == null) {
Toast.makeText(this, "NFC NOT supported on this devices!", Toast.LENGTH_LONG).show();
检查NFC阅读器,但收到消息NFC是不是支持的。我在哪里做错了?
答
Android NFC堆栈不支持开箱即用的ACR122U阅读器。实际上,我怀疑你可以为NFC堆栈编写一个驱动层,可以利用该阅读器,因为它只支持Android设备中当前NFC控制器的一部分功能,并且由于PN532 NFC芯片在ACR122U与目前的NFC控制器(说NCI)相比,提供了完全不同的协议。
可以肯定的是,您将NFC读卡器插入PC并希望仿真器将其用作Android NFC读卡器? – LaurentY