This sample code is to upload temperature and air pressure data to your Fastsensing account. It uses SCP1000 to measure temp and pressure. 解説記事はこちら(https://qiita.com/AkiraKashihara/items/fd21fa4fd85aa9f723aa)
Dependencies: EthernetInterface Fastsensing HTTPClient SCP1000 mbed-rtos mbed
Revision 1:507f14e0c252, committed 2017-04-30
- Comitter:
- AkiraK
- Date:
- Sun Apr 30 10:30:10 2017 +0000
- Parent:
- 0:4b1269eccf13
- Commit message:
- Put define of Device basic information on Global area.; Change variable of device ID and channel.
Changed in this revision
main.cpp | Show annotated file Show diff for this revision Revisions of this file |
diff -r 4b1269eccf13 -r 507f14e0c252 main.cpp --- a/main.cpp Tue Apr 04 14:07:19 2017 +0000 +++ b/main.cpp Sun Apr 30 10:30:10 2017 +0000 @@ -8,10 +8,11 @@ Fastsensing fast; SCP1000 scp1000(p5,p6,p7,p8); +//Define User's Device Basic Information +char *deviceId = "Device ID(16 digits)"; //Device ID +char *channel[3] = {"Channel ID(8 digits)", "Channel ID", "Channel ID"}; //Channel ID : 1st ID is temperature. 2nd is humidity. + int main() { - //Define User's Device Basic Information - char *deviceId = "UIYCOQAATQAO5AF7"; //Device ID - char *channel[3] = {"RFMZW246", "KLQWUD3M", "VT7OQEYA"}; //Channel ID : 1st ID is temperature. 2nd is humidity. float data[3]; //Data holder fast.ethConnect(); //Ethernet connect