On Mon 22 Jan 2024 at 07:40:00 (+0100), Geert Stappers wrote:
> On Sun, Jan 21, 2024 at 04:34:23PM -0600, David Wright wrote:
> > On Sun 21 Jan 2024 at 22:41:01 (+0100), Geert Stappers wrote:
> > > Pressing "Function key with symbol of computer sending signal" has no
> > > effect. Which could be caused by the horrible state of keyboard.
> > > When keyboard is needed, is an USB-attached keyboard needed. Usual use
> > > case of the laptop is "headless server, server with SSH access".
> > 
> > I'm not sure what you mean by horrible state.
> 
> That the laptop has a worndown (usage damaged) keyboard. [1]
> 
> > > So I'm ask if 
> > >   export KEYCODE=42
> > >   echo $KEYCODE > /devices/platform/thinkpad_acpi/input/input16
> > > could cause "wlan radio enable"? Or should KEYCODE be another magic 
> > > number?
> > 
> > FWIW my wifi hardware button's keycode is 246.
> 
> How was that keycode found?

By running xev and pressing the button, which is on the front edge
of the laptop. Having the button there is really inconvenient, as
it's easy for a belt buckle or such to accidentally press it.
In theory, that should be easily noticed, as the button is translucent
and illuminated when wifi is connected (and flashes when attempting
to connect). However, the light is not consistent in behaviour.

But another suggestion comes from a more modern laptop, which has
an aeroplane Fn-key (action/hot key), and that uses 255.

So that's 246 / XF86WLAN   on an old laptop with a physical button,
and       255 / XF86RFKill on a newer laptop with a Fn-key.

[ … ]

> Back to "send key code".

One can but try. Did you check the BIOS, BTW?

$ xmodmap -pk or -pke will print what keycodes are available,
but I don't claim to know how all this stuff works (if it does).

Cheers,
David.

Reply via email to