I’m trying to create an embedded gadget by building and installing Android OS (Android 6.0.1) on the DragonBoard 410C.
When power is supplied to the DragonBoard 410C, Android starts and a screen with icons etc. is displayed. As everyone knows well, after the Android OS has started normally, pressing the power button once will turn off the screen display (sleep), and pressing the power button again will display the screen again ( wake-up).
I want Android to do certain things to the device when it goes to sleep and wake-up from that state. In other words, I want the callback function A to be executed when the Android OS goes to sleep and the callback function B to be executed when wake-up.
Where and how should I modify the Android source code? If anyone knows, please teach me. goes to sleep and the callback function B to be executed when wake up.
Thank you for your assistance, in advance.