Fast, accurate scanning to Input element

I am after some advice for my barcode scanning app.

The devices running my App have either USB or bluetooth 2D scanners attached, they connect as a ‘keyboard’ and push 13-digit barcodes followed by a carriage return to regular input elements.

Post-scan processing occurs with each scan triggered when the vaule in the input is changed, then the input is cleared after each scan.

I’m finding, irrespective of device and scanners used, that some barcodes append together and/or skip the carriage return (leaving the barcode in the input) causing data quality issues and missed scans.

To rule out hardware, I’ve tested scanning direct to notepad as fast as possible and data capture is perfect.

I’ve tried using two alternating inputs, showing the 2nd as soon as the 1st has its value changed. This improves things slightly, but the problem persists.

Asking my users to “scan slower” isn’t an option.

I’d value the community’s opinion or ideas on this.

Would writing scans to a custom state list FIFO-style speed this up perhaps?
if so, would this be achieved using:

  • a “do every x seconds” workflow?
  • a “Do when condition is true” workflow?

Or, is this an inherent limitation of the input element I’m unlikely to get past?
I’ve seen another post for writing to a multiline input instead, but not sure how to process multiline entries in this manner.

Appreciate it if you read this far. Look forward to any responses :slight_smile:

Ben

Hey @nalsey :wave:

I think your problem might be about the late firing of the input's value changed event which is a known limitation of the built-in input element in Bubble.

You can use the 1T - Input Watcher Plugin | Bubble plugin for a faster firing of the changed event. See the demo below:
brave_IqcnFMENdi

  • If you want to give it a shot, you have to enable IDs in your settings:

  • Then, you will assign an ID to your input:

  • Create an Watch Input with the ID field refering to your textfield:

    • image
  • Then, you will create the workflow for this Watch Input's Value Changed:

You can also create an event for enter is pressed:
image

Here is the full editor if you want to see details: Bubble Demos by Flusk | Bubble Editor

I hope this helps.

bdk_512x512 @Huseyin from Flusk | Discover the #1 Security and Monitoring Tool for Bubble

2 Likes

Many thanks Flusk - I suspected this was the most likely cause, but hadn’t come across this plugin - i’ll give it a shot and respond with results.

Update: I have used this plugin to watch when enter is pressed (as opposed to when the input is changed) - and it has worked perfectly.

Thank you very much for your help!

Ben

1 Like

This topic was automatically closed after 70 days. New replies are no longer allowed.