Dht11 motor control based on humidity levels

Hi guys, i am trying to create a project where i use the dht11 sensor to turn on na doff the motor based on humidity values. When i power it up it works fine for the condition IF HUMIDITY IS LESS THAN 80% START MOTOR, but when the motor starts the seonor stops sending readings to serila monitor, and i have to unplug power for it to start again, any help folks.

Using recommended tags, post your code.
Also post your wiring schematic

Best guess is the motor running somehow interferes with the DHT1 signal. However it could also be in the code.

You need to post the code and a schematic.

1 Like

Be sure the schematic is annotated, a frizzy is wiring diagram not a schematic. Be cretin to show all connections, power, ground and other electronic components as well as power sources. Run your spelling checker over your responses.