Fix the missing cover-panel reaction with a 9-bit panel path and sign-off probe
Live diagnosis with the flip physically closed showed the wake chain is intact: bananarchy-coverctl BUTTON/WAKE, the lid gate and sxmo_state.sh set unlock all reached backend=spidev visible=1 mux=closed, with the daemon holding /dev/spidev0.1, the gpiochip and its line handles. The outer panel itself never reacted. Register reads over SPI return zeros (write-only panels), gpio21 stays static, and a reversible panel-mipi-dbi-spi/spidev rebind on spi0.0 showed the shared gpio110 D/C path is also unreadable, so the missing piece is the panel framing: the KaiOS downstream DTS labels gpio21 TE, not D/C, and Qualcomm MDSS SPI carries D/C as the ninth bit. bananarchy-cover-idle now defaults to 9-bit MIPI DBI: it releases gpio21, claims only the reset line, and frames every command and pixel as a little-endian 9-bit word with D/C in bit 8. spi_word_bits = 8 keeps the old D/C-GPIO path. A PROBE command walks twelve combinations of word width, gpio13 mux level, reset/D-C polarity and 25 MHz / 5 MHz clock, re-initialising the panel and drawing TEST bars; STATUS reports bits= and probe=case N/12. bananarchy-cover-probe.sh drives all twelve cases with a three-second hold so the working wiring can be written back to cover-display.conf. wanted_device() in common.h now also matches KEY_POWER, so the pm8941_pwrkey device (KEY_POWER only) is no longer invisible to bananarchy-volume-keys and all three outer buttons can produce a cover wake. Rebuilt the a1108/dejavu nokia-beatles image and pinned the verified hash 57d140e9cdf05631a6620b639d143350b9984b2170592fb927c93bfb18f67a2b in check-rebuild.sh. e2fsck -fn passed on both partitions, debugfs confirms seven updated rootfs files byte-for-byte, and the bootfs sync, boot image check, artifact sync, host tests and rebuild preflight all pass. Eyes-on confirmation of which case lights the cover, and the cover backlight source, are still required; this is an intermediate checkpoint.
This commit is contained in:
1 parent
2857ef4374
commit
5f8b7c88ac
15 files changed
+252
-28
No files matched your search
@@ -16,6 +16,9 @@ LID_SRC = BASE / "src/bananarchy-daemons/bananarchy-lid.c"
|
||||
COVER_SRC = BASE / "src/bananarchy-daemons/bananarchy-cover-idle.c"
|
||||
GATE = BASE / "overlay/rootfs/usr/bin/bananarchy-lid-gate.sh"
|
||||
LID_WRAPPER = BASE / "overlay/rootfs/usr/bin/bananarchy-lid-state.sh"
|
||||
COMMON = BASE / "src/bananarchy-daemons/common.h"
|
||||
COVER_CONF = BASE / "overlay/rootfs/etc/bananarchy/cover-display.conf"
|
||||
PROBE_SH = BASE / "overlay/rootfs/usr/bin/bananarchy-cover-probe.sh"
|
||||
WM = BASE / "overlay/rootfs/usr/bin/sxmo_wm.sh"
|
||||
STATE_SH = BASE / "overlay/rootfs/usr/bin/sxmo_state.sh"
|
||||
WAKE = BASE / "overlay/rootfs/usr/bin/bananarchy-screen-wake.sh"
|
||||
@@ -50,8 +53,9 @@ def run_gate(profile, state, arg="", stub=None):
|
||||
|
||||
|
||||
def main():
|
||||
paths = [LID_SRC, COVER_SRC, GATE, LID_WRAPPER, WM, STATE_SH, WAKE,
|
||||
DPMS_SYNC, EVENT, *INPUT_HOOKS, *HOOKS]
|
||||
paths = [LID_SRC, COVER_SRC, COMMON, COVER_CONF, PROBE_SH, GATE,
|
||||
LID_WRAPPER, WM, STATE_SH, WAKE, DPMS_SYNC, EVENT,
|
||||
*INPUT_HOOKS, *HOOKS]
|
||||
for path in paths:
|
||||
if not path.is_file():
|
||||
return fail("missing %s" % path.relative_to(BASE))
|
||||
@@ -103,6 +107,12 @@ def main():
|
||||
event = EVENT.read_text(encoding="utf-8")
|
||||
if " wake)" not in event or "coverctl WAKE" not in event:
|
||||
return fail("cover event bridge lost the wake forwarding case")
|
||||
common = COMMON.read_text(encoding="utf-8")
|
||||
if "device_has_code(fd, EV_KEY, KEY_POWER)" not in common:
|
||||
return fail("the End/Power key is not watched while the flip is closed")
|
||||
conf = COVER_CONF.read_text(encoding="utf-8")
|
||||
if "spi_word_bits" not in conf:
|
||||
return fail("the cover config lost the 8/9-bit sign-off knob")
|
||||
cover = COVER_SRC.read_text(encoding="utf-8")
|
||||
if "cover_wake" not in cover or 'strcmp(command, "WAKE")' not in cover:
|
||||
return fail("cover daemon lost the WAKE command")
|
||||
|
||||
Reference in new issue
Block a user