|
cursada_mc2
Base de control de temperatura para EDU-CIAA-NXP
|
Interfaz del driver UART bloqueante. More...
#include <chip.h>
Include dependency graph for uart_driver.h:
This graph shows which files directly or indirectly include this file:Go to the source code of this file.
Macros | |
| #define | INT_RX 1 |
| Habilita interrupcion de recepcion. | |
| #define | INT_TX 2 |
| Habilita interrupcion de transmision. | |
| #define | BAUD_9600 9600 |
| Constante de baudrate a 9600 baudios. | |
| #define | BAUD_115K 115200 |
| Constante de baudrate a 115200 baudios. | |
Functions | |
| void | driver_uart_init (uint8_t channel) |
| Inicializa un canal UART en modo bloqueante. | |
| void | driver_uart_int_enable (uint8_t int_type) |
| Habilita una interrupcion UART sobre el canal ya configurado. | |
| void | driver_uart_send_char (uint8_t data) |
| Transmite un byte por UART en modo bloqueante. | |
| void | driver_uart_send_string (const void *data, uint16_t num_bytes) |
| Transmite una secuencia de bytes por UART en modo bloqueante. | |
| void | driver_uart_receive_char (void *data) |
| Recibe un byte por UART en modo bloqueante. | |
| #define BAUD_115K 115200 |
Definition at line 19 of file uart_driver.h.
| #define BAUD_9600 9600 |
Definition at line 17 of file uart_driver.h.
| #define INT_RX 1 |
Definition at line 12 of file uart_driver.h.
| #define INT_TX 2 |
Definition at line 14 of file uart_driver.h.
| void driver_uart_init | ( | uint8_t | channel | ) |
| channel | Canal UART a utilizar. |
Definition at line 16 of file uart_driver.c.
References BAUD_115K, and uart_channel_.
| void driver_uart_int_enable | ( | uint8_t | int_type | ) |
| int_type | Tipo de interrupcion a habilitar. |
Definition at line 46 of file uart_driver.c.
References INT_RX, INT_TX, and uart_channel_.
| void driver_uart_receive_char | ( | void * | data | ) |
| data | Puntero donde se almacenara el byte recibido. |
Definition at line 65 of file uart_driver.c.
References uart_channel_.
| void driver_uart_send_char | ( | uint8_t | data | ) |
| data | Byte a transmitir. |
Definition at line 55 of file uart_driver.c.
References uart_channel_.
| void driver_uart_send_string | ( | const void * | data, |
| uint16_t | num_bytes | ||
| ) |
| data | Puntero al buffer a transmitir. |
| num_bytes | Cantidad de bytes a transmitir. |
Definition at line 60 of file uart_driver.c.
References uart_channel_.