Flipper Zero Firmware
Loading...
Searching...
No Matches
input.h File Reference

Input: main API. More...

#include <furi_hal_resources.h>

Go to the source code of this file.

Data Structures

struct  InputEvent
 Input Event, dispatches with FuriPubSub. More...
 

Macros

#define RECORD_INPUT_EVENTS   "input_events"
 
#define INPUT_SEQUENCE_SOURCE_HARDWARE   (0u)
 
#define INPUT_SEQUENCE_SOURCE_SOFTWARE   (1u)
 

Enumerations

enum  InputType {
  InputTypePress , InputTypeRelease , InputTypeShort , InputTypeLong ,
  InputTypeRepeat , InputTypeMAX
}
 Input Types Some of them are physical events and some logical. More...
 

Functions

const char * input_get_key_name (InputKey key)
 Get human readable input key name.
 
const char * input_get_type_name (InputType type)
 Get human readable input type name.
 

Detailed Description

Input: main API.

Enumeration Type Documentation

◆ InputType

enum InputType

Input Types Some of them are physical events and some logical.

Enumerator
InputTypePress 

Press event, emitted after debounce.

InputTypeRelease 

Release event, emitted after debounce.

InputTypeShort 

Short event, emitted after InputTypeRelease done within INPUT_LONG_PRESS interval.

InputTypeLong 

Long event, emitted after INPUT_LONG_PRESS_COUNTS interval, asynchronous to InputTypeRelease

InputTypeRepeat 

Repeat event, emitted with INPUT_LONG_PRESS_COUNTS period after InputTypeLong event.

InputTypeMAX 

Special value for exceptional.

Function Documentation

◆ input_get_key_name()

const char * input_get_key_name ( InputKey key)

Get human readable input key name.

Parameters
key- InputKey
Returns
string

◆ input_get_type_name()

const char * input_get_type_name ( InputType type)

Get human readable input type name.

Parameters
type- InputType
Returns
string