Hi guys, I'm facing a problem with my Compose mult...
# multiplatform
e
Hi guys, I'm facing a problem with my Compose multiplatform project. When I try to read barcodes with my Zebra ET45 internal scanner, the focus loses completely, and I can't write anything else. Can anyone help me with this?
not kotlin but kotlin colored 2
f
I don’t think it’s a kotlin issue
d
Usually barcode readers can operate in either HID mode (for compatibility with all Apps) or via dedicated channel (best user experience). In HID mode they're emulating a keyboard, which is probably interacting badly with Compose in this case. Likely the configuration is emitting tabs, newlines or other control codes along with the barcode digits themselves, and that's causing a focus change. See if you can initialise the reader in a different mode. On handheld wireless scanners this usually means connecting Bluetooth in RFCOMM Bluetooth profile (emulating a Serial port), but for an internal Zebra scanner I'd expect some SDK function. Overall I agree with @François this is almost certainly a Zebra Scanner issue and not a Kotlin one. See: Zebra Scanner SDK for Android
e
Thanks guys I resolved the problem already
🙌 1
d
@Esteban Vasquez Anything worth sharing? I may be deploying CMP on Zebra Devices soon too.
e
Nothing special, I just created a new project and I compared both since the second one worked without any issues, so the solution just was upgrading my gradle plugin to the actual version. I'm not an expert so I don't know why it works now!
👍 1