Ver código fonte

explicitly set wifi mode on start - crash or reset during setup retains state

etisab 10 anos atrás
pai
commit
6ae2087953
1 arquivos alterados com 1 adições e 0 exclusões
  1. 1 0
      rebuild/main.lua

+ 1 - 0
rebuild/main.lua

@@ -92,6 +92,7 @@ function debounce(delay, func)
   end
 end
 
+wifi.setmode(wifi.STATION)
 handle_short_press = debounce(3000000, handle_short_press) --3 seconds
 gpio.mode(button_pin, gpio.INT, gpio.FLOAT)
 gpio.trig(button_pin, "both", debounce(50000, handle_button_flip)) --50 ms