E1 Prima Android BLE Protocol Recovery #
This working document describes the behavior recovered from:
- App: Victoria Arduino E1 Prima
- Package:
com.victoriaarduino.e1prima - Version:
4.0.0(versionCode816) - XAPK SHA-256:
abe3f7ff2860999515f69d7bfc33d71acd333aad0d873629a7cf1543bd4d41d5 - Base APK SHA-256:
42e874175e2b1ce4cc6bdcce8b5404c62b06799f45f664c996a8b5c3cf3e6e14 - Web protocol bundle SHA-256:
c6a4e6e992a042044b0af14c6788e4c9c7752641caaa258a34208f6545513b32 - APK signer subject:
CN=Developer, OU=Hibo Tech Area, O=Simonelli Group, L=Belforte del Chienti, ST=MC, C=IT - Minimum/target Android SDK: 23/35
- Analysis date: 2026-06-11
The app is a Capacitor/Cordova hybrid. Machine communication is implemented in the shipped JavaScript and uses cordova-plugin-ble-central 2.0.0. The ARM64 split contains SQLCipher only; it does not contain the machine protocol.
Document Set #
- This file: protocol architecture, lifecycle, transport, operations, validation, and tooling.
- settings.md: complete direct settings and multi-register write workflows.
- registers.md: all 196 recovered registers with access and usage classification.
- capabilities.json / capabilities.csv: machine-readable raw register map.
- ui-settings.json / ui-settings.csv: extracted UI ranges, scaling, labels, model variants, and defaults.
- validation-plan.md: machine-capture matrix and acceptance criteria.
- mac-client.md: build and operate the read-only Rust/macOS diagnostic client.
Evidence and Confidence #
- Static-confirmed: directly present in the shipped bundle, such as UUIDs, register addresses, frame construction, UI ranges, call order, and retry constants.
- Inferred: interpretation based on names or code context, such as treating PreWetting as pre-infusion or describing the read characteristic as a mailbox.
- Machine-unconfirmed: behavior requiring a physical capture, especially BLE link security, standalone response
01, exact string-block semantics, and firmware differences.
Unless stated otherwise, this document is static-confirmed for app version 4.0.0 and machine-unconfirmed.
Executive Summary #
The app communicates with the espresso machine over Bluetooth Low Energy GATT. It scans for names beginning with VA-Eagle1Gr, connects without an explicit Android bond operation, requests MTU 128 on Android, and uses one custom UUID for the service and both read/write characteristic roles:
cb6c6083-7f32-4446-9b1d-3ad2bef9ac6b
The application-layer protocol is a register map. Requests start with ASCII R (0x52) or W (0x57), followed by a 16-bit big-endian address and one-byte length. Numeric register values are signed big-endian integers, normally two bytes.
The UI calls connection validation "pairing," but this app version does not call the plugin's bond, setPin, or bondedDevices methods. Its isDevicePaired function simply proves protocol access by reading model, firmware, and Pure Brew registers. Any claim that link-layer bonding occurs must be validated with an HCI capture or machine firmware documentation.
App Capability Summary #
Machine-facing functions found in the app include:
- BLE discovery, connection, persistence, auto-connect, reconnect, and manual disconnect.
- Live machine monitoring: temperature, pressure, delivery time, alarms, and operating mode.
- Espresso doses, pre-wetting/pre-infusion, temperature, PBTech, and recipe application.
- Pure Brew mode, profiles, blooming/pulse parameters, doses, and recipes.
- Steam boiler, hot-water timing, EasyCream, display, LEDs, and automatic purge.
- Weekly wake/sleep programming and power management.
- Technical calibration offsets protected by an app-level machine password prompt.
- Counters, alarm history, maintenance targets, warning reset, and alarm-history reset.
- Phone-to-machine date/time synchronization.
The app also has account, cloud recipe, sharing/community, content, analytics, and local database features. Those use HTTP/local storage and are outside the BLE machine protocol described here.
Lifecycle #
1. Permissions and radio readiness #
On Android 12/API 31 and later, the app requests BLUETOOTH_CONNECT and BLUETOOTH_SCAN. On older Android versions it also checks location authorization and whether location services are enabled. If Bluetooth is disabled, the app attempts to enable it.
2. Discovery #
- Starts an unfiltered BLE scan:
startScan([]). - Filters discovered devices in application code by local name matching
^VA-Eagle1Gr. - A specific device ID can also be supplied as a regular-expression filter.
- The normal scan screen retries for 5, 7, 9, and 11 seconds before reporting no machines.
- On iOS, the local name may be taken from
kCBAdvDataLocalName.
3. Connection #
The connect screen deliberately disconnects the selected ID first, then calls the BLE plugin's connect. The connection has a 10-second application timeout. After Android connects, the app requests an MTU of 128 bytes and waits one second before validation.
The Cordova plugin performs GATT service discovery internally. The app itself does not subscribe to notifications and does not use write-without-response; it uses characteristic writes followed by characteristic reads.
4. "Pairing" validation #
The app verifies all of the following:
- GATT reports the device as connected.
- Read
CAPABILITY_MACHINE_PROat address 1703, length 2. - Read
CAPABILITY_FIRMWARE_VERSIONat address 800, length 2. - For non-Pro firmware 400 or later, read Pure Brew state at addresses 9000/9001 as applicable.
Successful reads classify the machine as Base, EXP, or Pro and persist its BLE ID and display name in the local database. This is application-level validation, not proof of Android bonding.
5. Post-connection initialization #
When the shared data provider observes a connected machine, it clears the command queue and then:
- Registers for the app's synthetic
BLE_disconnect_errorevent. - Writes phone date/time to registers 600 through 604.
- Reads the active recipe name and UUID.
- Reads EasyCream availability/state from registers 2073 and 2074.
- Marks connection initialization ready.
Firmware version and feature-state reads are cached in the provider. Other pages issue grouped reads for monitor data, doses, settings, counters, alarms, maintenance, and recipes.
6. Normal command execution #
- A single-concurrency queue serializes protocol operations.
- Queue timeout: 15 seconds.
- After writing a request, the app polls the read characteristic every 150 ms.
- Maximum read attempts per request: 20, approximately 3 seconds.
- Response matching uses the request command/address/length prefix for reads and command/address prefix for writes.
- A one-byte response
01is treated as "not ready" and skipped. - Responses for a different request prefix are skipped, which allows stale characteristic values to drain.
- A 16-byte all-zero fallback is treated as a disconnected read.
The code appears intended to add 150 ms between queued commands, but its delay callback creates a Promise without returning it. In this build, that queue item completes immediately. This should be confirmed against source history before treating the delay as a protocol requirement.
7. Disconnect and reconnect #
Read/write failures test isConnected; failure emits BLE_disconnect_error. For an unexpected disconnect of the current device, the data provider attempts to reconnect automatically. A manual disconnect suppresses that reconnect, waits 1.5 seconds, then calls the BLE disconnect operation and clears cached state.
Lifecycle Sequence #
User/App Android BLE Machine
| permissions/radio checks |
| startScan([]) -------------------------->|
|<------ advertisements: VA-Eagle1Gr* -----|
| disconnect(selected ID) |
| connect(selected ID) ------------------->|
| service discovery / GATT ready <-------->|
| request MTU 128 (Android) |
| wait 1 second |
| R: machine Pro flag -------------------->|
| poll characteristic <--------------------|
| R: firmware version -------------------->|
| R: Pure Brew state when applicable ---->|
| persist machine and model classification |
| W: phone date/time block --------------->|
| R: active recipe name/UUID ------------>|
| R: EasyCream state --------------------->|
| normal serialized reads/writes <-------->|
| unexpected failure -> reconnect |
Wire Format #
Request header #
| Offset | Size | Meaning |
|---|---|---|
| 0 | 1 | ASCII R (0x52) or W (0x57) |
| 1 | 2 | Register address, unsigned big-endian |
| 3 | 1 | Requested/declared length |
| 4 | variable | Write payload only |
Examples:
Read firmware version (address 800, 2 bytes): 52 03 20 02
Read machine Pro flag (address 1703, 2 bytes): 52 06 A7 02
Write value 1 to Pure Brew enabled (9001): 57 23 29 02 00 01
Response #
Responses use the same four-byte header shape followed by data. Numeric values of length 1, 2, or 4 are interpreted as signed integers. Write responses must decode to ASCII OK; ASCII ERR is recognized by the parser but fails the write check.
Likely examples, to be confirmed by capture:
Read firmware 500: 52 03 20 02 01 F4
Write acknowledgement: 57 <address:2> 02 4F 4B
There is no checksum, sequence number, encryption, or authentication field in the recovered application frame. BLE link-layer security, if any, is outside this frame and remains a dynamic-test question.
Block operations #
Block reads calculate length = count * elementSize, with a hard limit of 64. Returned data is divided into elements and mapped to consecutive register addresses. Two-byte data advances the logical address by one; four-byte data advances it by two.
Most block writes serialize signed values as two-byte big-endian fields. Recipe name/UUID writes use a special string layout and have a declared-length/payload-size relationship that deserves capture-based validation before reimplementation.
Protocol Operations #
| App operation | Register access |
|---|---|
| Firmware version | Read 800, 2 bytes |
| Model validation | Read 1703, then 800 and Pure Brew state |
| Clock sync | Write 600-604 as one 10-byte block |
| Weekly programming | Read 100-131 as a 64-byte block; write selected fields individually |
| Monitor polling | Read from 2, 400, optional 133, and mode-dependent recipe/status fields |
| Key/display settings | Read block beginning 1707; length depends on model/feature state |
| Espresso doses/settings | Read 3, blocks beginning 2003 and 2041, hot water at 1508, EasyCream at 2073 |
| Temperature settings | Read 400-401, 2002, optional 9003 and 133 |
| Calibration offsets | Read 1100-1112 and discard reserved gaps |
| Alarm history | Read 1200-1234 in two blocks |
| Counters | Read 32-bit blocks beginning 4078, 5000, 5020, 5034, and 5078 |
| Maintenance warning | Read 6006 as 32-bit plus 6008-6014 as 16-bit fields |
| Automatic purge | Read 8000-8002 |
| Espresso recipe | Ordered block writes at 2001, 2004, 2009, 2041, then name/UUID |
| Pure Brew recipe | Block writes at 9002 and 9100, then name/UUID |
Detailed field definitions and write order are in settings.md.
Model and Firmware Gates #
- Pro classification takes precedence over Pure Brew availability.
- Non-Pro firmware below 400 skips Pure Brew probing and is treated as not supporting it.
- Pro firmware 104 or later reads the steam-boiler-enabled register at 133.
- Non-Pro firmware 500 or later changes the allowed lower steam pressure setpoint and enables additional mode behavior.
- Pure Brew setting groups are activated or hidden according to availability at 9000 and enabled mode at 9001.
- EasyCream fields are read only when 2073/2074 indicate the feature is active.
- The app caches firmware, Pure Brew state, and EasyCream state after connection.
Security and Authorization #
- No application-layer checksum, MAC, nonce, session key, or authentication field is present in recovered frames.
- The app does not explicitly initiate BLE bonding and does not submit a BLE PIN.
- Technical settings read a four-byte value from register 806 and compare the user's decimal input locally. The password is not written back to the machine.
- The XAPK alone cannot prove whether the machine requires encrypted ATT or initiates link-layer security. Confirm this with an Android HCI trace.
- Anyone implementing a client should add local authorization and safe operating limits rather than assuming the machine protocol enforces them.
Important Registers #
| Capability | Address | Length | Access | Purpose |
|---|---|---|---|---|
CAPABILITY_GROUP_TEMPERATURE |
2 | 2 | R | Live group temperature, scaled by 10 in UI |
CAPABILITY_FIRMWARE_VERSION |
800 | 2 | R | Firmware feature gating |
CAPABILITY_MACHINE_TYPE |
804 | 2 | R | Machine type |
CAPABILITY_BLE_PASSWORD |
806 | 4 | R | Password shown by protected-settings prompt; not used for BLE bonding |
CAPABILITY_MACHINE_STATUS |
1702 | 2 | R | Machine status |
CAPABILITY_MACHINE_PRO |
1703 | 2 | R | Pro classification flag |
CAPABILITY_RECIPE_NAME |
2013 | 10 | R/W | Espresso recipe name storage |
CAPABILITY_RECIPE_UUID |
2023 | 18 | R/W | Espresso recipe UUID storage |
CAPABILITY_PURE_BREW_AVAILABLE |
9000 | 2 | R | Pure Brew capability flag |
CAPABILITY_PURE_BREW_ENABLED |
9001 | 2 | R/W | Espresso/Pure Brew mode |
See registers.md for the complete annotated table or capabilities.csv / capabilities.json for all 196 machine-readable entries. Writable settings and recipe behavior are in settings.md.
Dynamic Validation Runbook #
Use an isolated test machine and an authorized test account. Start with reads and avoid writes to heating, cleaning, calibration, maintenance, and recipe registers until the team has reviewed the register table.
-
Use an ARM64 Android phone. Enable Developer options, USB debugging, and Enable Bluetooth HCI snoop log.
-
Install all APK splits together:
adb install-multiple -r analysis/xapk/*.apk -
Clear old state for a clean lifecycle test:
adb shell pm clear com.victoriaarduino.e1prima -
Capture application logs while scanning, connecting, reading one screen, changing one benign setting, and disconnecting:
adb logcat -c adb logcat -v threadtime > e1-prima-logcat.txt -
Record exact timestamps and UI actions in a test worksheet. Change one variable per run.
-
Generate a bug report after the run. Android bug reports commonly contain the Bluetooth HCI snoop capture:
adb bugreport e1-prima-bugreport -
Open the HCI capture in Wireshark. Start with the
btattdisplay filter, identify the handle for UUIDcb6c6083-7f32-4446-9b1d-3ad2bef9ac6b, and compare characteristic value bytes with the examples above. -
Independently connect with nRF Connect for Mobile to verify the GATT service, characteristic properties, read behavior, and whether the OS ever requests bonding.
-
Repeat the lifecycle with Bluetooth turned off, machine out of range, and an unexpected disconnect to document failure behavior.
Tooling #
Required:
unzip,shasum, andjqfor XAPK inventory and evidence hashes.- Node.js for extracting the shipped web bundle and running the included protocol tools.
- Android SDK Platform Tools (
adb) for split installation, logcat, package reset, and bug reports. - A physical ARM64 Android phone; an emulator cannot validate the real BLE radio path reliably.
- Wireshark for ATT/GATT packet analysis.
- nRF Connect for Mobile for direct GATT discovery and controlled characteristic reads/writes.
Useful but secondary:
- JADX for decoded manifests, plugin Java code, and native bridge behavior. It accepts XAPK directly.
- Apktool for resource/smali inspection and manifest reconstruction.
- Chrome DevTools remote WebView inspection, if the release WebView permits debugging.
- Frida for authorized runtime hooks around Cordova BLE calls when logcat and HCI capture are insufficient.
- An nRF52840-class BLE sniffer for over-the-air capture independent of the Android host.
For this XAPK, start with the JavaScript bundle. JADX is not the shortest path to the protocol because the app's own register map and codec are already present in assets/public/assets/index-B5zV0Gdo.js.
Reproducibility #
After unpacking the base APK, regenerate the registry with:
node tools/extract-capabilities.mjs \
analysis/base/assets/public/assets/index-B5zV0Gdo.js \
docs/e1-prima
node tools/extract-ui-settings.mjs \
analysis/base/assets/public/assets/index-B5zV0Gdo.js
node tools/generate-register-docs.mjs
Encode and decode frames with:
node tools/protocol-frame.mjs read 800 2
node tools/protocol-frame.mjs write 9001 2 1
node tools/protocol-frame.mjs decode 5203200201F4
Open Questions #
- Does the machine request BLE link-layer encryption or bonding despite the app not initiating it?
- Are service and read/write UUIDs truly identical in the machine's GATT table, or is this normalized by the plugin/device firmware?
- What does standalone response
01mean: busy, pending, or empty mailbox? - Is the read characteristic a mailbox holding the latest response, and when is it cleared?
- What is the exact recipe name/UUID block-write length convention?
- Are negative calibration values accepted as signed two's-complement fields exactly as the app assumes?
- Does firmware behavior differ across Base, EXP, and Pro generations?
These questions should remain marked unconfirmed until backed by HCI traces or firmware-side source.
External References #
- JADX: https://github.com/skylot/jadx
- Apktool: https://apktool.org/docs/install/
- Android developer options: https://developer.android.com/studio/debug/dev-options
- Android bug reports: https://developer.android.com/studio/debug/bug-report
- Android BLE GATT connection model: https://developer.android.com/develop/connectivity/bluetooth/ble/connect-gatt-server
- nRF Connect for Mobile: https://www.nordicsemi.com/Products/Development-tools/nRF-Connect-for-mobile
- Wireshark Bluetooth ATT filters: https://www.wireshark.org/docs/dfref/b/btatt.html