Appendix · reference

Silan SC7A20 accelerometer

PineTab2 3-axis accelerometer on i2c5; candidate sysctl driver, bench pending

Identity

PartSilan SC7A20 3-axis accelerometer
RoleTablet orientation / motion sensing
Bus / addressPineTab2 i2c5 addr 0x18; WHO_AM_I (reg 0x0f) = 0x11
GPIO / IRQINT on GPIO3_A2 in the Linux DTS; IRQ is not wired in the first FreeBSD driver slice
PineTab2 DTScompatible = "silan,sc7a20"
Linux referencemainline drivers/iio/accel/st_accel*; SC7A20 is treated as LIS2DH-compatible

Status — ◐ partial

The local tree now has a candidate iicbus driver at src/sys/dev/iicbus/sc7a20.c, and PINETAB2 includes device sc7a20. It probes silan,sc7a20, checks WHO_AM_I == 0x11, enables normal 100 Hz XYZ sampling, and exposes raw axis sysctls under dev.sc7a20.0.*.

This is still bench-pending. No PineTab2 run has confirmed that the chip responds on i2c5, that the board axis signs match the Linux orientation policy, or that the GPIO3_A2 interrupt mapping works.

Driver Shape

The first slice intentionally avoids IRQs and evdev. Polled sysctls are enough to prove the I2C path and board orientation without adding a tablet policy surface before the hardware is on the bench.

Bring-Up Predicate

After a PineTab2 boot with the first-boot DTB:

sysctl dev.sc7a20.0

Expected first-pass evidence:

  1. dev.sc7a20.0.whoami reports 17 (0x11).
  2. One of accel_*_mg sits near +/-1000 when the tablet is flat and stationary.
  3. Rotating the tablet moves that +/-1000 g-vector between axes with a stable sign.
  4. status changes while the tablet is being moved.

Open Work