mkdir -p ~/.config/sway
cp /etc/sway/config ~/.config/sway/config
nano .config/sway/config
and
set $mod Mod1
mkdir -p ~/.config/sway
cp /etc/sway/config ~/.config/sway/config
nano .config/sway/config
and
set $mod Mod1
and what physical key is it? what do you press to switch workplace?
fn + alt + 1 ?
mod1 - Alt (left and right)
alt+1 switch 1 workspace
alt + 2 ….
Would this work with Rex’s Trixie 6.12.y?
My uConsole hasn’t arrived yet, so I haven’t been able to test it, but wondering if anyone else has tried it.
I’m going to be setting up my main daily card to trixie tomorrow. I’ll post here if I had to make any changes. Might just turn it into a package for bookworm and trixie for easy install.
Works great on my CM3 running on top of Rex’s Trixie image! Power consumption went from 3.2W idle to just over 2W. A 50% increase in idle time is nothing to be laughed at, even though it doesn’t really compare to the sleep mode on a laptop which to my understanding is impossible to implement on the RPi platform.
Thank you! Just tested on Rex’s Trixie. Works as expected.
Question: can I change config so it will ask password on wake up? Like it does when I hold the power key and choose Lock Screen
you can add swaylock -p to the script that gets activated to “sleep” the device.
just tested it on the Rex’s Trixie + Gnome. On button hold it shows only Power Off option. On short press it works as expected + asks for the password without additional edits
Tested it now on CM4 with Rex’s Trixie image. The screen turns off and the keyboard locks. However the max CPU frequency is not adjusted. The value in cat /sys/devices/system/cpu/cpufreq/policy0/scaling_max_freq stays in my case at 2000000. HTOP also shows 2000Mhz.
checked it with SSH connection to the device while putting it to sleep, is this maybe preventing the adjustment of that value?
Update:
Seems like something is wrong with the keyboard detection part of the script. Chatgpt solved it for me with this change:
From:
def find_internal_kb(ids=[“feed:0000”, “1eaf:0003”]):
To:
def find_internal_kb(ids=[“1eaf:0024”,“1eaf:0003”,“feed:0000”]):
After some invetigation I found this errors:
clockworkpi sleep_power_control[816]: File "sleep_power_control.py", line 62, in <module> clockworkpi sleep_power_control[816]: Exception: there's no matched kb
The above mentioned fix is available in this fork:
And the deb file can be downloaded here:
Which compute module have you tried this with?
Still a great app using this on Rex Trixie cm5 working great
New user here trying CM5 with Trixie:
I had the same issue mentioned by @ati as my keyboard with USB ID 1eaf:0024 was causing an error with v1.3.0. Then i noticed the new id is already present in the main branch but no release was generated since then, so compiling from source solves the issue for me and i didn’t need the fork mentioned here: uConsole-Sleep v1.3 - #51 by ati
So as soon as @paragonnov builds a new release, this issue should be resolved also for .deb installs.
Seems ENV_VERSION needs to be passwd to the build script. Otherwise dpkg-deb returns an error complaining about empty ‘Version’ field value.
Further, it occurred two times already that after wake up the keyboard stopped working. In dmesg:
[ 3211.014306] panel-cwu50 fe700000.dsi.0: regulator iovcc and vci defined, enabling
[ 3211.023665] panel-cwu50 fe700000.dsi.0: old panel, cycling the reset pin
[ 3215.586132] usb 1-1.1: Failed to suspend device, error -71
[ 3215.592154] usb 1-1.1: Failed to suspend device, error -71
[ 3217.191764] panel-cwu50 fe700000.dsi.0: asserting reset pin for old panel
[ 3457.710539] input: python-uinput as /devices/virtual/input/input96
[ 3457.712542] input: python-uinput as /devices/virtual/input/input97
[ 3463.282267] usb 1-1.1: reset full-speed USB device number 4 using dwc2
[ 3463.358267] usb 1-1.1: device descriptor read/64, error -71
[ 3463.538261] usb 1-1.1: device descriptor read/64, error -71
Only the following input devices are shown:
root@clockworkpi:~# evtest
No device specified, trying to scan all of /dev/input/event*
Available devices:
/dev/input/event0: axp20x-pek
/dev/input/event1: vc4-hdmi-0
/dev/input/event2: vc4-hdmi-0 HDMI Jack
/dev/input/event3: vc4-hdmi-1
/dev/input/event4: vc4-hdmi-1 HDMI Jack
/dev/input/event5: python-uinput
/dev/input/event6: python-uinput
Trixie, Xorg + xfce4, kernel 6.12.67. Without remote access this means you’d need to hard-reboot the uConsole to recover.
Wonder if anyone else experienced a similar behaviour.
try qmk firmware? they wrote they fixed usb power issue in latest updates
- Power Surge Fix: I’ve implemented a workaround for the known “USB Power Surge” issue. If the keyboard gets stuck in DFU mode due to a power spike, it now auto-reverifies and stays functional.
Thank you, I am already using QMK. Also I believe the linked workaround only concerns the DFU mode.
@paragonnov I’ve forked your repo and made a PR with a few changes, mainly towards cleaning up the structure of the project - specifically I don’t believe there are any real benefits of converting the python files into binary form so instead they now live as separate files in both repo and the system. This also fixed the problem of logging (journalctl -u sleep-remap-powerkey -f is now showing the events as the user presses the button).
Branch: GitHub - jose1711/uConsole-sleep at nobinary · GitHub
PR: Replace binaries with Python source scripts by jose1711 · Pull Request #4 · qkdxorjs1002/uConsole-sleep · GitHub
Thx works perfectly with cm5 ![]()
Nice, I missed a standby function badly.