• XDA Forums have been migrated to XenForo. We are aware of several issues including missing threads, logins not working, and more. To discuss, use this thread.
  • If you are experiencing issues logging in, we migrated and software and made it more secure. We recommend trying to reset your password.

[APP] ScanR - Simple Resistor Scanner

laufersteppenwolf

Inactive Recognized Developer / Retired Forum Mode
Jul 1, 2012
2,881
6,987
0
Baden-Württemberg
droideveloper.com
After publishing CutCalc, a colleague of mine had the (not so) brilliant idea that I could write an app that can scan resistors and tell you their resistance. At first I was like 'nah, too much work', but after some time I, too, felt like it would come quite handy to have such an app.

Long story short, I have built an app that can do exactly that. It is not completely finished yet, but it's at a point where it's doing what it's supposed to do. I know that the UI is not really...umm...beautiful yet, but I'm not really good when it comes to graphics and designing :eek:


ScanR


How to use:
  1. In order to scan a resistor, you have to place it with the tolerance band to the right (works best with bright backgrounds).
  2. Then position the blue line over the color bands indicating the resistance. The left border should align with the first band, the right one with the last band.
  3. When you've positioned your camera correctly,
  4. Press the scan button. The app will then scan until it has 20 proper readings and then calculate the most common value of the scans.
  5. Once it has calculated the most likely result you will be redirected to the result screen.
    (Using the advanced result screen you can directly edit the color combination in case it was read incorrectly.)

Of course you can also switch directly to the manual detection screen and enter the color combination manually.

And as usual, you have settings for pretty much anything you could possibly wanna have changed.

Please note that this app gets developed on my Z3 Compact's camera, so all color values are tweaked for my camera. It is quite possible that my values do not properly fit yours, so please let me know if there are some colors not being properly recognized on your device.

Further plans:
- Nicer UI
- Further fine tuning of the color values

Screenshots







Changelog
v01
- initial release

Download
You can get the app either from this thread (see downloads tab)
or directly from Google Play:


Credits
A big thanks goes out to @matmutant for creating the app's icon. :good:

And just like with all other projects of mine, this app is completely open source. So feel free to issue pull requests/suggestions. I appreciate all kinds of feedback.
If you encounter issues, please let me know and I'll do my best to fix it ASAP.

XDA:DevDB Information
ScanR, App for all devices (see above for details)

Contributors
laufersteppenwolf, matmutant
Source Code: https://github.com/laufersteppenwolf/ScanR


Version Information
Status: Stable
Current Stable Version: v01
Stable Release Date: 2015-09-06

Created 2015-09-06
Last Updated 2015-09-06
 

Attachments

polykoma

New member
Nov 4, 2013
196
31
0
Berlin
n1

noiiiice.

downloaded right away.
will test when my next soldering action impacts.

badly needed that 3 years ago :D

nice work ! :fingers-crossed::good::fingers-crossed:
 

laufersteppenwolf

Inactive Recognized Developer / Retired Forum Mode
Jul 1, 2012
2,881
6,987
0
Baden-Württemberg
droideveloper.com
Emm... no autofocus and it can't recognize :(
Autofocus is working perfectly fine for me, mind taking a logcat of the unsuccessful scans?

@laufersteppenwolf You were a C , not a java guy before ! I'm amazed , congrats on your app !
Ahh, it gave me some motivation, maybe first thing tommorrow I will open AndroidStudio again !
Yeah, and I actually still prefer C over java hands down :D
Feel free to jump in to the fun, though if you want ;)

I think its the camera function...
Please tell me if this logcat is enough (I tried to cut it to the important part in my eyes)
Code:
09-10 02:58:04.100 D/JavaCameraView(26164): Connecting to camera
09-10 02:58:04.100 D/JavaCameraView(26164): Initialize java camera
09-10 02:58:04.100 D/JavaCameraView(26164): Trying to open camera with old open()
[B]09-10 02:58:04.103 W/ServiceManager(  202): Permission failure: android.permission.CAMERA from uid=10152 pid=26164[/B]
09-10 02:58:04.103 E/CameraService(  202): Permission Denial: can't use the camera pid=26164, uid=10152
09-10 02:58:04.103 W/CameraBase(26164): An error occurred while connecting to camera: 0
09-10 02:58:04.103 E/JavaCameraView(26164): Camera is not available (in use or does not exist): Fail to connect to camera service
09-10 02:58:04.104 D/JavaCameraView(26164): Trying to open camera with new open(0)
[B]09-10 02:58:04.104 W/ServiceManager(  202): Permission failure: android.permission.CAMERA from uid=10152 pid=26164[/B]
09-10 02:58:04.104 E/CameraService(  202): Permission Denial: can't use the camera pid=26164, uid=10152
09-10 02:58:04.104 W/CameraBase(26164): An error occurred while connecting to camera: 0
09-10 02:58:04.104 E/JavaCameraView(26164): Camera #0failed to open: Fail to connect to camera service
09-10 02:58:04.104 D/JavaCameraView(26164): Trying to open camera with new open(1)
[B]09-10 02:58:04.105 W/ServiceManager(  202): Permission failure: android.permission.CAMERA from uid=10152 pid=26164[/B]
09-10 02:58:04.105 E/CameraService(  202): Permission Denial: can't use the camera pid=26164, uid=10152
09-10 02:58:04.105 W/CameraBase(26164): An error occurred while connecting to camera: 1
09-10 02:58:04.105 E/JavaCameraView(26164): Camera #1failed to open: Fail to connect to camera service
There's your problem ;)
Are you sure you granted permission to use the camera?
 
  • Like
Reactions: BIade

spiff72

New member
Apr 14, 2006
476
39
0
I can't get this to work right. I have a brown-black-orange 5% resistor and I can't get the correct value to save my life. I even tried manually entering the brown black orange sequence and I get 1.03 kohm instead of 10 kohm

Sent from my SM-T320 using Tapatalk
 

BIade

Senior Member
Apr 11, 2013
692
543
93
Cologne
...
There's your problem ;)
Are you sure you granted permission to use the camera?
LOL i did not block cam-access, and since other apps (like whatsapp) had permissions, i thought it had to do with Android M.
I was not been asked to grant access in any way...

For others facing the same strage problem:
Open App-settings of scanR -> Permissions -> and turn on camera
@laufersteppenwolf Thank you sir! Good service!
Perhaps you can add this info in a short sentence for other users in your OP or FAQ