IoT실습 HW3 mbed

Fork of DHT by jajn HA

Files at this revision

API Documentation at this revision

Comitter:
priscilla5328
Date:
Tue Jan 02 14:06:36 2018 +0000
Parent:
4:1e78a462b211
Commit message:
HW3

Changed in this revision

DHT.cpp Show annotated file Show diff for this revision Revisions of this file
README.md Show annotated file Show diff for this revision Revisions of this file
--- a/DHT.cpp	Thu Jul 20 09:04:07 2017 +0000
+++ b/DHT.cpp	Tue Jan 02 14:06:36 2018 +0000
@@ -36,7 +36,7 @@
 
 DHT::DHT(PinName pin, eType DHTtype)
 {
-    _pin = pin;
+    _pin = A0;
     _DHTtype = DHTtype;
     _firsttime = true;
 }
@@ -136,7 +136,7 @@
 
 float DHT::CalcTemperature()
 {
-    int v;
+    float v;
 
     switch (_DHTtype) {
         case DHT11:
@@ -208,7 +208,7 @@
 
 float DHT::CalcHumidity()
 {
-    int v;
+    float v;
 
     switch (_DHTtype) {
         case DHT11:
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/README.md	Tue Jan 02 14:06:36 2018 +0000
@@ -0,0 +1,10 @@
+# mbed-os-example-coap
+
+This application demonstrates how to connect to a CoAP server from mbed OS 5. It connects to coap://coap.me, sends a message to `/hello` and receives the response.
+
+## To build
+
+1. Open ``mbed_app.json`` and change the `network-interface` option to your connectivity method ([more info](https://github.com/ARMmbed/easy-connect)).
+2. Build the project in the online compiler or using mbed CLI.
+3. Flash the project to your development board.
+4. Attach a serial monitor to your board to see the debug messages.