Browse Source

Connect to wifi and run server on boot

master
Elis Hirwing 2 years ago
parent
commit
06a265f3ac
Signed by: etu GPG Key ID: D57EFA625C9A925F
  1. 1
      Makefile
  2. 16
      src/boot.py

1
Makefile

@ -1,6 +1,7 @@
DEVICE := /dev/ttyUSB3
copy:
ampy --port $(DEVICE) put src/boot.py
ampy --port $(DEVICE) put src/csms12.py
ampy --port $(DEVICE) put src/main.py

16
src/boot.py

@ -0,0 +1,16 @@
# Original file:
# This file is executed on every boot (including wake-boot from deepsleep)
#import esp
#esp.osdebug(None)
import uos, machine
#uos.dupterm(None, 1) # disable REPL on UART(0)
import gc
#import webrepl
#webrepl.start()
gc.collect()
# My additions:
import main
main.connect()
main.server()
Loading…
Cancel
Save