01-24-2021, 12:09 PM
Oh you're not the first to have that dream!
Issues Installing NetBSD on a PineBook Pro
|
01-24-2021, 12:09 PM
Oh you're not the first to have that dream!
I had some spare time today (!) and made a simple script that you might find interesting.
Code: $ cat ~/s/ModBright It requires 'sudo' unfortunately. But if you pass a value, it will dim or brighten the backlight. Passing "10" will increase the parameter by 10, passing "-15" will decrease the parameter by 15. I used xbindkeys and bound this script to the Alt comma and Alt period keys: Code: $ cat ~/.xbindkeysrc You might prefer to use Mod4 + F1 and Mod4 + F2 (which is Pine + F1 and Pine + F2). As you can see, I did not because I have those in use already. We cannot use Fn + F1 and Fn + F2 because the keyboard firmware returns both keys as the same single key. I run this as a script at KDE startup, but you could put it in .xinitrc: Code: sysctl -n hw.pwmbacklight0.level > ~/.backlightlevel Surely there is a better way to do this, but until we get support for whatever the keyboard firmware does, it works. I'm not any kind of Unix guru, and I barely know how to make shell scripts work.
01-27-2021, 03:08 PM
01-31-2021, 10:39 AM
(This post was last modified: 01-31-2021, 10:41 AM by ReleaseTheGeese.)
@KC9UDX , thanks for sharing that script. It reminds me somewhat of a similar hack I've done with Fluxbox to control MPD and take screenshots using ImageMagick. Though this uses 'aplay' on Linux, it could easily be tweaked to use mixerctl on NetBSD.
With regards to your script requiring sudo, it ought to be possible to edit /etc/sudoers by running 'visudo' on NetBSD and allow NOPASSWD for 'sysctl'. I typically also allow my login to run poweroff/reboot with NOPASSWD too. I haven't yet tried NOPASSWD on BSD but I'd make a high bet it works the same way.
01-31-2021, 11:20 AM
I have never tried such a thing, but it seems like that would require the sudo package as well, if it works.
|
Possibly Related Threads… | |||||
Thread | Author | Replies | Views | Last Post | |
2nd NetBSD boot goes dark | donn | 6 | 4,114 |
02-22-2024, 03:59 AM Last Post: KC9UDX |
|
NetBSD 1.0 runs down battery | donn | 13 | 3,842 |
11-15-2023, 04:05 PM Last Post: KC9UDX |
|
Booting NetBSD | untitled | 12 | 8,717 |
08-30-2022, 01:23 AM Last Post: untitled |
|
NetBSD on the Pinebook Pro in August 2022 - or not? | KC9UDX | 6 | 5,274 |
08-24-2022, 01:49 AM Last Post: KC9UDX |
|
NetBSD and pinebook keyboard/trackpad firmware updater | mrgtwentythree | 5 | 11,624 |
05-16-2021, 07:37 PM Last Post: mrgtwentythree |
|
NetBSD | Der Geist der Maschine | 76 | 125,884 |
05-16-2021, 02:43 PM Last Post: mrgtwentythree |
|
OpenBSD 6.7 on Pinebook Pro | SKG | 27 | 55,672 |
05-07-2021, 04:03 PM Last Post: bigtreeman |
|
NetBSD and USB "sound cards" | KC9UDX | 2 | 6,494 |
05-07-2021, 12:11 PM Last Post: elimark1 |
|
OpenBSD on the pinebook pro | e-minguez | 5 | 12,498 |
04-27-2021, 04:06 AM Last Post: dreamer_ |
|
PINEBOOK Pro USB-C Docking Deck on FreeBSD | S199pWa1k9r | 2 | 5,237 |
03-04-2021, 01:53 PM Last Post: Arwen |