Skip to content

Fix Renpho ES-30M (QN-Scale) support#1301

Merged
oliexdev merged 1 commit intooliexdev:masterfrom
8bitgentleman:fix-es30m-support
Feb 15, 2026
Merged

Fix Renpho ES-30M (QN-Scale) support#1301
oliexdev merged 1 commit intooliexdev:masterfrom
8bitgentleman:fix-es30m-support

Conversation

@8bitgentleman
Copy link
Copy Markdown
Contributor

I recently got an ES-30M scale and since it wasn't working with openScale decided to do some investigating. The ES-30M scale was connecting but not recording measurements due to incomplete protocol handshake and incorrect frame parsing.

Fixes #986

Problem

The ES-30M scale (advertises as "QN-Scale") was connecting successfully but not
recording measurements. The app showed "step on barefoot" but weight data never
appeared.

Root Cause

  1. Incomplete handshake: The scale requires specific responses to 0x21 opcode
    before sending weight data
  2. Wrong frame format: ES-30M uses a different byte layout than other QN
    scales

Solution

1. Fixed Protocol Handshake

  • 0x21 handler: Now sends TWO 0xA0 responses (was sending one incorrect
    response)
  • 0x14 handler: Sends proper 0x20 time sync with real timestamp (was sending
    fixed bytes)
  • Added 0x22 query: After 0xA0 responses, queries stored data

2. Added Format Detection for 0x10 Weight Frames

ES-30M uses a different byte layout:
ES-30M format:
byte[3] = unit (kg/lb)
byte[4] = stable flag (0x00/0x01/0x02)
bytes[5,6] = weight (big-endian)
bytes[7-10] = resistances

Original QN format:
bytes[3,4] = weight (big-endian)
byte[5] = stable flag (0x01)
bytes[6-9] = resistances

Detection logic: If byte[4] <= 0x02 AND weightScaleFactor == 10.0, use
ES-30M format.

3. Added Opcode Handlers

  • 0x23 (user data frames)
  • 0xA1, 0xA3 (acknowledgments)

Backward Compatibility

Format detection ensures existing QN scales continue working with the original
format. ES-30M is auto-detected based on:

  • Byte pattern (stable flag at byte[4])
  • Weight scale factor (10.0 for ES-30M vs 100.0 for most others)

Testing

  • ✅ ES-30M now successfully records weight and body composition
  • ✅ Format detection works correctly
  • ⚠️ Other QN scale models should be tested to confirm no regression

Technical Details

This is based on BLE traffic capture comparing the official Renpho app (working) vs openScale (not
working). The ES-30M requires a complete handshake sequence before transmitting
weight data.

The ES-30M scale was connecting but not recording measurements due to
incomplete protocol handshake and incorrect frame parsing.

Changes:
- Fix 0x21 handler to send two 0xA0 responses (was sending one incorrect response)
- Add 0x22 data query after 0xA0 responses
- Fix 0x14 handler to send proper 0x20 time sync with real timestamp
- Add format detection in 0x10 weight parser for ES-30M vs other QN scales
  - ES-30M: byte[4]=stable, bytes[5,6]=weight, bytes[7-10]=resistances
  - Original: byte[5]=stable, bytes[3,4]=weight, bytes[6-9]=resistances
- Add handlers for 0x23, 0xA1, 0xA3 opcodes

The format detection is backward compatible and does not affect other
QN scales. Detection logic: byte[4] <= 0x02 AND weightScaleFactor == 10.0f
indicates ES-30M format.

Fixes oliexdev#986
@oliexdev oliexdev merged commit 5cdbd96 into oliexdev:master Feb 15, 2026
@oliexdev
Copy link
Copy Markdown
Owner

Thanks for your PR 👍

Ebonhawk3829 added a commit to Ebonhawk3829/openScale that referenced this pull request Apr 22, 2026
The ES-30M (PR oliexdev#1301) needs two 0xA0 frames and an i mmediate 0x22 query, while the ES-CS20M needs a single 0xA0 and must wait for the 0xA1 ACK before sending 0x22.

Use the existing weightScaleFactor == 10.0f heuristic to detect ES-30M and branch accordingly in both the 0x21 and 0xA1 handlers, preserving correct behavior for both scales.
@Edouard-B
Copy link
Copy Markdown

Hello,
I have an ES-30M scale with the latest firmware (V9.0) and openScale 3.1.0 downloaded from F-Droid.

It seems to me that despite your PR, I still don’t have access to the measurements. The Renpho app works fine, but on openScale I only see “Please step on the scale barefoot” and then nothing else.

Is there a problem with this PR? Thanks for your help.

If needed, I can run some tests on my scale, but I’m not very familiar with how it works.

Translated with DeepL.com (free version)

@8bitgentleman
Copy link
Copy Markdown
Contributor Author

Hmm how did you check what version of scale firmware you have? This is still working fine on mine

@Edouard-B
Copy link
Copy Markdown

Edouard-B commented Apr 27, 2026

I checked with the Renpho Health app. There was a firmware update (I've just bought the scale), I applied it and it then said v9.0. I'm not sure what number it was before the update.

signal-2026-04-27-131616

Should it be a different app or a different firmware version?

(I've redacted the device code, I don't know what it is... do you need it?)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Bug on connecting to RENPHO Elis 1 (Model: ES-30M-US)

3 participants