PAW_Sensor: This library control the PAW sensor. This library get sensor values from the PAW sensor, and send these values to PC through serial-communication. And you need to convert these values to delta h using some module on PC. I create sample python module for this library. If you want to get this module, please access below page, https://github.com/HiroakiMatsuda/PAW-Sensor The PAW Sensor is developed by RT. If you need to get information about this sensors, please access below page. http://www.rt-shop.jp/index.php?main_page=product_info&cPath=42&products_id=1303

Dependents:   PAW_Sensor_HelloWorld

Files at this revision

API Documentation at this revision

Comitter:
matsu
Date:
Sun Nov 09 11:40:29 2014 +0000
Parent:
2:6a493f73860c
Child:
4:ea00b3135f6e
Commit message:
Add id parameter to print().

Changed in this revision

paw.cpp Show annotated file Show diff for this revision Revisions of this file
paw.h Show annotated file Show diff for this revision Revisions of this file
--- a/paw.cpp	Sun Nov 09 08:21:00 2014 +0000
+++ b/paw.cpp	Sun Nov 09 11:40:29 2014 +0000
@@ -58,12 +58,12 @@
     return _state;
 }
 
-void PAW::print( Serial* pc )
+void PAW::print( Serial* pc, unsigned char id )
 {
-    pc->printf("%c%c%c%c%c%c%c%c%c%c", 0xFA, 0xAF, 
-                                           _value.ch_1 & 0x00FF, ( _value.ch_1 & 0xFF00 ) >> 8,
-                                           _value.ch_2 & 0x00FF, ( _value.ch_2 & 0xFF00 ) >> 8,
-                                           _value.ch_3 & 0x00FF, ( _value.ch_3 & 0xFF00 ) >> 8,
-                                           _value.ch_4 & 0x00FF, ( _value.ch_4 & 0xFF00 ) >> 8);
+    pc->printf("%c%c%c%c%c%c%c%c%c%c%c", 0xFA, 0xAF, id,
+                                         _value.ch_1 & 0x00FF, ( _value.ch_1 & 0xFF00 ) >> 8,
+                                         _value.ch_2 & 0x00FF, ( _value.ch_2 & 0xFF00 ) >> 8,
+                                         _value.ch_3 & 0x00FF, ( _value.ch_3 & 0xFF00 ) >> 8,
+                                         _value.ch_4 & 0x00FF, ( _value.ch_4 & 0xFF00 ) >> 8);
 }
     
--- a/paw.h	Sun Nov 09 08:21:00 2014 +0000
+++ b/paw.h	Sun Nov 09 11:40:29 2014 +0000
@@ -107,7 +107,7 @@
          *
          * @param Reference to serial object.
          */ 
-        void print( Serial* );
+        void print( Serial* pc, unsigned char id );
         
     protected:
         DigitalOut _led_1;