Quellcode durchsuchen

fix ble peripheral name

marek vor 1 Monat
Ursprung
Commit
1b69c6ccf3
1 geänderte Dateien mit 2 neuen und 1 gelöschten Zeilen
  1. 2 1
      main.py

+ 2 - 1
main.py

@@ -9,6 +9,7 @@ import struct
 import machine
 import bme280_float as bme280
 import ssd1306
+import config
 
 i2c = machine.I2C(0, sda=machine.Pin(0), scl=machine.Pin(1))
 bme = bme280.BME280(i2c=i2c)
@@ -94,7 +95,7 @@ async def peripheral_task():
         try:
             async with await aioble.advertise(
                 _ADV_INTERVAL_MS,
-                name="RPi-Pico",
+                name=config.ble_peripheral_name,
                 services=[_ENV_SENSE_UUID],
                 appearance=_ADV_APPEARANCE_GENERIC_THERMOMETER,
                 ) as connection: