--- wikisrc/ports/evbarm/allwinner.mdwn 2018/05/06 11:29:50 1.87 +++ wikisrc/ports/evbarm/allwinner.mdwn 2018/05/23 21:14:50 1.91 @@ -56,7 +56,8 @@ Please refer to the [SUNXI kernel config - Audio codecYesSupported on sun4i, sun5i, sun6i, sun7i, sun8i-h2+, sun8i-h3, sun50i-h5 + Audio codecYesSupported on sun4i, sun5i, sun6i, sun7i, sun8i-h2+, sun8i-h3, sun50i-h5, sun50i-a64 + CAN controllerYes Crypto engine- CSI- DMAYes @@ -67,7 +68,7 @@ Please refer to the [SUNXI kernel config GPIOYes GPU- I2CYes - I2S/PCM- + I2S/PCMExperimental IR transceiver- NANDYes P2WI/RSBYes @@ -78,7 +79,7 @@ Please refer to the [SUNXI kernel config SD/MMCYes SMPYes32-bit only. Uses PSCI support in firmware SPDIF- - SPI- + SPIYes Thermal sensorsYes Touch screenYes UARTYes @@ -104,3 +105,29 @@ On some television models, the borders o setenv video-mode sunxi:1280x720-24,overscan_x=32,overscan_y=20 saveenv reset + +## Pinebook function keys + +The sleep (Fn+Esc), home (Fn+F1), volume down (Fn+F3), volume up (Fn+F4), and mute (Fn+F5) keys on the keyboard are mapped to uhid(4) devices. + +Create the following config file: + +[[!template id=filecontent name="/etc/usbhidaction.conf" text=""" +Consumer:Consumer_Control.Consumer:Volume_Up 1 + mixerctl -n -w outputs.master++ +Consumer:Consumer_Control.Consumer:Volume_Down 1 + mixerctl -n -w outputs.master-- +Consumer:Consumer_Control.Consumer:Mute 1 + mixerctl -n -w outputs.mute++ +Consumer:Consumer_Control.Consumer:AC_Home 1 + /etc/powerd/scripts/hotkey_button AC_Home pressed +Generic_Desktop:System_Control.Generic_Desktop:System_Sleep 1 + /etc/powerd/scripts/sleep_button System_Sleep pressed +"""]] + +Then start two copies of usbhidaction: + +[[!template id=programlisting text=""" +# /usr/bin/usbhidaction -c /etc/usbhidaction.conf -f /dev/uhid0 -i -p /var/run/usbhidaction-uhid0.pid +# /usr/bin/usbhidaction -c /etc/usbhidaction.conf -f /dev/uhid1 -i -p /var/run/usbhidaction-uhid1.pid +"""]]