Developer Hub / Barcode / scanner

Barcode scanner integration

Build one scanner boundary, normalize wedge, intent or direct results, and close every session cleanly.

Publishing standardDevelopers

Connect and validate your application on target hardware.

A repeatable scan flow that delivers one application-owned event shape.

Android developers integrating a handheld scanner into an existing app.

Technical content is the core of RuggedLayer. Public resources show reproducible device-interface patterns and the evidence needed to move an existing app toward deployment, while restricted manufacturer SDKs remain behind approved distribution channels.

Comparable device evidence with method, version and limitations.

Developer resourcesBarcode / scanner
RuggedLayer Test LabBeginner
Technical guides, SDK notes, sample apps and compatibility data for connecting existing enterprise applications to rugged Android devices.Android developers integrating a handheld scanner into an existing app.
  • An Android app with one workflow that needs a barcode result.
  • The exact target model, Android build and approved device SDK identified.
  • A decision about wedge, intent or direct SDK transport; do not mix them accidentally.

Publishing standard

Build and validate enterprise Android integrations with versioned evidence.

Technical content is the core of RuggedLayer. Public resources show reproducible device-interface patterns and the evidence needed to move an existing app toward deployment, while restricted manufacturer SDKs remain behind approved distribution channels.

  1. 01

    Choose the transport for the workflow

    Use wedge when a focused form needs a fast retrofit. Use an explicit intent or callback when the application owns the event. Use a direct device API only behind a small adapter so business screens do not depend on vendor types.

  2. 02

    Define the event your application owns

    Keep decoded text, raw bytes, symbology and received time together. Treat the transport payload as untrusted input and reject missing, oversized or undecodable data before it reaches inventory logic.

  3. 03

    Open, listen, start and stop in one owner

    Register the result path before starting a decode. Start only once, stop when the workflow ends, and close the device resource from every exit path including background, cancellation and errors.

  4. 04

    Prove the unhappy paths

    Test an empty payload, duplicate result, timeout, unsupported symbology, screen resume and a device with no scanner option. A green scan on one device is not a compatibility statement for every configuration.

Sample apps / Kotlin

SDK and API patterns

Original adapter pattern. Bind CapturePort to the approved device SDK in your private Android project.

scan-boundary.kt

data class CaptureEvent(
  val value: String,
  val symbology: String?,
  val capturedAt: Instant,
)

interface CapturePort {
  fun open()
  fun start()
  fun stop()
  fun close()
  fun setListener(listener: (CaptureEvent) -> Unit)
}

class ScanWorkflow(private val scanner: CapturePort) {
  private var active = false

  fun begin(onCapture: (CaptureEvent) -> Unit) {
    if (active) return
    scanner.open()
    scanner.setListener(onCapture)
    scanner.start()
    active = true
  }

  fun end() {
    if (!active) return
    runCatching { scanner.stop() }
    runCatching { scanner.close() }
    active = false
  }
}
No vendor binary, API reference, firmware or source sample is published until its redistribution permission and supported scope are recorded.

SDK distribution

Publication gate

No vendor binary, API reference, firmware or source sample is published until its redistribution permission and supported scope are recorded.

No value or raw bytes

Return an input error and keep the workflow available for another scan.

Same result arrives twice

Deduplicate by a short-lived event key; never silently double-receive inventory.

Timeout or scanner busy

Stop the current operation, show a recoverable state and allow a controlled retry.

Screen leaves the foreground

Stop or pause according to the workflow contract, then re-register safely on resume.

How to read the references

Comparable device evidence with method, version and limitations.

  1. 01

    Record model, scanner option, Android build, firmware and SDK release.

  2. 02

    Run cold start, repeated start/stop, background/resume and cancellation tests.

  3. 03

    Use Code 128, a damaged label, an empty trigger and one unsupported symbology.

  4. 04

    Confirm that no raw scan data or customer identifier is written to ordinary logs.

Connect and validate your application on target hardware. Run the same event contract with a fake adapter before connecting hardware.

Resources

SDK and API patterns

No vendor binary, API reference, firmware or source sample is published until its redistribution permission and supported scope are recorded.

Connect and validate your application on target hardware.

Share the non-confidential app workflow, current device and integration path; we will scope the closest validation deliverable.

Connect and validate my application