Comment on Got myself some energy monitoring Zigbee plugs and made an interesting discovery
fmstrat@lemmy.nowsci.com 4 months agoThere are a couple of ways:
- Formally add a system entry to run at suspend/resume (like how nvidia does in their driver package)
Or
- Write a script that rmmods, suspends, sleeps, modprobes, and map it to Cntrl-Alt-Shift-S
I usually do 2 because I like the hotkey method for desktops, and it keeps things the same for both. Also allows me to close a lid on a laptop and leave it on. But 1 is more “formal”.
Happy to share some scripts if you’d like, on my phone now, though.
umbrella@lemmy.ml 4 months ago
fmstrat@lemmy.nowsci.com 4 months ago
Will grab some when I back, but assuming you are using
systemd
, it’s easy if you follow this old but good method: blog.christophersmart.com/…/running-scripts-befor…If that doesn’t work out of the box, it’s likely because you’re hitting S1 instead of S3, but give that test script a shot and let me know how it goes!
umbrella@lemmy.ml 4 months ago
fmstrat@lemmy.nowsci.com 4 months ago
Could be internal to kernel? Try updating
/etc/default/grub
to include:GRUB_CMDLINE_LINUX_DEFAULT=“quiet splash atkbd.reset”
and runsudo update-grub
. This will cause a full keyboard reset on resume.If you have not run BIOS updates, that could be it, too.