TM-T82II EPSON Thermal Printer. RS232 Interface Nucleo

Dependencies:   EPSON mbed

Files at this revision

API Documentation at this revision

Comitter:
shivanandgowdakr
Date:
Mon Jul 09 08:08:52 2018 +0000
Commit message:
EPSON Thermal Printer RS232 Interface TM-T82II

Changed in this revision

EPSON.lib Show annotated file Show diff for this revision Revisions of this file
main.cpp Show annotated file Show diff for this revision Revisions of this file
mbed.bld Show annotated file Show diff for this revision Revisions of this file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/EPSON.lib	Mon Jul 09 08:08:52 2018 +0000
@@ -0,0 +1,1 @@
+https://os.mbed.com/users/shivanandgowdakr/code/EPSON/#19ca061f5bcf
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/main.cpp	Mon Jul 09 08:08:52 2018 +0000
@@ -0,0 +1,37 @@
+#include "mbed.h"
+ 
+ #include "EPSON.h"
+ 
+  Serial pc(USBTX, USBRX);
+ EPSON tp(D1,D0); // tx, 9600bps
+ 
+  int main()
+  {
+      tp.initialize();
+      tp.putLineFeed(2);
+ 
+      tp.printf("**EPSON  Thermal Printer  **\r\r");
+ 
+     
+      
+     tp.setDoubleSizeWidth();
+     tp.printf("ABCDEFG 0123456789\r");
+     tp.clearDoubleSizeWidth();
+ 
+     tp.setDoubleSizeHeight();
+     tp.printf("ABCDEFG 0123456789\r");
+     tp.clearDoubleSizeHeight();
+     
+     tp.PrintBarCode("1234567890123456",16);
+ 
+     pc.printf("EPSON Thermal Printer\n\n");
+     
+     
+     while(1) {
+         if (pc.readable()) {
+             int c = pc.getc();
+             pc.putc(c);
+             tp.putc(c);
+         }
+     }
+  }
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/mbed.bld	Mon Jul 09 08:08:52 2018 +0000
@@ -0,0 +1,1 @@
+https://os.mbed.com/users/mbed_official/code/mbed/builds/a7c7b631e539
\ No newline at end of file