MengLi Shih
/
3_3_Monitor_Display
lab3_3
Revision 0:2e0d5e886234, committed 2017-02-26
- Comitter:
- shih775007
- Date:
- Sun Feb 26 08:49:10 2017 +0000
- Commit message:
- lab3_3
Changed in this revision
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 |
diff -r 000000000000 -r 2e0d5e886234 main.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/main.cpp Sun Feb 26 08:49:10 2017 +0000 @@ -0,0 +1,12 @@ +#include "mbed.h" +Serial pc( USBTX, USBRX ); +AnalogIn Ain(A0); +float ADCdata; + +int main(){ + while(1){ + ADCdata = Ain; + wait(0.5); + pc.printf("%1.3f\r\n", ADCdata); + } +} \ No newline at end of file
diff -r 000000000000 -r 2e0d5e886234 mbed.bld --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/mbed.bld Sun Feb 26 08:49:10 2017 +0000 @@ -0,0 +1,1 @@ +http://mbed.org/users/mbed_official/code/mbed/builds/ef9c61f8c49f \ No newline at end of file