lyre liu / Mbed 2 deprecated project1

Dependencies:   mbed

Files at this revision

API Documentation at this revision

Comitter:
lyreliu
Date:
Tue Mar 08 08:00:01 2016 +0000
Parent:
6:0d854548023b
Child:
8:120355a81f73
Commit message:
program;

Changed in this revision

main.cpp Show annotated file Show diff for this revision Revisions of this file
--- a/main.cpp	Tue Mar 08 07:41:12 2016 +0000
+++ b/main.cpp	Tue Mar 08 08:00:01 2016 +0000
@@ -13,8 +13,8 @@
 DigitalOut low_pin(p6);             //test pin, p6 is the low level pin
                                     
 float mass;                         // The mass of the object
-unsigned short int mass_trans_high; // A 8 bits mass used for transmitting
-unsigned short int mass_trans_low;
+unsigned char mass_trans_high; // A 8 bits mass used for transmitting
+unsigned char mass_trans_low;
 
 unsigned short int test;
 
@@ -54,7 +54,7 @@
 
 void SerialTransmit(void)
 {   
-    unsigned short int start,end;
+    unsigned char start,end;
     start = 0xfe;
     end   = 0xff;
     if(mass>3)