ping pong loop nearly working

This commit is contained in:
2026-05-15 12:09:41 +10:00
parent 9a072bacf9
commit 224709f913
3 changed files with 71 additions and 26 deletions

View File

@@ -1,11 +1,12 @@
from sx1262 import SX1262
from _sx126x import *
from connection import Connection
import time
import crypt_random
import uasyncio as asyncio
from lora_handler import LoRaHandler
LORA_ENABLED = True
BLUETOOTH_ENABLED = False
@@ -14,15 +15,9 @@ def main():
if BLUETOOTH_ENABLED:
from bluetooth_handler import BluetoothHandler
bluetooth_handler = BluetoothHandler()
lora_handler = None
if LORA_ENABLED:
lora_handler = LoRaHandler()
print("Ready!")
while True:
lora_handler.advertise()
time.sleep(5)
conn = Connection()
asyncio.run(conn.start())
if __name__ == "__main__":