Using Goggles or Zxing Barcode scanner with a PhoneGap application - android

I am trying to set up my current app (it's a HTML5 application compiled with phonegap build) where when I press a button, it pops up an option to select which bar code scanner to use(Or prompt to download the bar code scanner). When I select and scan it, I want to retrieve the information.
For example:
Retrieving via Zxing scanner would give me a set of numbers.
Retrieving via Goggles will give me more information like the number and product details.
I have seen some guides which are for native Android where they use Zxing but not Goggles. Seen no guides for using Goggles in an application. Closest I saw is a reverse engineered attempt dated few years back and not for HTML5 plat.
All I need to do is press a button from my app, go out into one of the scanner apps and retrieve the information back to my app to display.
Is there anyway I can do this? Is there a set of APIs available to access Zxing and Goggles via a HTML5/PhoneGap application?
It is definitely possible. Seen it on few applications.
This one for example: An app on Google Play
Please assist.
Screenshot additions for reference.
Screenshot 1
Screenshot 2

Related

Is there a way to embed logic in a QR code?

I have a requirement where I need to generate a QR code which, when scanned, displays the following behaviour.
When scanned for the first time, if my ios/android app is not installed then it takes the user to the appstore to prompt them to install the app.
When scanned again, if the app is already installed then it should open the app to a particular screen in the app.
Is it possible to create a QR code (or is it the app?) that behaves like this?
This behaviour is not be implemented in QR code. This will be implemented in your app.
I talk about Android. Same will be for iOS.
QR code will give you applicationId. (like com.stackexchange.marvin)
Get list of installed apps. See this question for getting installed apps list.
If user has installed this package name already, then open the app. See this question.
If not installed then open play store page.
Related question:
https://stackoverflow.com/a/8778268/6891563

Camera launching when I click an app

I am trying to do an android app where I will use facial recognition for providing security to the other applications present in phone. I am retrieving all applications and showing them in a list. I kept a button(ON/OFF) beside every application mentioned in the list. When I select ON for an app I provide security for that app using facial recognition.
Now, when I am trying to open the corresponding app it should first go to front camera. Here is where I am facing problem. Since I am new to android I don't understand how to redirect to front camera when I open an application.
Please help me if anyone has an idea on how to do it.

Working with 2 apps android

I'm working with android and I have a question. How I can do if I am doing an app that need another app. For example one of my option needs an app that reads code QR (2D) how can I work with both?
Thanks
You should be integrating via intent. See here for details how: https://code.google.com/p/zxing/wiki/ScanningViaIntent.
By doing it this way you eliminate the need to try to copy the barcode scanner app into your own which I think you'll find to be somewhat difficult(Not to mention you won't be tasked with trying to maintain a project that is not yours as new verions of the OS are released). You'll also be saving your users the space of another copy of the barcode scanner application.
Integrating via intent is the way that the authors of barcode scanner intended for you to use it along with your own application.

QR codes linked to android

I am trying to create an android application that is linked to a QR code. I need the user to scan a QR code and be taken to the application which they can then use. I have looked around on the internet where there are many different generators but they are for website,sms,text. Is there a way to link it to an application?
Thanks
You can link to the market page of an app with a link like this:
market://details?id=com.example.admob.lunarlander
Turn that link into a QR code like you would for any other URL. When they scan it, this will give the user the option to Install the app if they don't have it, or Launch the app if they do.
ref: http://support.google.com/admob/bin/answer.py?hl=en&answer=1620109
You can make the link to your app's page on the Android Market website. Basically, just go to market.android.com, find your app and use your app's page's url for the QR code.

Is there a way to create a scannable barcode that links to your app on marketplace?

I am trying to find a way that allows you to scan one of those online barcodes and have it link up to my droid app - anyone have any idea how to get one?
Yes you can simply use any kind of QR code generator to generate a link to your applications market presence.
The QR Code below was created using ZXing's Online QR Code Generator
This QR Code links to a pseudo app with following link.
market://details?id=com.example.my.cool.app
Scanning this code using a QR Code scanner app will open the market on your device linking you to your application.
Use one of the uncountable meta market site like http://www.androidpit.com/
Search for your application there and you will find a QR code for the market link there, too.
[edit] Afaik the update of the page is at least once a day, so you should see your new app soon there. As your link doesn't change on update you don't need to change the QR code [/edit]

Categories

Resources