aboutsummaryrefslogtreecommitdiff
path: root/cores/arduino/wiring_serial.c
diff options
context:
space:
mode:
Diffstat (limited to 'cores/arduino/wiring_serial.c')
-rwxr-xr-xcores/arduino/wiring_serial.c85
1 files changed, 1 insertions, 84 deletions
diff --git a/cores/arduino/wiring_serial.c b/cores/arduino/wiring_serial.c
index 9392a09..4cac891 100755
--- a/cores/arduino/wiring_serial.c
+++ b/cores/arduino/wiring_serial.c
@@ -126,87 +126,4 @@ SIGNAL(SIG_UART_RECV)
rx_buffer[rx_buffer_head] = c;
rx_buffer_head = i;
}
-}
-
-void printMode(int mode)
-{
- // do nothing, we only support serial printing, not lcd.
-}
-
-void printByte(unsigned char c)
-{
- serialWrite(c);
-}
-
-void printNewline()
-{
- printByte('\n');
-}
-
-void printString(const char *s)
-{
- while (*s)
- printByte(*s++);
-}
-
-void printIntegerInBase(unsigned long n, unsigned long base)
-{
- unsigned char buf[8 * sizeof(long)]; // Assumes 8-bit chars.
- unsigned long i = 0;
-
- if (n == 0) {
- printByte('0');
- return;
- }
-
- while (n > 0) {
- buf[i++] = n % base;
- n /= base;
- }
-
- for (; i > 0; i--)
- printByte(buf[i - 1] < 10 ?
- '0' + buf[i - 1] :
- 'A' + buf[i - 1] - 10);
-}
-
-void printInteger(long n)
-{
- if (n < 0) {
- printByte('-');
- n = -n;
- }
-
- printIntegerInBase(n, 10);
-}
-
-void printHex(unsigned long n)
-{
- printIntegerInBase(n, 16);
-}
-
-void printOctal(unsigned long n)
-{
- printIntegerInBase(n, 8);
-}
-
-void printBinary(unsigned long n)
-{
- printIntegerInBase(n, 2);
-}
-
-/* Including print() adds approximately 1500 bytes to the binary size,
- * so we replace it with the smaller and less-confusing printString(),
- * printInteger(), etc.
-void print(const char *format, ...)
-{
- char buf[256];
- va_list ap;
-
- va_start(ap, format);
- vsnprintf(buf, 256, format, ap);
- va_end(ap);
-
- printString(buf);
-}
-*/
+} \ No newline at end of file