Skip to content

PowerButtonState (UORB message)

power button state notification message.

TOPICS: power_button_state

Fields

NameTypeUnit [Frame]Range/EnumDescription
timestampuint64time since system start (microseconds)
eventuint8one of PWRBUTTON_STATE*

Constants

NameTypeValueDescription
PWR_BUTTON_STATE_IDELuint80Button went up without meeting shutdown button down time (delete event)
PWR_BUTTON_STATE_DOWNuint81Button went Down
PWR_BUTTON_STATE_UPuint82Button went Up
PWR_BUTTON_STATE_REQUEST_SHUTDOWNuint83Button went Up after meeting shutdown button down time

Source Message

Source file (GitHub)

Click here to see original file
c
# power button state notification message

uint64 timestamp			    # time since system start (microseconds)

uint8 PWR_BUTTON_STATE_IDEL = 0             # Button went up without meeting shutdown button down time (delete event)
uint8 PWR_BUTTON_STATE_DOWN = 1             # Button went Down
uint8 PWR_BUTTON_STATE_UP = 2               # Button went Up
uint8 PWR_BUTTON_STATE_REQUEST_SHUTDOWN = 3 # Button went Up after meeting shutdown button down time

uint8 event                                 # one of PWR_BUTTON_STATE_*