Reputation: 1574
I have a qr/barcode scanner in my application and NFC detection. The NFC detection works fine. I receive the onNewIntent in my Activity.
The issue is that this method isn't called anymore when I have my barcode scanner active.
After debugging, I found that it stops detecting nfc when I call:
mCamera.startPreview();
The Camera is used in a Fragment, which is added to the Activity. This is a strange issue.
Is it possible to detect NFC and having the camera open + preview at the same time?
Edit https://stackoverflow.com/a/34678864/1723525 This issue was on my Nexus 5X. No clue if this will be an issue for only this device or more devices..
Upvotes: 1
Views: 559
Reputation: 8287
Yes, it is normally possible to have camera open and detect NFC at the same time. I have it working with ZXing in more than one project.
Upvotes: 0