Problem: Barcode Scanner and Contacts on the Droid X

draftpeppin

Well-known member
Aug 22, 2010
81
6
0
Visit site
Sorry if I overlooked an existing discussion of this.

I just got my Droid X yesterday. I installed Barcode Scanner from ZXing. It works, except when I try to create a QR Code of a Contact, right when I pick the contact, things just jump back to the screen where you do scanning where it has the horizontal thin line. I emailed ZXing and the guy wrote back that he has seen this on the Droid X and that this model doesn't allow access to contacts, basically. Has anyone else run into this? Does anyone know if there is an effort going on to fix this on the DX?

Steve
 

draftpeppin

Well-known member
Aug 22, 2010
81
6
0
Visit site
I was in contact some more with ZXing. He said there's some limitations that are in some of the phones. Sounds like Motorola would have to fix this. Here's what he said after I sent him my log, quote:

Here's the key section, and yes this is like what the other Droid X problem was:
- Hide quoted text -

09-12 15:47:02.542 30262 30262 I ShareActivity: Showing contact URI as
barcode: null
09-12 15:47:02.542 30262 30262 D AndroidRuntime: Shutting down VM
09-12 15:47:02.542 30262 30262 W dalvikvm: threadid=3: thread exiting
with uncaught exception (group=0x4001e278)
09-12 15:47:02.542 30262 30262 E AndroidRuntime: Uncaught handler:
thread main exiting due to uncaught exception
09-12 15:47:02.550 1227 7849 I foo : **********************
resuming: 1178929312
09-12 15:47:02.550 30262 30262 E AndroidRuntime:
java.lang.RuntimeException: Failure delivering result
ResultInfo{who=null, request=1, result=-1, data=Intent { (has extras)
}} to activity {com.google.zxing.client.android/com.google.zxing.client.android.share.ShareActivity}:
java.lang.NullPointerException
09-12 15:47:02.550 30262 30262 E AndroidRuntime: at
android.app.ActivityThread.deliverResults(ActivityThread.java:3391)
09-12 15:47:02.550 30262 30262 E AndroidRuntime: at
android.app.ActivityThread.handleSendResult(ActivityThread.java:3433)
09-12 15:47:02.550 30262 30262 E AndroidRuntime: at
android.app.ActivityThread.access$2900(ActivityThread.java:121)
09-12 15:47:02.550 30262 30262 E AndroidRuntime: at
android.app.ActivityThread$H.handleMessage(ActivityThread.java:1955)
09-12 15:47:02.550 30262 30262 E AndroidRuntime: at
android.os.Handler.dispatchMessage(Handler.java:99)
09-12 15:47:02.550 30262 30262 E AndroidRuntime: at
android.os.Looper.loop(Looper.java:130)
09-12 15:47:02.550 30262 30262 E AndroidRuntime: at
android.app.ActivityThread.main(ActivityThread.java:4425)
09-12 15:47:02.550 30262 30262 E AndroidRuntime: at
java.lang.reflect.Method.invokeNative(Native Method)
09-12 15:47:02.550 30262 30262 E AndroidRuntime: at
java.lang.reflect.Method.invoke(Method.java:521)
09-12 15:47:02.550 30262 30262 E AndroidRuntime: at
com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:860)
09-12 15:47:02.550 30262 30262 E AndroidRuntime: at
com.android.internal.os.ZygoteInit.main(ZygoteInit.java:618)
09-12 15:47:02.550 30262 30262 E AndroidRuntime: at
dalvik.system.NativeStart.main(Native Method)
09-12 15:47:02.550 30262 30262 E AndroidRuntime: Caused by:
java.lang.NullPointerException
09-12 15:47:02.550 30262 30262 E AndroidRuntime: at
android.content.ContentResolver.acquireProvider(ContentResolver.java:757)
09-12 15:47:02.550 30262 30262 E AndroidRuntime: at
android.content.ContentResolver.query(ContentResolver.java:200)
09-12 15:47:02.550 30262 30262 E AndroidRuntime: at
com.google.zxing.client.android.share.ShareActivity.showContactAsBarcode(Unknown
Source)
09-12 15:47:02.550 30262 30262 E AndroidRuntime: at
com.google.zxing.client.android.share.ShareActivity.onActivityResult(Unknown
Source)
09-12 15:47:02.550 30262 30262 E AndroidRuntime: at
android.app.Activity.dispatchActivityResult(Activity.java:3828)
09-12 15:47:02.550 30262 30262 E AndroidRuntime: at
android.app.ActivityThread.deliverResults(ActivityThread.java:3387)
09-12 15:47:02.550 30262 30262 E AndroidRuntime: ... 11 more


The data in the returned Intent was null, and it should not be. I put
in a check that will just ignore this rather than throw an exception,
but it would have to be addressed on the other end. That's what I'd
post.
End quote

After he told me that, I went on to try two other QR Contact sharing apps, both of which worked. The ZXing guy said, quote:

Yeah I suspect what's really going on is that they have a bug in the
"old-style" contact intent API. The app only uses APIs from 1.5 and
earlier now to maintain backwards compatibility.

You can try this build which uses all the newer Android 2.2 APIs,
including the new contact APIs:
BarcodeScanner-debug.apk - zxing - Barcode Scanner Froyo beta for Android - Project Hosting on Google Code

I would not be surprised if that works.

But the old APIs are not gone and need to work, so it's valid to
report that as a bug still.

End Quote

I'm not sure I totally follow that all yet, but I just want to share this for anyone else who has run into this so they don't spend as much time trying to figure it out as I did.
 

trippinbillies40

Well-known member
Sep 7, 2010
71
2
0
Visit site
Its so funny you post this (not really funny actually). That program totally messed up my phone, had to master reset. It would not take phone calls from anyone on my contact list, and would drop service completely if i tried to make a phone call to someone. not talking for a second, I mean it would shut the cell service down completely needing a reboot. I could text to people just fine.
 

srowen

New member
Sep 14, 2010
1
0
0
Visit site
Developer here. Sorry to hear that, but it cannot have anything to do with the app. An app can't make this happen if it wanted to, unless the platform has a problem.

We see so many phones with questionable camera driver implementations that do indeed exhibit problems when the camera is used. But it's nothing to do with us.
 

Forum statistics

Threads
943,188
Messages
6,917,697
Members
3,158,867
Latest member
Non