VSF Documented
|
Macros | |
#define | VSF_USART_CFG_PROTECT_LEVEL interrupt |
#define | __vsf_usart_protect vsf_protect(VSF_USART_CFG_PROTECT_LEVEL) |
#define | __vsf_usart_unprotect vsf_unprotect(VSF_USART_CFG_PROTECT_LEVEL) |
#define | ____USART_LOCAL(__N, __DONT_CARE) |
#define | __USART_LOCAL(__N, __DONT_CARE) ____USART_LOCAL(__N, __DONT_CARE) |
Functions | |
vsf_err_t | vsf_usart_init (vsf_usart_t *usart_ptr, vsf_usart_cfg_t *cfg_ptr) |
initialize a usart instance. | |
fsm_rt_t | vsf_usart_enable (vsf_usart_t *usart_ptr) |
enable interrupt masks of usart instance. | |
fsm_rt_t | vsf_usart_disable (vsf_usart_t *usart_ptr) |
disable interrupt masks of usart instance. | |
vsf_usart_status_t | vsf_usart_status (vsf_usart_t *usart_ptr) |
get the status of usart instance. | |
bool | vsf_usart_read_byte (vsf_usart_t *usart_ptr, uint8_t *byte_ptr) |
bool | vsf_usart_write_byte (vsf_usart_t *usart_ptr, uint_fast8_t byte) |
fsm_rt_t | vsf_usart_request_read (vsf_usart_t *usart_ptr, uint8_t *buffer_ptr, uint_fast32_t size) |
fsm_rt_t | vsf_usart_request_write (vsf_usart_t *usart_ptr, uint8_t *buffer_ptr, uint_fast32_t size) |
void | vsf_usart_irqhandler (vsf_usart_t *usart_ptr) |
void | vsf_usart_event_register (vsf_usart_t *usart_ptr, vsf_usart_event_type_t type, vsf_usart_event_t event) |
usart_event_status_t | vsf_usart_event_enable (vsf_usart_t *usart_ptr, usart_event_status_t event_mask) |
usart_event_status_t | vsf_usart_event_disable (vsf_usart_t *usart_ptr, usart_event_status_t event_mask) |
void | vsf_usart_event_resume (vsf_usart_t *usart_ptr, usart_event_status_t event_status) |
#define VSF_USART_CFG_PROTECT_LEVEL interrupt |
#define __vsf_usart_protect vsf_protect(VSF_USART_CFG_PROTECT_LEVEL) |
#define __vsf_usart_unprotect vsf_unprotect(VSF_USART_CFG_PROTECT_LEVEL) |
#define ____USART_LOCAL | ( | __N, | |
__DONT_CARE | |||
) |
#define __USART_LOCAL | ( | __N, | |
__DONT_CARE | |||
) | ____USART_LOCAL(__N, __DONT_CARE) |
vsf_err_t vsf_usart_init | ( | vsf_usart_t * | usart_ptr, |
vsf_usart_cfg_t * | cfg_ptr | ||
) |
initialize a usart instance.
[in] | usart_ptr | a pointer to structure vsf_usart_t |
[in] | cfg_ptr | a pointer to structure vsf_usart_cfg_t |
calculate baudrate
fsm_rt_t vsf_usart_enable | ( | vsf_usart_t * | usart_ptr | ) |
enable interrupt masks of usart instance.
[in] | usart_ptr | a pointer to structure vsf_usart_t |
don't forget to enable sync clock and peripheral_clk here
fsm_rt_t vsf_usart_disable | ( | vsf_usart_t * | usart_ptr | ) |
disable interrupt masks of usart instance.
[in] | usart_ptr | a pointer to structure vsf_usart_t |
don't forget to disable sync clock and peripheral_clk here
vsf_usart_status_t vsf_usart_status | ( | vsf_usart_t * | usart_ptr | ) |
get the status of usart instance.
[in] | usart_ptr | a pointer to structure vsf_usart_t |
bool vsf_usart_read_byte | ( | vsf_usart_t * | usart_ptr, |
uint8_t * | byte_ptr | ||
) |
bool vsf_usart_write_byte | ( | vsf_usart_t * | usart_ptr, |
uint_fast8_t | byte | ||
) |
fsm_rt_t vsf_usart_request_read | ( | vsf_usart_t * | usart_ptr, |
uint8_t * | buffer_ptr, | ||
uint_fast32_t | size | ||
) |
fsm_rt_t vsf_usart_request_write | ( | vsf_usart_t * | usart_ptr, |
uint8_t * | buffer_ptr, | ||
uint_fast32_t | size | ||
) |
void vsf_usart_irqhandler | ( | vsf_usart_t * | usart_ptr | ) |
void vsf_usart_event_register | ( | vsf_usart_t * | usart_ptr, |
vsf_usart_event_type_t | type, | ||
vsf_usart_event_t | event | ||
) |
usart_event_status_t vsf_usart_event_enable | ( | vsf_usart_t * | usart_ptr, |
usart_event_status_t | event_mask | ||
) |
usart_event_status_t vsf_usart_event_disable | ( | vsf_usart_t * | usart_ptr, |
usart_event_status_t | event_mask | ||
) |
void vsf_usart_event_resume | ( | vsf_usart_t * | usart_ptr, |
usart_event_status_t | event_status | ||
) |