16 lines
273 B
Python
16 lines
273 B
Python
from machine import Pin
|
|
import src.server as server
|
|
import src.slave as slave
|
|
import src.wireless as wireless
|
|
import src.data as data
|
|
|
|
|
|
wireless.espnow_setup()
|
|
|
|
if data.master:
|
|
server.start()
|
|
Pin(2, Pin.OUT).value(1)
|
|
else:
|
|
slave.loop(Pin(2, Pin.OUT).value(1))
|
|
|