libnifalcon
1.0.1
|
#include <FalconGrip.h>
Public Types | |
enum | { FALCON_GRIP_INDEX_OUT_OF_RANGE = 4000 } |
Public Member Functions | |
FalconGrip (int32_t digital_inputs, int32_t analog_inputs) | |
virtual | ~FalconGrip () |
virtual bool | runGripLoop (int size, const uint8_t *data)=0 |
unsigned int | getNumDigitalInputs () const |
unsigned int | getNumAnalogInputs () const |
bool | getDigitalInput (unsigned int index) |
unsigned int | getDigitalInputs () const |
int | getAnalogInput (unsigned int index) |
![]() | |
FalconCore () | |
virtual | ~FalconCore () |
int | getErrorCode () |
Protected Attributes | |
unsigned int | m_numDigitalInputs |
unsigned int | m_numAnalogInputs |
unsigned int | m_digitalInputs |
int | m_analogInputs [128] |
![]() | |
int | m_errorCode |
Grip classes define how we deal with whatever grip might appear on the falcon. The base class tries to be as generic as possible, allowing for up to 32 digital inputs and 128 analog inputs.
anonymous enum |
|
inline |
Constructor. Defines the grip capabilities.
digital_inputs | Number of digital inputs on the grip |
analog_inputs | Number of analog inputs on the grip |
|
inlinevirtual |
Destructor
|
inline |
Returns the value of the requested analog input
index | Index of the analog input to return |
|
inline |
Returns the value of the requested digital input
index | Index of the digital input to return |
|
inline |
Returns the bitfield used to store all digital inputs
|
inline |
Returns the number of analog inputs available on the current grip
|
inline |
Returns the number of digital inputs available on the current grip
|
pure virtual |
Parses input/output for grip related data (button states, etc...)
size | Amount of data in the buffer being passed in |
data | Buffer of button data |
Implemented in libnifalcon::FalconGripFourButton.
|
protected |
Array of analog input values
|
protected |
Bitfield to hold digital input values
|
protected |
Number of analog inputs available on the grip
|
protected |
Number of digital inputs available on the grip