this is a test

Dependencies:   mbed TextLCD RemoteIR

Fork of RemoteIR_TestProgram by Shinichiro Nakamura

Files at this revision

API Documentation at this revision

Comitter:
sarvagyavaish
Date:
Fri Nov 22 16:17:01 2013 +0000
Parent:
5:40750d5779ca
Commit message:
Loopback Test with serial output

Changed in this revision

main.cpp Show annotated file Show diff for this revision Revisions of this file
--- a/main.cpp	Wed Oct 13 10:51:41 2010 +0000
+++ b/main.cpp	Fri Nov 22 16:17:01 2013 +0000
@@ -11,7 +11,7 @@
 #include "TransmitterIR.h"
 #include "TextLCD.h"
 
-#define TEST_LOOP_BACK  0
+#define TEST_LOOP_BACK  1
 
 ReceiverIR ir_rx(p15);
 TransmitterIR ir_tx(p21);
@@ -101,13 +101,13 @@
  * @param bitlength Bit length of a data.
  */
 void display_data(uint8_t *buf, int bitlength) {
-    lcd.locate(0, 1);
+    //lcd.locate(0, 1);
     const int n = bitlength / 8 + (((bitlength % 8) != 0) ? 1 : 0);
     for (int i = 0; i < n; i++) {
-        lcd.printf("%02X", buf[i]);
+        printf("%02X", buf[i]);
     }
     for (int i = 0; i < 8 - n; i++) {
-        lcd.printf("--");
+        printf("--");
     }
 }