code-scanner icon indicating copy to clipboard operation
code-scanner copied to clipboard

Flash not working on Redmi Note 8 Pro

Open Gl0deanR opened this issue 3 years ago • 14 comments
trafficstars

I have made a demo app for my school project and it works just fine until I tested it on a Xiaomi Redmi Note 8 Pro running MUI Global v12.0.5 Stable, Android 10. Tested the app on several Samsung phones and everything works. Permissions and all, focus, flashlight, scanning. Except when I installed it on a Xiaomi Redmi Note 8 Pro. Here, everything but the flashlight work perfectly.

The only errors I see in Android Studio when running on debug mode are:

E/GraphicExt: GraphicExtModuleLoader::CreateGraphicExtInstance false

E/libc: Access denied finding property "camera.aux.packagelist"

E/libc: Access denied finding property "vendor.camera.hal1.packagelist"

I am using the latest version of the code scanner: implementation("com.github.yuriy-budiyev:code-scanner:2.1.2")

And I am using the permissions: <uses-permission android:name="android.permission.CAMERA"> and I have also tried with: <uses-feature android:name="android.hardware.camera">

I would appreciate so, so much if anyone found or finds a fix to this.

Edit: Is it possible to make the app no longer have access to the flashlight? This way I believe I can turn it on from the top bar (quick access menu) because right now, when the app runs, the flashlight button is disabled.

Thank you!

Gl0deanR avatar Mar 22 '22 09:03 Gl0deanR

Gl0deanR did you find any solution??. I am getting same error on Samsung S9 Android 10.

HunterPillu avatar May 18 '22 10:05 HunterPillu

Gl0deanR did you find any solution??. I am getting same error on Samsung S9 Android 10.

No... I'm still waiting for @yuriy-budiyev response, maybe he will know ho to fix this for us.

Gl0deanR avatar May 18 '22 10:05 Gl0deanR

I'm also having the same issue with some device Vivo x70 pro

mahendradabiaplite avatar May 25 '22 12:05 mahendradabiaplite

@mahendradabiaplite could you please try again by adding uses-feature android:name="android.hardware.camera.any" and uses-feature android:name="android.hardware.camera.flashlight"

HunterPillu avatar May 25 '22 17:05 HunterPillu

@HunterPillu not working after adding this permission too in vivo x70 pro

mahendradabiaplite avatar May 26 '22 08:05 mahendradabiaplite

Hello @yuriy-budiyev could you please help and suggest what will the issue for the flashlight working in some devices and not working in some devices?

mahendradabiaplite avatar May 30 '22 08:05 mahendradabiaplite

@yuriy-budiyev any update on this?

mpierucci avatar Jun 15 '22 20:06 mpierucci

Also not working on Samsung A22 5G

RuiEEE avatar Aug 02 '22 21:08 RuiEEE

Also not working on Sony Xperia XZ3 and Samsung A03s

Wolfizarbabalam avatar Aug 22 '22 10:08 Wolfizarbabalam

an also not working on Redmi 10 s android 12 - S

Siddhesh2377 avatar Jan 07 '23 05:01 Siddhesh2377

Also not working in Samsung A04e

slmg-it-dept avatar May 09 '23 06:05 slmg-it-dept

did you find a solution

bahadirerdemm avatar Jun 03 '23 20:06 bahadirerdemm

did you find a solution

you can use this instead of that <com.journeyapps.barcodescanner.CompoundBarcodeView android:id="@+id/barcode_scanner" android:layout_width="match_parent" android:layout_height="match_parent"/>

slmg-it-dept avatar Jun 16 '23 04:06 slmg-it-dept

com.journeyapps.barcodescanner.CompoundBarcodeView

implementation 'com.journeyapps:zxing-android-embedded:4.3.0'

slmg-it-dept avatar Jun 16 '23 04:06 slmg-it-dept