problem IN running DHT11 sensor

hello.
i want to run dth11 sensor with marlin code. i installed libraries and other stuff as instruction in github but i get below errors.

Arduino: 1.8.13 (Windows Store 1.8.42.0) (Windows 10), Board: "Arduino Mega or Mega 2560, ATmega2560 (Mega 2560)"

libraries\DHT-sensor-library\DHT_U.cpp.o (symbol from plugin): In function `DHT_Unified::Temperature::getEvent(sensors_event_t*)':

(.text+0x0): multiple definition of `DHT_Unified::Temperature::getEvent(sensors_event_t*)'

sketch\DHT_U.cpp.o (symbol from plugin):(.text+0x0): first defined here

libraries\DHT-sensor-library\DHT_U.cpp.o (symbol from plugin): In function `DHT_Unified::Temperature::getEvent(sensors_event_t*)':

(.text+0x0): multiple definition of `DHT_Unified::Humidity::getEvent(sensors_event_t*)'

sketch\DHT_U.cpp.o (symbol from plugin):(.text+0x0): first defined here

libraries\DHT-sensor-library\DHT_U.cpp.o (symbol from plugin): In function `DHT_Unified::Temperature::getEvent(sensors_event_t*)':

(.text+0x0): multiple definition of `DHT_Unified::DHT_Unified(unsigned char, unsigned char, unsigned char, long, long)'

sketch\DHT_U.cpp.o (symbol from plugin):(.text+0x0): first defined here

libraries\DHT-sensor-library\DHT_U.cpp.o (symbol from plugin): In function `DHT_Unified::Temperature::getEvent(sensors_event_t*)':

(.text+0x0): multiple definition of `DHT_Unified::DHT_Unified(unsigned char, unsigned char, unsigned char, long, long)'

sketch\DHT_U.cpp.o (symbol from plugin):(.text+0x0): first defined here

libraries\DHT-sensor-library\DHT_U.cpp.o (symbol from plugin): In function `DHT_Unified::Temperature::getEvent(sensors_event_t*)':

(.text+0x0): multiple definition of `DHT_Unified::begin()'

sketch\DHT_U.cpp.o (symbol from plugin):(.text+0x0): first defined here

libraries\DHT-sensor-library\DHT_U.cpp.o (symbol from plugin): In function `DHT_Unified::Temperature::getEvent(sensors_event_t*)':

(.text+0x0): multiple definition of `DHT_Unified::setName(sensor_t*)'

sketch\DHT_U.cpp.o (symbol from plugin):(.text+0x0): first defined here

libraries\DHT-sensor-library\DHT_U.cpp.o (symbol from plugin): In function `DHT_Unified::Temperature::getEvent(sensors_event_t*)':

(.text+0x0): multiple definition of `DHT_Unified::setMinDelay(sensor_t*)'

sketch\DHT_U.cpp.o (symbol from plugin):(.text+0x0): first defined here

libraries\DHT-sensor-library\DHT_U.cpp.o (symbol from plugin): In function `DHT_Unified::Temperature::getEvent(sensors_event_t*)':

(.text+0x0): multiple definition of `DHT_Unified::Temperature::getSensor(sensor_t*)'

sketch\DHT_U.cpp.o (symbol from plugin):(.text+0x0): first defined here

libraries\DHT-sensor-library\DHT_U.cpp.o (symbol from plugin): In function `DHT_Unified::Temperature::getEvent(sensors_event_t*)':

(.text+0x0): multiple definition of `DHT_Unified::Humidity::getSensor(sensor_t*)'

sketch\DHT_U.cpp.o (symbol from plugin):(.text+0x0): first defined here

libraries\DHT-sensor-library\DHT_U.cpp.o (symbol from plugin): In function `DHT_Unified::Temperature::getEvent(sensors_event_t*)':

(.text+0x0): multiple definition of `DHT_Unified::Temperature::Temperature(DHT_Unified*, long)'

sketch\DHT_U.cpp.o (symbol from plugin):(.text+0x0): first defined here

libraries\DHT-sensor-library\DHT_U.cpp.o (symbol from plugin): In function `DHT_Unified::Temperature::getEvent(sensors_event_t*)':

(.text+0x0): multiple definition of `DHT_Unified::Temperature::Temperature(DHT_Unified*, long)'

sketch\DHT_U.cpp.o (symbol from plugin):(.text+0x0): first defined here

libraries\DHT-sensor-library\DHT_U.cpp.o (symbol from plugin): In function `DHT_Unified::Temperature::getEvent(sensors_event_t*)':

(.text+0x0): multiple definition of `DHT_Unified::Humidity::Humidity(DHT_Unified*, long)'

sketch\DHT_U.cpp.o (symbol from plugin):(.text+0x0): first defined here

libraries\DHT-sensor-library\DHT_U.cpp.o (symbol from plugin): In function `DHT_Unified::Temperature::getEvent(sensors_event_t*)':

(.text+0x0): multiple definition of `DHT_Unified::Humidity::Humidity(DHT_Unified*, long)'

sketch\DHT_U.cpp.o (symbol from plugin):(.text+0x0): first defined here

HardwareSerial0.cpp.o (symbol from plugin): In function `Serial':

(.text+0x0): multiple definition of `__vector_25'

sketch\MarlinSerial.cpp.o (symbol from plugin):(.text+0x0): first defined here

collect2.exe: error: ld returned 1 exit status

exit status 1

Error compiling for board Arduino Mega or Mega 2560.

This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.

These errors indicate that you put a copy of the library source files in your sketch folder in addition to the normally installed library.

Do this:

  • (in the Arduino IDE) Sketch > Show Sketch Folder
  • Delete all the files in the sketch folder that have "DHT" in their name. Please be very careful when deleting files from your computer. When in doubt, back up!

Now try compiling Marlin again

Thnaks it was helpful :wink:

You're welcome. I'm glad if I was able to be of assistance. Enjoy!
Per

another problem came up. :{
i want define DHT11 as bed temperature sensor. would you please help me?