GloDroid / glodroid_manifest

Android port that aims to bring both user- and developer-friendly experience in using AOSP with a set of single-board computers (SBC), phones and other devices.
471 stars 67 forks source link

Shutdown Raspberry Pi #118

Closed squidink7 closed 3 years ago

squidink7 commented 3 years ago

How do you shutdown the raspberry pi? there is no power button and unplugging the cord doesn't seem to be good for it.

rsglobal commented 3 years ago

You will need to adjust dts / overlay and map some of GPIO as a key: https://www.kernel.org/doc/Documentation/devicetree/bindings/input/gpio-keys.txt

Event number should be: https://github.com/torvalds/linux/blob/48342fc07272eec454fc5b400ed3ce3739c7e950/include/uapi/linux/input-event-codes.h#L191