Start keymon on TrimUI A133P so Fn key mappings work#1548
Open
Felixmil wants to merge 1 commit into
Open
Conversation
- trimui_a133p.sh: - add keymon to the blob list started in device_init_a133p
This was referenced Jun 5, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
On the TrimUI Brick, the "Fn Key and Switch Settings" app lets you map actions to the left/right Fn keys, but pressing them did nothing. This restores Fn key support by starting the stock
keymondaemon, which is the component that reads the editor's mappings and runs the chosen action on a key press.Root cause
The Fn keys are dispatched by the stock
keymondaemon (/usr/trimui/bin/keymon), which loads/usr/trimui/fnkeys/f1key.jsonandf2key.jsonand runs the mapped action script on key press. On stock firmwarekeymonis launched byruntrimui-original.sh. spruce replaces that boot path and starts the other TrimUI blobs indevice_init_a133p(trimui_inputd,trimui_scened,trimui_btmanager,hardwareservice,musicserver) plustrimui_osdd, but it never startedkeymon. As a result the editor saved mappings that nothing was running to act on.The physical switch was unaffected: it is handled by the separate
trimui_sceneddaemon (already running) viascene.sh, so it kept working.Change
keymonis added to the blob list started indevice_init_a133p(spruce/scripts/platform/device_functions/trimui_a133p.sh).run_trimui_blobsalready changes into/usr/trimui/bin, skips a blob that is absent or already running, and launches it with the correctLD_LIBRARY_PATH, which is exactly howkeymonneeds to run, so no other plumbing is required.keymonis also a known part of spruce input handling on other devices (the A30 path documents "ensuring keymon is running", and MiyooMini starts it), so this brings the A133P devices in line. Becauserun_trimui_blobsis a no-op when the binary is absent, the addition is safe for the other devices that sharedevice_init_a133p.Validation
Tested on a physical Brick (FW 1.1.1) over SSH, from a clean reboot.
keymonautostarts from the patched script (confirmed in the process list after boot), and volume keys, the power button, and the other daemons continue to behave normally with it running (no double-handling or crash observed).Every action the editor offers was exercised on hardware. All work except the CPU clock switcher:
The CPU clock switcher cannot work under spruce by design. Its script (
com.trimui.switch.cpufreq.sh) writes directly to/sys/devices/system/cpu/cpufreq/policy0/scaling_min_freqandscaling_max_freq, but spruce manages CPU scaling through its own performance profiles and those nodes are not writable here, so the writes fail with "Permission denied" and the clock does not change. This is not a regression from this PR (the action was already non-functional); it is left in place and can be removed from the menu in a follow-up.Related issues
Fixes #1440
Fixes #1319 (Brick LED switch not restoring lights). Confirmed on hardware: with
keymonrunning, both the Fn key LED toggle and the switch LED off action turn the LEDs off and back on (/sys/class/led_anim/enabletracks the switch state).