-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathprintit.h
99 lines (88 loc) · 1.6 KB
/
printit.h
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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
void printit(const __FlashStringHelper *);
void printit(const String &);
void printit(const char[]);
void printit(char);
void printit(unsigned char, int = DEC);
void printit(int, int = DEC);
void printit(unsigned int, int = DEC);
void printit(long, int = DEC);
void printit(unsigned long, int = DEC);
void printit(double, int = 2);
void printit(const Printable&);
void printit(const __FlashStringHelper *ifsh)
{
ui.print(ifsh);
if (noecho == 0) {
mySerial.print(ifsh);
}
}
void printit(const String &s)
{
ui.print(s);
if (noecho == 0) {
mySerial.print(s);
}
}
void printit(const char str[])
{
ui.print(str);
if (noecho == 0) {
mySerial.print(str);
}
}
void printit(char c)
{
ui.print(c);
if (noecho == 0) {
mySerial.print(c);
}
}
void printit(unsigned char b, int base)
{
ui.print(b, base);
if (noecho == 0) {
mySerial.print(b, base);
}
}
void printit(int n, int base)
{
ui.print(n, base);
if (noecho == 0) {
mySerial.print(n, base);
}
}
void printit(unsigned int n, int base)
{
ui.print(n, base);
if (noecho == 0) {
mySerial.print(n, base);
}
}
void printit(long n, int base)
{
ui.print(n, base);
if (noecho == 0) {
mySerial.print(n, base);
}
}
void printit(unsigned long n, int base)
{
ui.print(n, base);
if (noecho == 0) {
mySerial.print(n, base);
}
}
void printit(double n, int digits)
{
ui.print(n, digits);
if (noecho == 0) {
mySerial.print(n, digits);
}
}
void printit(const Printable& x)
{
ui.print(x);
if (noecho == 0) {
mySerial.print(x);
}
}