peterhinch / micropython-mqtt

A 'resilient' asynchronous MQTT driver. Recovers from WiFi and broker outages.
MIT License
549 stars 116 forks source link

sense of red wifi LED is backwards w/r/t docs in range demo #143

Closed bikeNomad closed 1 week ago

bikeNomad commented 1 week ago

Love your code!

The range demo says that out-of-range will light the red LED, but in fact the red LED stays on until a failure.

ebolisa commented 1 week ago

Love your code!

The range demo says that out-of-range will light the red LED, but in fact the red LED stays on until a failure.

Not all dev boards are wired the same way. Perhaps you need to invert the command? Where it calls for ON, you send OFF.

peterhinch commented 1 week ago

@bikeNomad You are right, thanks for the report. The code comments don't match the code (also range_ex). I think it's best to have the LED work as currently, as a "WiFi UP" light. I'll amend the comments. [EDIT] Now done.