Re: T520 Linux Mint / button ThinkVantage

Marius Gedminas <[email protected]> Fri, 19 Aug 2022 12:21:33 +0300
Newsgroups gmane.linux.hardware.thinkpad
Message-ID <20220819092133.vewgzvhyiy3w5a3j@blynas>
--===============0265073006904194727==
Content-Type: multipart/signed; micalg=pgp-sha1;
	protocol="application/pgp-signature"; boundary="balqcj7qdirj3gyc"
Content-Disposition: inline


--balqcj7qdirj3gyc
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Thu, Aug 18, 2022 at 05:26:25PM +0700, =D0=98=D0=B2=D0=B0=D0=BD =D0=9D=
=D0=B8=D0=B0=D0=B3=D0=B0=D1=80=D0=B0 wrote:
> Many years I have used the T520 with linux.
> I have an idea to hang some job on the blue button "ThinkVantage" on the =
top of
> the notebook keyboard.
>=20
> I suppose, this button has a different interrupt=C2=A0code, not as anothe=
r button on
> the keyboard.

I'm not sure how it's all wired at the hardware level, but the Linux
userspace sees a regular key event.

I've always mapped it to lock screen.

> The jobs may be:
> - turn power off
> - erase some files or memory
> - etc.
>=20
> Is it possible?

Sure.  How, specifically, depends on your desktop environment.  I use
GNOME so I'd do it from gnome-control-center -> Keyboard shortcuts.
If you want a custom action ("erase some files", I'm not sure how you'd
erase "memory"), you can create a custom shortcut that runs a shell
script that can do whatever you want.

Regards,
Marius Gedminas
--=20
Why do geeks think Halloween and Christmas occur on the same day?
Because 31oct =3D 25dec!

--balqcj7qdirj3gyc
Content-Type: application/pgp-signature; name="signature.asc"

-----BEGIN PGP SIGNATURE-----

iF0EABECAB0WIQSBIa0y8AqAlHSKbNCRV0Rd56bXjwUCYv9WFQAKCRCRV0Rd56bX
j4j9AJ9Nc5dDtIj+7MMrQJOYvYLn8PymwwCbB+m/GERZo+LrNyFZmxcp9UgbSEg=
=bEkI
-----END PGP SIGNATURE-----

--balqcj7qdirj3gyc--

--===============0265073006904194727==
Content-Type: text/plain; charset="utf-8"
MIME-Version: 1.0
Content-Transfer-Encoding: base64
Content-Disposition: inline

LS0gClRoZSBsaW51eC10aGlua3BhZCBtYWlsaW5nIGxpc3QgaG9tZSBwYWdlIGlzIGF0OgpodHRw
Oi8vbWFpbG1hbi5saW51eC10aGlua3BhZC5vcmcvbWFpbG1hbi9saXN0aW5mby9saW51eC10aGlu
a3BhZA==

--===============0265073006904194727==--