Error with libraries

Hellos, first of all thank you and sorry for my noobness on C++.

I’m doing a proyect with some DHT22 sensors, using the DHTlib from github (the one is recommended on this page). Everithing was right, placed on the lib folder and working perfectly for 5 months.

Suddenly, last week this library stops working. It reports:

In file included from ______

c:___\Arduino\libraries\arduino-DHT-master/DHT.h:38:1: error: expected ‘,’ or ‘;’ before ‘class’

class DHT{

^

Utilizando biblioteca arduino-DHT-master en carpeta:
C:____\Arduino\libraries\arduino-DHT-master (legacy)
exit status 1
Error compilación en tarjeta Arduino/Genuino Uno.

I’ve tried some libraries (this error is from another library), using the code as it need (changing the variable declaration and correcting the errors), but the error was excatly the same.

Also I tried to put some ‘,’ or ‘;’ just where it says it should be, but I think is not needed for a class declaration (for what I’ve seen in other libraries)

I assume the error had to be in the IDE, but had download different versions…but none works.

I attach some of this libraries, and dont post the code cos the error shows it compiles fine in everithing else.

Any idea what is going on? Thank you.

DHTlib.zip (27.4 KB)

CarlosCT: using the DHTlib from github

CarlosCT: Utilizando biblioteca arduino-DHT-master en carpeta: C:____\Arduino\libraries\arduino-DHT-master (legacy)

You say you're using DHTlib but the output shows it's actually arduino-DHT-master which is not included in the attached zip file. If you want further help with this you really need to provide a set of clear steps for how we can reproduce the error instead of just throwing a bunch of random libraries at us.

Sorry, I’ve tried 2 many lib already, but the error is the same on all (once I correct the rest of differences on the lib functions). I attach now on the zip this lib.

bty: I work on a Windows 7, but had also tried in Ubuntu (on this same PC), but it replies same error :(:(:frowning:

DHTlib.zip (70.3 KB)

I just did the following:

  • Install arduino-DHT-master from your zip file.
  • File > Examples > arduino-DHT-master > DHT_Test
  • Tools > Board > Arduino/Genuino Uno
  • Sketch > Verify/Compile

This completes without errors for me using either Arduino IDE 1.6.8 or 1.6.5-r5. Note that having DHT-sensor-library-master installed at the same time as arduino-DHT-master will cause the sketch not to compile because the wrong file is included. Please try the above steps and report your results with the full output if you encounter an error(click the Copy error messages button on the right side of the orange bar and paste here using code tags(</> button)).