Release a1111 (lennon): isolate nokia-argon slider from 2720 Flip cover stack
- Write /usr/share/bananarchy/lid-profile per target in apply-bananarchy-overlay.sh (slider on nokia-argon, flip on nokia-beatles, none elsewhere), disable flip runlevel services, cover udev/config, and mux module loads on non-flip builds, and exit 0 immediately in flip daemons/init scripts when lid-profile != flip - Guard startup Escape grab cleanup when locked and gate lid-state checks in display-power-sync, locker.so, and callscreen.so on lid-profile == flip so nokia-argon keeps pure a1108 sliding-lid behaviour - Ship active-high shared cover backlight (kernel_backlight_invert = 0), active-black internal panel isolation (kernel_internal_sleep = 0), pixel-centered 240x240 cover UI, SW_LID hall sync, and shared Screen blank timeout on nokia-beatles - Pin verified a1111 (lennon) image hashes for both nokia-argon and nokia-beatles and synchronize docs and host tests
This commit is contained in:
1 parent
7a2b965ce3
commit
83c8db10f1
38 files changed
+1351
-276
No files matched your search
@@ -3,9 +3,9 @@
|
||||
|
||||
The daemon runs in simulation mode against a fake /dev/fb0, fake DPMS/backlight
|
||||
and the panel-mipi-dbi-spi debugfs command hook. It verifies the stock vendor
|
||||
init, active-low cover backlight, shared-backlight marker, 240x240 frame,
|
||||
periodic repaint against Xorg, blanking, handover on open and the initial
|
||||
DPMS-off gate.
|
||||
init, active-high shared backlight, active-black internal GRAM isolation,
|
||||
shared-backlight marker, 240x240 frame, periodic repaint against Xorg,
|
||||
blanking, handover on open and the initial DPMS-off gate.
|
||||
"""
|
||||
import os
|
||||
import pathlib
|
||||
@@ -45,7 +45,7 @@ class Daemon:
|
||||
"BANANARCHY_COVER_KERNEL_BL": str(bl),
|
||||
"BANANARCHY_COVER_KERNEL_BL_POWER": str(bl_power),
|
||||
"BANANARCHY_COVER_KERNEL_MARKER": str(marker),
|
||||
"BANANARCHY_COVER_KERNEL_BL_INVERT": "1",
|
||||
"BANANARCHY_COVER_KERNEL_BL_INVERT": "0",
|
||||
})
|
||||
(root / "dpms").write_text("Off\n")
|
||||
self.proc = subprocess.Popen([str(exe), "--config", str(config)],
|
||||
@@ -111,7 +111,8 @@ def main():
|
||||
"kernel_backlight_power_path = /sys/class/backlight/backlight/bl_power",
|
||||
"kernel_backlight_marker = /run/bananarchy/cover-backlight",
|
||||
"kernel_backlight_level = 14",
|
||||
"kernel_backlight_invert = 1"):
|
||||
"kernel_backlight_invert = 0",
|
||||
"kernel_internal_sleep = 0"):
|
||||
if token not in conf:
|
||||
return fail("shipping config lost %s" % token)
|
||||
helper = HELPER.read_text(encoding="utf-8")
|
||||
@@ -161,7 +162,8 @@ def main():
|
||||
"panel_firmware = %s\nkernel_dpms_helper = /bin/true\n"
|
||||
"kernel_backlight_path = %s\nkernel_backlight_power_path = %s\n"
|
||||
"kernel_backlight_marker = %s\nkernel_backlight_level = 14\n"
|
||||
"kernel_backlight_invert = 1\nmux_closed_level = 1\n"
|
||||
"kernel_backlight_invert = 0\nkernel_internal_sleep = 0\n"
|
||||
"mux_closed_level = 1\n"
|
||||
"mux_open_level = 0\nreset_assert_level = 0\nreset_idle_level = 1\n" %
|
||||
(root / "cover.sock", root / "no-fb1", root / "legacy-backlight",
|
||||
fb, FIRMWARE, bl, bl_power, marker))
|
||||
@@ -181,28 +183,41 @@ def main():
|
||||
print("[ok] open flip: internal mux and backlight restored, no cover frame")
|
||||
|
||||
daemon.send("LID CLOSED")
|
||||
if not daemon.wait("kernel marker 0") or not daemon.wait("dpms reinit"):
|
||||
return fail("closing the flip did not blank the cover")
|
||||
if not any(e == "gpio 1 1" for e in daemon.events()):
|
||||
return fail("the mux was not switched to the external panel")
|
||||
if marker.read_text().strip() != "0" or bl.read_text().strip() != "14" \
|
||||
or bl_power.read_text().strip() != "0":
|
||||
return fail("the active-low cover backlight was not held off")
|
||||
print("[ok] closed flip: mux to cover, external backlight held off")
|
||||
if not daemon.wait("kernel marker absent") or not daemon.wait("dpms off"):
|
||||
return fail("closing the flip did not power down the displays")
|
||||
if any(e == "gpio 1 1" for e in daemon.events()):
|
||||
return fail("closing the flip selected the cover without a button press")
|
||||
if marker.exists() or bl.read_text().strip() != "0" \
|
||||
or bl_power.read_text().strip() != "4":
|
||||
return fail("closing the flip did not hold both backlights dark")
|
||||
print("[ok] closed flip: mux parked low, both panels dark")
|
||||
|
||||
tail = len(daemon.events())
|
||||
daemon.send("BUTTON")
|
||||
expected = ("kernel marker 1", "dpms reinit", "kernel reset",
|
||||
"kernel cmd fe", "kernel cmd 29",
|
||||
"kernel backlight 0 power=0", "kernel frame lit=1")
|
||||
expected = ("kernel marker 0", "dpms on", "kernel clear fb",
|
||||
"gpio 1 1", "kernel reset", "kernel cmd fe",
|
||||
"kernel cmd 29", "kernel frame lit=1",
|
||||
"kernel marker 1", "kernel backlight 14 power=0")
|
||||
for text in expected:
|
||||
if not daemon.wait(text):
|
||||
return fail("BUTTON did not produce %s" % text)
|
||||
if marker.read_text().strip() != "1" or bl.read_text().strip() != "0" \
|
||||
wake_events = daemon.events()[tail:]
|
||||
if "dpms reinit" in wake_events:
|
||||
return fail("BUTTON ran dpms reinit and reset internal gpio25")
|
||||
clear_idx = next(i for i, e in enumerate(wake_events)
|
||||
if e == "kernel clear fb")
|
||||
mux_idx = next(i for i, e in enumerate(wake_events) if e == "gpio 1 1")
|
||||
if clear_idx > mux_idx:
|
||||
return fail("internal fb clear did not precede cover mux switch")
|
||||
if any(e == "kernel cmd 28" for e in wake_events[:mux_idx]):
|
||||
return fail("BUTTON put the normally-white internal panel to sleep before cover mux switch")
|
||||
if not marker.exists() or marker.read_text().strip() != "1" \
|
||||
or bl.read_text().strip() != "14" \
|
||||
or bl_power.read_text().strip() != "0":
|
||||
return fail("the active-low cover backlight was not enabled")
|
||||
return fail("the active-high cover backlight was not enabled")
|
||||
if "kernel" not in daemon.send("STATUS"):
|
||||
return fail("STATUS does not report the kernel backend")
|
||||
print("[ok] BUTTON: vendor init, active-low cover backlight and UI")
|
||||
print("[ok] BUTTON: internal panel active-black, vendor init and cover UI")
|
||||
|
||||
frames = daemon.count("kernel frame lit=1")
|
||||
time.sleep(1.2)
|
||||
@@ -210,15 +225,20 @@ def main():
|
||||
return fail("the kernel cover UI is not repainted against Xorg")
|
||||
print("[ok] kernel UI is repainted every second")
|
||||
|
||||
tail = len(daemon.events())
|
||||
daemon.send("BLANK")
|
||||
time.sleep(0.1)
|
||||
if not daemon.wait("kernel cmd 28") or not daemon.wait("dpms reinit") or \
|
||||
not daemon.wait("kernel marker 0") or \
|
||||
not daemon.wait("kernel backlight 14 power=0"):
|
||||
return fail("blanking did not power the cover down")
|
||||
if marker.read_text().strip() != "0" or bl.read_text().strip() != "14":
|
||||
return fail("the cover backlight was not returned to the OFF duty: marker=%r bl=%r blp=%r events=%r" % (marker.read_text() if marker.exists() else None, bl.read_text(), bl_power.read_text(), daemon.events()[-12:]))
|
||||
print("[ok] BLANK: display-off, external backlight OFF duty")
|
||||
time.sleep(0.15)
|
||||
blank_events = daemon.events()[tail:]
|
||||
for text in ("kernel cmd 28", "kernel cmd 10", "gpio 0 1",
|
||||
"kernel marker absent", "kernel backlight 0 power=4",
|
||||
"dpms off"):
|
||||
if not any(text in e for e in blank_events):
|
||||
return fail("blanking did not produce %s: %r" % (text, blank_events))
|
||||
if marker.exists() or bl.read_text().strip() != "0" \
|
||||
or bl_power.read_text().strip() != "4":
|
||||
return fail("blanking did not power down the backlight: marker=%r bl=%r blp=%r" %
|
||||
(marker.exists(), bl.read_text(), bl_power.read_text()))
|
||||
print("[ok] BLANK: display-off, mux parked low and backlight powered down")
|
||||
|
||||
daemon.send("LID OPEN")
|
||||
if not daemon.wait("release") or not daemon.wait("kernel restore internal"):
|
||||
|
||||
Reference in new issue
Block a user