Closed jscrane closed 8 months ago
Have added infrastructure for this; however DHT doesn't work at 1MHz, using the default library. The reason is that the pulse-width is too narrow for that clock speed. See this thread.
From the datasheet, the sensor sends 40 bits of data in which 0s are encoded as a pulse-high 26-28uS wide, while a 1 is encoded as a pulse-high 70uS wide. From the thread, the resolution of micros()
is 64uS at 1MHz so polling is out.
Could use pin-change interrupts and direct reading of a higher-resolution timer (e.g., timer1).
Not worth doing this.
This will require a new patched optiboot. The current patch assumes the frequency is 8MHz.
See
optiboot/bootloaders/optiboot/Makefile.extras
.