goodcheney / TTN_Mydevice

1 stars 4 forks source link

dht error compile #1

Open ericwang321 opened 6 years ago

ericwang321 commented 6 years ago

use arduino 1.85

lora Dragino Lora Shield+ arduino+dht11 as lora end device send data the Ttn Network

when compile

__rror: 'dht' does not name a type

dht DHT; ^ XXXX\ Documents\Arduino\sketch_dht\sketch_dht.ino: In function 'void dhtTem()': sketch_dht:199: error: expected primary-expression before '.' token temperature = DHT.read11(DHT11_PIN); //Temperature detection__

but with   (

https://github.com/dragino/Arduino-Profile-Examples/blob/master/libraries/Dragino/examples/LoRa/multi-nodes-with-temperature-sensor/LoRa_Simple_Client_DHT11/LoRa_Simple_Client_DHT11.ino

) work fine

@goodcheney dht library problem?

leewens1303 commented 5 years ago

https://github.com/RobTillaart/Arduino/archive/master.zip Copy the Arduino-master/libraries/DHTstable subfolder to the arduino library folder of your device. Change to if required.