Skip to content

feat(Hardware Support): Qualcomm SSC sensors through FastRPC#590

Draft
gio3k wants to merge 7 commits into
ShadowBlip:mainfrom
gio3k:dev/gio/ssc
Draft

feat(Hardware Support): Qualcomm SSC sensors through FastRPC#590
gio3k wants to merge 7 commits into
ShadowBlip:mainfrom
gio3k:dev/gio/ssc

Conversation

@gio3k
Copy link
Copy Markdown

@gio3k gio3k commented May 21, 2026

This PR adds support for the FastRPC "subsystem" and the Qualcomm Sensor Core

When combined with the correct sensor data and hexagonrpc, this can provide accelerometer & gyroscope support to Snapdragon handhelds that use the SSC for that

Big changes, in no order:

  • libloading has been added as a dependency
  • libssc, glib and gobject are runtime dependencies (they don't need to be on the build machine or any targets that don't need it)
  • FastRPC has been added as an input source / "subsystem"
  • ssc has been added as a driver

I'm opening this as a draft as I have a couple concerns:

  • FastRPC devices show up in the "misc" subsystem - UdevDevice now checks for devices with the misc subsystem and fastrpc prefix, then fakes the subsystem
  • I'd like to see what other people think of the dylib loading at runtime, it's a bit weird code-wise but I'm not sure there's a better way here

Also, minor naming concern:

Maybe the ssc driver should be split into two, something like:

drivers/ssc/runtime.rs, drivers/ssc/bindings.rs
drivers/ssc_imu/driver.rs, drivers/ssc_imu/event.rs

This is because SSC can provide other sensor data in the future aside from gyro / accel.

Where would I put the drivers/ssc folder in that case - it seems out of place to have it there if it's just the core SSC stuff?

gio3k added 6 commits May 21, 2026 11:17
Adds a default value for MountMatrix (just an identity matrix)

Signed-off-by: Gianni Spadoni <me@gio.blue>
libloading will help us load dylibs, which we need for the libssc / FastRPC implementation

Signed-off-by: Gianni Spadoni <me@gio.blue>
This implements support for the Qualcomm Sensor Core (SSC), which provides accel and gyro to some Snapdragon based handhelds made in the past 8 years or so

This requires libssc as a runtime dependency, and requires libloading as a build time & runtime dependency

As FastRPC devices don't actually show up in a "fastrpc" subsystem, and instead use the "misc" subsystem, some logic has been added to udev/device.rs to check for fastrpc devices and fake the subsystem

Signed-off-by: Gianni Spadoni <me@gio.blue>
Based on IIOIMUDevice

Signed-off-by: Gianni Spadoni <me@gio.blue>
Signed-off-by: Gianni Spadoni <me@gio.blue>
Makes sure we don't get stuck trying to init the sensor if the subsystem isn't ready

Signed-off-by: Gianni Spadoni <me@gio.blue>
Also ups the gyro scaling from 14.0 -> 16.0

Signed-off-by: Gianni Spadoni <me@gio.blue>
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.

1 participant