TC25 - Barcode scanner tutorial - Can't scan until DataWedge Demo used

M Mahendran Nadesan 3 years 2 months ago
471 1 0

After much wrangling of my Android Studio, I got the source code in the tutorial here (http://techdocs.zebra.com/emdk-for-android/6-9/tutorial/tutBasicScannin…) to build and deploy. The main activity shows up with the message "The scanner enabled and its idle", which is not what I expected. Further, pressing the hard triggers didn't do anything. But if I then open the DWDemo that came with the phone, select a scanner (I can even reselect the current option), and then switch back to my test app, the light flashes and I scan. I have debugged the code with a breakpoint where the scanner is assigned, but there I couldn't find any obvious field that would tell me about the scanner's status (whether idle or not).

Specs:
Android Version: 7.1.2
Model: TC25BJ
EMDK Version: 6.9

Full disclosure: I am actually playing with this with the intention of incorporating it into a Cordova (Angular/Ionic) app. This is the first step, as once I can get the scanner to work (or be programmatically turned 'on'), I can create a plugin. If anyone knows of a plugin that works for Cordova and the TC25, please do let me know.

Please Register or Login to post a reply

1 Replies

H Hunter Bradshaw

Hi, based on the description, it sounds like the EMDK is not being enabled in your app for some reason - you might want to try the pre-built barcode scanning application to see a working application: Barcode APIs - Zebra Technologies TechDocs .

Having said that however, if you are incorporating scanning into an Ionic application we have a blog post and Dev Talk on that topic which should be more relevant to you.

CONTACT
Can’t find what you’re looking for?