WPILibC++
2018.4.1-1232-gce8c71b
|
Typedefs | |
typedef void(* | HAL_InterruptHandlerFunction )(uint32_t interruptAssertedMask, void *param) |
Functions | |
HAL_InterruptHandle | HAL_InitializeInterrupts (HAL_Bool watcher, int32_t *status) |
Initializes an interrupt. More... | |
void * | HAL_CleanInterrupts (HAL_InterruptHandle interruptHandle, int32_t *status) |
Frees an interrupt. More... | |
int64_t | HAL_WaitForInterrupt (HAL_InterruptHandle interruptHandle, double timeout, HAL_Bool ignorePrevious, int32_t *status) |
In synchronous mode, waits for the defined interrupt to occur. More... | |
void | HAL_EnableInterrupts (HAL_InterruptHandle interruptHandle, int32_t *status) |
Enables interrupts to occur on this input. More... | |
void | HAL_DisableInterrupts (HAL_InterruptHandle interruptHandle, int32_t *status) |
Disables interrupts without without deallocating structures. More... | |
double | HAL_ReadInterruptRisingTimestamp (HAL_InterruptHandle interruptHandle, int32_t *status) |
Returns the timestamp for the rising interrupt that occurred most recently. More... | |
double | HAL_ReadInterruptFallingTimestamp (HAL_InterruptHandle interruptHandle, int32_t *status) |
Returns the timestamp for the falling interrupt that occurred most recently. More... | |
void | HAL_RequestInterrupts (HAL_InterruptHandle interruptHandle, HAL_Handle digitalSourceHandle, HAL_AnalogTriggerType analogTriggerType, int32_t *status) |
Requests interrupts on a specific digital source. More... | |
void | HAL_AttachInterruptHandler (HAL_InterruptHandle interruptHandle, HAL_InterruptHandlerFunction handler, void *param, int32_t *status) |
Attaches an asynchronous interrupt handler to the interrupt. More... | |
void | HAL_AttachInterruptHandlerThreaded (HAL_InterruptHandle interruptHandle, HAL_InterruptHandlerFunction handler, void *param, int32_t *status) |
Attaches an asynchronous interrupt handler to the interrupt. More... | |
void | HAL_SetInterruptUpSourceEdge (HAL_InterruptHandle interruptHandle, HAL_Bool risingEdge, HAL_Bool fallingEdge, int32_t *status) |
Sets the edges to trigger the interrupt on. More... | |
void HAL_AttachInterruptHandler | ( | HAL_InterruptHandle | interruptHandle, |
HAL_InterruptHandlerFunction | handler, | ||
void * | param, | ||
int32_t * | status | ||
) |
Attaches an asynchronous interrupt handler to the interrupt.
This interrupt gets called directly on the FPGA interrupt thread, so will block other interrupts while running.
interruptHandle | the interrupt handle |
handler | the handler function for the interrupt to call |
param | a parameter to be passed to the handler |
void HAL_AttachInterruptHandlerThreaded | ( | HAL_InterruptHandle | interruptHandle, |
HAL_InterruptHandlerFunction | handler, | ||
void * | param, | ||
int32_t * | status | ||
) |
Attaches an asynchronous interrupt handler to the interrupt.
This interrupt gets called on a thread specific to the interrupt, so will not block other interrupts.
interruptHandle | the interrupt handle |
handler | the handler function for the interrupt to call |
param | a parameter to be passed to the handler |
void* HAL_CleanInterrupts | ( | HAL_InterruptHandle | interruptHandle, |
int32_t * | status | ||
) |
Frees an interrupt.
interruptHandle | the interrupt handle |
void HAL_DisableInterrupts | ( | HAL_InterruptHandle | interruptHandle, |
int32_t * | status | ||
) |
Disables interrupts without without deallocating structures.
interruptHandle | the interrupt handle |
void HAL_EnableInterrupts | ( | HAL_InterruptHandle | interruptHandle, |
int32_t * | status | ||
) |
Enables interrupts to occur on this input.
Interrupts are disabled when the RequestInterrupt call is made. This gives time to do the setup of the other options before starting to field interrupts.
interruptHandle | the interrupt handle |
HAL_InterruptHandle HAL_InitializeInterrupts | ( | HAL_Bool | watcher, |
int32_t * | status | ||
) |
Initializes an interrupt.
watcher | true for synchronous interrupts, false for asynchronous |
double HAL_ReadInterruptFallingTimestamp | ( | HAL_InterruptHandle | interruptHandle, |
int32_t * | status | ||
) |
Returns the timestamp for the falling interrupt that occurred most recently.
This is in the same time domain as HAL_GetFPGATime().
interruptHandle | the interrupt handle |
double HAL_ReadInterruptRisingTimestamp | ( | HAL_InterruptHandle | interruptHandle, |
int32_t * | status | ||
) |
Returns the timestamp for the rising interrupt that occurred most recently.
This is in the same time domain as HAL_GetFPGATime().
interruptHandle | the interrupt handle |
void HAL_RequestInterrupts | ( | HAL_InterruptHandle | interruptHandle, |
HAL_Handle | digitalSourceHandle, | ||
HAL_AnalogTriggerType | analogTriggerType, | ||
int32_t * | status | ||
) |
Requests interrupts on a specific digital source.
interruptHandle | the interrupt handle |
digitalSourceHandle | the digital source handle (either a HAL_AnalogTriggerHandle of a HAL_DigitalHandle) |
analogTriggerType | the trigger type if the source is an AnalogTrigger |
void HAL_SetInterruptUpSourceEdge | ( | HAL_InterruptHandle | interruptHandle, |
HAL_Bool | risingEdge, | ||
HAL_Bool | fallingEdge, | ||
int32_t * | status | ||
) |
Sets the edges to trigger the interrupt on.
Note that both edges triggered is a valid configuration.
interruptHandle | the interrupt handle |
risingEdge | true for triggering on rising edge |
fallingEdge | true for triggering on falling edge |
int64_t HAL_WaitForInterrupt | ( | HAL_InterruptHandle | interruptHandle, |
double | timeout, | ||
HAL_Bool | ignorePrevious, | ||
int32_t * | status | ||
) |
In synchronous mode, waits for the defined interrupt to occur.
interruptHandle | the interrupt handle |
timeout | timeout in seconds |
ignorePrevious | if true, ignore interrupts that happened before waitForInterrupt was called |