Browse Source

Disable AP on boot

master
Elis Hirwing 1 year ago
parent
commit
45dc9fbbb9
Signed by: etu <elis@hirwing.se> GPG Key ID: D57EFA625C9A925F
2 changed files with 4 additions and 0 deletions
  1. +1
    -0
      src/boot.py
  2. +3
    -0
      src/main.py

+ 1
- 0
src/boot.py View File

@@ -12,5 +12,6 @@ gc.collect()
# My additions:
import main

main.disableAP()
main.connect()
main.server()

+ 3
- 0
src/main.py View File

@@ -25,6 +25,9 @@ def connect():

print('network config:', sta_if.ifconfig())

def disableAP():
ap_if = network.WLAN(network.AP_IF)
ap_if.active(False)

def server():
addr = socket.getaddrinfo('0.0.0.0', 80)[0][-1]


Loading…
Cancel
Save