Inherit from Serial and use software buffers for TX and RX. This allows the UART peripherals to operate in a IRQ driven mode. Overrides most (but not all) stdio functions as Serial did

Dependencies:   Buffer

Fork of BufferedSerial by Sam Grove

Files at this revision

API Documentation at this revision

Comitter:
ninad
Date:
Tue Nov 15 12:39:45 2016 +0000
Parent:
12:a0d37088b405
Commit message:
no change

Changed in this revision

BufferedSerial.cpp Show annotated file Show diff for this revision Revisions of this file
diff -r a0d37088b405 -r 14c80cd78f1d BufferedSerial.cpp
--- a/BufferedSerial.cpp	Mon Mar 07 21:10:27 2016 +0000
+++ b/BufferedSerial.cpp	Tue Nov 15 12:39:45 2016 +0000
@@ -81,7 +81,7 @@
 
 int BufferedSerial::printf(const char* format, ...)
 {
-    char buffer[this->_buf_size];
+    char buffer[100];
     memset(buffer,0,this->_buf_size);
     int r = 0;