-
Notifications
You must be signed in to change notification settings - Fork 0
/
log.c
53 lines (47 loc) · 972 Bytes
/
log.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
/**
* Quadrofly Software (http://quadrofly.ni-c.de)
*
* @file log.c
* @brief Log helper class
* @author Willi Thiel ([email protected])
* @date Mar 7, 2012
*/
//#include "main.h"
//#include <avr/io.h>
#include <stdio.h>
//#include <stdint.h>
#include <inttypes.h>
//#include "config.h"
//#include "uart.h"
/**
* Poll the specified uint16_t out the log port.
*
* @param i The specified uint16_t
*/
void log_uint16_t(uint16_t i) {
//#ifdef LOG_AVAILABLE
//#ifdef UART_AVAILABLE
uart_tx_uint16_t(i);
//#endif /* UART_AVAILABLE */
//#endif /* LOG_AVAILBLE */
}
/**
* Poll the specified int16_t out the log port.
*
* @param i The specified int16_t
*/
void log_int16_t(int16_t i) {
#ifdef LOG_AVAILABLE
uart_tx_int16_t(i);
#endif /* LOG_AVAILBLE */
}
/**
* Poll the specified string out the log port.
*
* @param s The specified string
*/
void log_s(const char *s) {
#ifdef LOG_AVAILABLE
uart0_puts(s);
#endif /* LOG_AVAILBLE */
}