Skip to content

[catfish_ext] Step counter works in nanohub but no STEP_COUNTER events reach sensorfw #333

Description

@p6zem0

Device

  • Watch: Mobvoi TicWatch Pro WF12106
  • AsteroidOS device codename: catfish_ext
  • AsteroidOS version: 2.1
  • Architecture: armv7vehf-neon

Problem

The step counter shown by asteroid-health always remains at zero.

The nanohub firmware itself detects walking and counts steps correctly, but no STEP_COUNTER events appear to reach sensorfwd. As a result, asteroid-sensorlogd only records zero values.

Heart rate, accelerometer, light sensor and wrist-tilt events work.

Installed package versions

asteroid-sensorlogd - 0.9+git0+f46ac73ac2-r1
libhybris - 1:0.1.0+git0+9f61f26c44-r1
libqt5sensors-plugins - 5.15.16+git0+d1b4005610-r0
libqt5sensors-qmlplugins - 5.15.16+git0+d1b4005610-r0
libqt5sensors5 - 5.15.16+git0+d1b4005610-r0
sensorfw - +git0+bec350b88a-r1
sensorfw-hybris-hal-plugins - +git0+bec350b88a-r1

Relevant configuration

/etc/sensorfw/primaryuse.conf contains:

stepcounteradaptor = hybrisstepcounteradaptor

/etc/sensorfw/sensord.conf.d/20-sensors-default.conf contains:

stepcountersensor=True

/etc/xdg/QtProject/Sensors.conf contains:

QStepCounterSensor=sensorfw.stepcountersensor

The relevant plugins are installed:

/usr/lib/sensord-qt5/libstepcountersensor-qt5.so
/usr/lib/sensord-qt5/libhybrisstepcounteradaptor-qt5.so
/usr/lib/libhybrissensorfw-qt5.so.1.0.0

Android/vendor HAL

The vendor HAL contains both step sensors:

Step Detector
android.sensor.step_detector
Step Counter
android.sensor.step_counter

This was confirmed with:

strings /vendor/lib/hw/sensors.nanohub.so |
grep -Ei 'step|counter|detector|pedo'

The device also declares:

/vendor/etc/permissions/android.hardware.sensor.stepcounter.xml
/vendor/etc/permissions/android.hardware.sensor.stepdetector.xml

Nanohub result

The nanohub firmware initializes the step counter:

[STEP_STATUS] Power on: Counter
[COUNTER] Step Counter initialization
[COUNTER] Current version: 1.2.5
[STEP_STATUS] Last step counts: 0

During walking, the nanohub correctly increases the value:

[COUNTER] Change to walking. Steps = 113
[COUNTER] Change to idle. Steps = 196

A later test produced:

[COUNTER] Change to walking. Steps = 218
[COUNTER] Change to idle. Steps = 253

So the accelerometer, nanohub firmware and step-counting algorithm are working.

SensorFW result

sensorfwd repeatedly reports:

"stepcounteradaptor" No initial data for step counter

With SensorFW debug logging enabled using SIGUSR1, accelerometer, light and wrist-tilt events are visible:

QUEUE HYBRIS EVE ACCELEROMETER
HYBRIS EVE ACCELEROMETER
QUEUE HYBRIS EVE LIGHT
HYBRIS EVE LIGHT
QUEUE HYBRIS EVE WRIST_TILT_GESTURE
HYBRIS EVE WRIST_TILT_GESTURE

However, while the nanohub counter increases, there are no events such as:

HYBRIS EVE STEP_COUNTER

or any other step-counter/step-detector event in the sensorfwd journal.

Sensor log

asteroid-sensorlogd writes only zero values:

1785304559:0
1785305187:0
1785306121:0
1785307234:0
1785308313:0
1785308562:0

The file is:

/home/ceres/.asteroid-sensorlogd/stepCounter/2026-07-29.log

Additional observations

There is no Android framework sensorservice available:

Can't find service: sensorservice

The vendor HIDL sensor service and HAL files are present:

/vendor/bin/hw/android.hardware.sensors@1.0-service
/vendor/lib/hw/android.hardware.sensors@1.0-impl.so
/vendor/lib/hw/sensors.nanohub.so

Nanohub firmware reported at runtime:

Nanohub FW version: 0x19061201

The firmware file available in the image is:

/vendor/firmware/nanohub.full.catshark.20033010.bin

I did not attempt to flash or replace the nanohub firmware.

Expected result

HybrisStepCounterAdaptor::processSample() should receive cumulative STEP_COUNTER events from the vendor HAL and expose them through SensorFW and Qt Sensors.

Actual result

The nanohub counts steps, but no STEP_COUNTER event reaches SensorFW. HybrisStepCounterAdaptor::sendInitialData() therefore reports that no initial data is available, and Asteroid Health displays zero.

Suspected area

The issue appears to be between:

sensors.nanohub.so
→ libhybris / libhybrissensorfw
→ HybrisStepCounterAdaptor

It may involve activation or event handling for the Android SENSOR_TYPE_STEP_COUNTER on catfish_ext.

Please let me know if additional logs or tests are needed.

catfish-sensorlogd-steps.log
catfish-nanohub-stepcounter.log

catfish-sensorfwd-stepcounter.log

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions