SAM Serial Peripheral Interface Driver.
Copyright (c) 2012-2018 Microchip Technology Inc. and its subsidiaries.
Typedefs | |
typedef void(* | sercom_handler_t )(uint8_t instance) |
Functions | |
enum system_interrupt_vector | _sercom_get_interrupt_vector (Sercom *const sercom_instance) |
void | _sercom_set_handler (const uint8_t instance, const sercom_handler_t interrupt_handler) |
Variables | |
void * | _sercom_instances [SERCOM_INST_NUM] |
typedef void(* sercom_handler_t)(uint8_t instance) |
enum system_interrupt_vector _sercom_get_interrupt_vector | ( | Sercom *const | sercom_instance | ) |
Returns the system interrupt vector.
[in] | sercom_instance | Instance pointer |
SYSTEM_INTERRUPT_MODULE_SERCOM0 | |
SYSTEM_INTERRUPT_MODULE_SERCOM1 | |
SYSTEM_INTERRUPT_MODULE_SERCOM2 | |
SYSTEM_INTERRUPT_MODULE_SERCOM3 | |
SYSTEM_INTERRUPT_MODULE_SERCOM4 | |
SYSTEM_INTERRUPT_MODULE_SERCOM5 | |
SYSTEM_INTERRUPT_MODULE_SERCOM6 | |
SYSTEM_INTERRUPT_MODULE_SERCOM7 |
References _sercom_get_sercom_inst_index(), _SERCOM_INTERRUPT_VECT_NUM, and MREPEAT.
Referenced by spi_disable(), spi_enable(), usart_disable(), and usart_enable().
void _sercom_set_handler | ( | const uint8_t | instance, |
const sercom_handler_t | interrupt_handler | ||
) |
Saves the given callback handler.
[in] | instance | Instance index. |
[in] | interrupt_handler | Pointer to instance callback handler. |
References _handler_table_initialized, _sercom_default_handler(), _sercom_instances, and _sercom_interrupt_handlers.
Referenced by spi_init(), and usart_init().
void* _sercom_instances[SERCOM_INST_NUM] |
Referenced by _sercom_set_handler(), _usart_interrupt_handler(), spi_init(), and usart_init().