test bmp085,mpxv7002dp

Dependencies:   BMP085_2 GPS mbed

Fork of HelloBMP085 by Takashi SASAKI

Files at this revision

API Documentation at this revision

Comitter:
TakashiSasaki
Date:
Mon Jul 29 07:53:31 2013 +0000
Child:
1:99bcc6f8c856
Commit message:
I2C communication with BMP085 by p27 and p28.

Changed in this revision

BMP085.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/BMP085.lib	Mon Jul 29 07:53:31 2013 +0000
@@ -0,0 +1,1 @@
+https://mbed.org/users/okini3939/code/BMP085/#e0e88a46e11d
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/main.cpp	Mon Jul 29 07:53:31 2013 +0000
@@ -0,0 +1,21 @@
+#include "mbed.h"
+#include "BMP085.h"
+
+DigitalOut myled(LED1);
+BMP085 bmp085(p28, p27); 
+Serial pc(USBTX, USBRX);
+ 
+int main() {
+    pc.printf("main\n");
+    float p, t;
+ 
+    while(1) {
+        myled = 1;
+        bmp085.update();
+        p = bmp085.get_pressure();
+        t = bmp085.get_temperature();
+        pc.printf("P %6.2f t %6.2f\n", p, t);
+        myled = 0;
+        wait(3);
+    }//while
+}//main
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/mbed.bld	Mon Jul 29 07:53:31 2013 +0000
@@ -0,0 +1,1 @@
+http://mbed.org/users/mbed_official/code/mbed/builds/b3110cd2dd17
\ No newline at end of file