Class for DHT11, DHT21 and DHT22 (temperature & humidity)

Just a few questions while checking both DHT versions:

Rob:

  • Has a delay of 20msec for both DHT11 and DHT22.
  • Uses a counter in the while to break out of the while in case the pin does not change

Mark:

  • Has a delay of 18msec for the DHT11 and 800usec for the DHT22.
  • Uses an endless while loop, so if the pin does not change --> Arduino in endless loop!

Further:

  • I am using multiple DHT22's on different pins. Which library would be most RAM efficient?
  • Is the 800usec the right delay for the DHT22? If so, it saves me 5*19msec = 75msec of doing nothing, which is a lot using NilRTOS/ChibiOS RTOSses...

Please comment 8)