Flipklok
 
Loading...
Searching...
No Matches
uart.h
Go to the documentation of this file.
1/*
2 * uart.h
3 *
4 * Created on: 2 apr. 2025
5 */
6
7#ifndef UART_H_
8#define UART_H_
9
10#include <msp430.h>
11#include <stdint.h>
12#include <stdbool.h>
13
14#define UART_ENABLED //Enables UART
15
16void UART_Init(void);
17void UART_SendChar(char c);
18void UART_SendString(char *str);
19
20void UART_SendUint32(uint32_t num);
21void UART_SendInt(int32_t num);
22
23void UART_SendTime(uint32_t seconds);
24
25void UART_Bitstream(const bool* arr, unsigned int length);
26
27
28
29#endif /* UART_H_ */
void UART_SendChar(char c)
send a single character via UART to host system
Definition uart.c:37
void UART_SendInt(int32_t num)
send a 16 bit integer to host system
Definition uart.c:63
void UART_Bitstream(const bool *arr, unsigned int length)
Sends a the received DCF bitstream to host system.
Definition uart.c:154
void UART_SendTime(uint32_t seconds)
Sends a time formated in hours and minutes to host system.
Definition uart.c:131
void UART_Init(void)
Setup UART communication, gets called from main()
Definition uart.c:18
void UART_SendUint32(uint32_t num)
send a 32 bit integer to host system
Definition uart.c:103
void UART_SendString(char *str)
send a full string to host system
Definition uart.c:49