I don't get Libraries working... I know that if I use a Library, I need to copy the library file also to the Pico (e.g. via Thonny).
Currently, I'm trying to get the DHT sensor working... I saw that there is a default DHT Library included in Micropython: https://docs.micropython.org/en/latest/ ... l/dht.html
But how do I use this Library on the Pico?
if I'm using the default code from below, I get this error message
Code: Select all
import dht
import machine
d = dht.DHT11(machine.Pin(4))
d.measure()
d.temperature() # eg. 23 (°C)
d.humidity() # eg. 41 (% RH)
d = dht.DHT22(machine.Pin(4))
d.measure()
d.temperature() # eg. 23.6 (°C)
d.humidity() # eg. 41.3 (% RH)
So how to handle these standard Libraries on the Pico?
What about other Libraries e.g. Neopixel etc.
Thank you so mutch
Joe