Skip to content
  • MySensors
  • OpenHardware.io
  • Categories
  • Recent
  • Tags
  • Popular
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo
  1. Home
  2. My Project
  3. My Sesnor DHT - can't upload to Uno

My Sesnor DHT - can't upload to Uno

Scheduled Pinned Locked Moved My Project
9 Posts 3 Posters 4.6k Views 2 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • robertmtR Offline
    robertmtR Offline
    robertmt
    wrote on last edited by
    #1

    Hello.

    I'm trying to upload a example sketch from mysensors.org and I have this error... Reinstalled Arduino, downloaded DHT libraries and still nothing....
    This is error:

    `
    DHTSensor:41: error: no matching function for call to 'DHT::DHT()'
    DHT dht;
    ^
    D:\Arduino\DHTSensor\DHTSensor.ino:41:5: note: candidates are:
    In file included from D:\Arduino\DHTSensor\DHTSensor.ino:12:0:
    C:\Users\Robert\Documents\Arduino\libraries\DHT_sensor_library/DHT.h:40:4: note: DHT::DHT(uint8_t, uint8_t, uint8_t)
    DHT(uint8_t pin, uint8_t type, uint8_t count=6);
    ^
    C:\Users\Robert\Documents\Arduino\libraries\DHT_sensor_library/DHT.h:40:4: note: candidate expects 3 arguments, 0 provided
    C:\Users\Robert\Documents\Arduino\libraries\DHT_sensor_library/DHT.h:38:7: note: constexpr DHT::DHT(const DHT&)
    class DHT {
    ^
    C:\Users\Robert\Documents\Arduino\libraries\DHT_sensor_library/DHT.h:38:7: note: candidate expects 1 argument, 0 provided
    C:\Users\Robert\Documents\Arduino\libraries\DHT_sensor_library/DHT.h:38:7: note: constexpr DHT::DHT(DHT&&)
    C:\Users\Robert\Documents\Arduino\libraries\DHT_sensor_library/DHT.h:38:7: note: candidate expects 1 argument, 0 provided
    D:\Arduino\DHTSensor\DHTSensor.ino: In function 'void setup()':
    DHTSensor:59: error: 'class DHT' has no member named 'setup'
    dht.setup(DHT_DATA_PIN); // set data pin of DHT sensor
    ^
    DHTSensor:60: error: 'class DHT' has no member named 'getMinimumSamplingPeriod'
    if (UPDATE_INTERVAL <= dht.getMinimumSamplingPeriod()) {
    ^
    DHTSensor:65: error: 'class DHT' has no member named 'getMinimumSamplingPeriod'
    sleep(dht.getMinimumSamplingPeriod());
    ^
    D:\Arduino\DHTSensor\DHTSensor.ino: In function 'void loop()':
    DHTSensor:72: error: 'class DHT' has no member named 'readSensor'
    dht.readSensor(true);
    ^
    DHTSensor:75: error: 'class DHT' has no member named 'getTemperature'
    float temperature = dht.getTemperature();
    ^
    DHTSensor:82: error: 'class DHT' has no member named 'toFahrenheit'
    temperature = dht.toFahrenheit(temperature);
    ^
    DHTSensor:99: error: 'class DHT' has no member named 'getHumidity'
    float humidity = dht.getHumidity();
    ^
    exit status 1
    no matching function for call to 'DHT::DHT()'

    Please help!!!

    1 Reply Last reply
    0
    • sundberg84S Offline
      sundberg84S Offline
      sundberg84
      Hardware Contributor
      wrote on last edited by
      #2

      It really looks like it cant find the DHT library... or you have the wrong lib installed.
      Open the dht.cpp file in notepad and see if you find the functions like getTemperature() and so on.

      Controller: Proxmox VM - Home Assistant
      MySensors GW: Arduino Uno - W5100 Ethernet, Gw Shield Nrf24l01+ 2,4Ghz
      MySensors GW: Arduino Uno - Gw Shield RFM69, 433mhz
      RFLink GW - Arduino Mega + RFLink Shield, 433mhz

      1 Reply Last reply
      0
      • robertmtR Offline
        robertmtR Offline
        robertmt
        wrote on last edited by
        #3

        Can't see getTemperature in dht.cpp. There is "readTemperature", "readHumidity" etc... but nothing like "get"

        sundberg84S 1 Reply Last reply
        0
        • robertmtR robertmt

          Can't see getTemperature in dht.cpp. There is "readTemperature", "readHumidity" etc... but nothing like "get"

          sundberg84S Offline
          sundberg84S Offline
          sundberg84
          Hardware Contributor
          wrote on last edited by
          #4

          @robertmt - then you are using the wrong DHTlib.
          Download it from Mysensors github and use the example sketch and it will work:
          https://github.com/mysensors/MySensorsArduinoExamples

          there is a getTemperature() in this lib.

          Controller: Proxmox VM - Home Assistant
          MySensors GW: Arduino Uno - W5100 Ethernet, Gw Shield Nrf24l01+ 2,4Ghz
          MySensors GW: Arduino Uno - Gw Shield RFM69, 433mhz
          RFLink GW - Arduino Mega + RFLink Shield, 433mhz

          1 Reply Last reply
          0
          • robertmtR Offline
            robertmtR Offline
            robertmt
            wrote on last edited by
            #5

            Thanks... it helped a bit. No more DHT error... but now:

            avr-g++: error: CreateProcess: No such file or directory
            exit status 1
            Error compiling for board Arduino/Genuino Uno.
            Invalid version found: 1.04
            Invalid version found: 1.04

            1 Reply Last reply
            0
            • robertmtR Offline
              robertmtR Offline
              robertmt
              wrote on last edited by
              #6

              I'm lost....

              I've installed Arduino ver 1.6.6 than I had an error :+1:
              avr-g++: error: missing filename after '-o'

              removed everything and installed ver. 1.6.12 ... libraries from github:
              https://github.com/mysensors/MySensors
              https://github.com/mysensors/MySensorsArduinoExamples

              everything inside:
              C:\Users\Robert\Documents\Arduino\libraries\MySensors

              now error:
              C:\Users\Robert\Documents\Arduino\libraries\MySensors\examples\DhtTemperatureAndHumiditySensor\DhtTemperatureAndHumiditySensor.ino:44:17: fatal error: DHT.h: No such file or directory
              #include <DHT.h>
              ^
              compilation terminated.
              exit status 1
              Error compiling for board Arduino/Genuino Uno.

              1 Reply Last reply
              0
              • robertmtR Offline
                robertmtR Offline
                robertmt
                wrote on last edited by
                #7

                hello again:

                my latest trial gave me something like this:

                avr-g++: error: CreateProcess: No such file or directory
                exit status 1
                Error compiling for board Arduino/Genuino Uno.
                Invalid version found: 1.04

                anyone???

                1 Reply Last reply
                0
                • robertmtR Offline
                  robertmtR Offline
                  robertmt
                  wrote on last edited by
                  #8

                  Ok... Looks like issue was with windows and some SH...T in AppData and Temp...
                  Removed everything related with arduino and maneged to upload a sketch.
                  (Maybe somebody else will have a same issue)

                  Only one thing left, this:
                  Invalid version found: 1.04
                  Any idea what can it be? My Arduino IDE is 1.6.12 on Windows 7.

                  Thanks in advance

                  clio75C 1 Reply Last reply
                  0
                  • robertmtR robertmt

                    Ok... Looks like issue was with windows and some SH...T in AppData and Temp...
                    Removed everything related with arduino and maneged to upload a sketch.
                    (Maybe somebody else will have a same issue)

                    Only one thing left, this:
                    Invalid version found: 1.04
                    Any idea what can it be? My Arduino IDE is 1.6.12 on Windows 7.

                    Thanks in advance

                    clio75C Offline
                    clio75C Offline
                    clio75
                    wrote on last edited by
                    #9

                    @robertmt Yes I have similar problems :/
                    But have not had the time to look into this yet.
                    Hopefully later today (or maybe closer to the weekend)

                    1 Reply Last reply
                    0
                    Reply
                    • Reply as topic
                    Log in to reply
                    • Oldest to Newest
                    • Newest to Oldest
                    • Most Votes


                    18

                    Online

                    11.7k

                    Users

                    11.2k

                    Topics

                    113.0k

                    Posts


                    Copyright 2025 TBD   |   Forum Guidelines   |   Privacy Policy   |   Terms of Service
                    • Login

                    • Don't have an account? Register

                    • Login or register to search.
                    • First post
                      Last post
                    0
                    • MySensors
                    • OpenHardware.io
                    • Categories
                    • Recent
                    • Tags
                    • Popular