I'm trying to make screen rotation button functional on thinkpad x230t. Need to do
Code:
setkeycodes 0x67 132 0x6c 120
at system startup. Reading around the internets it seems to be very simple, but for some reason I cant make it work.
So far have tried
/etc/init/setmycodes.conf
Code:
description "remapping screen rotation buttons on thinkpad x230t"
start on startup
exec /bin/setkeycodes 0x67 132 0x6c 120
have tried
/etc/rc.local
Code:
#!/bin/sh
#
# /etc/rc.local: Local multi-user startup script.
# remapping screen rotation buttons on thinkpad x230t
#
touch /var/lock/subsys/local
setkeycodes 0x67 132 0x6c 120
exit 0
and oldschool way of placing my script in /etc/init.d/setmycodes.sh, symlinking it to /etc/rc5.d/S91setmycodes.sh
Unfortunately nothing works. At the end of a day the button has no keycode and I am reading /var/log/messages to find
Code:
Oct 26 00:36:29 localhost kernel: [52975.153112] atkbd serio0: Unknown key released (translated set 2, code 0x6c on isa0060/serio0).
Oct 26 00:36:29 localhost kernel: [52975.153119] atkbd serio0: Use 'setkeycodes 6c <keycode>' to make it known.
The worst thing is that
Code:
sudo setkeycodes 0x67 132 0x6c 120
works perfectly. What am I missing?