config.py 465 B

123456789101112131415161718
  1. import ubinascii
  2. import machine
  3. # Default MQTT server to connect to
  4. MQTT_SERVER = "192.168.1.1"
  5. CLIENT_ID = ubinascii.hexlify(machine.unique_id())
  6. TOPIC_SUB = b"Room/rgbBulb/1/command"
  7. TOPIC_PUB = b"Room/rgbBulb/1/state"
  8. #LEDs with name, pin, channel and default value
  9. LED_LIST = [
  10. ('R', machine.Pin.PA_05, 0, 100),
  11. ('G', machine.Pin.PB_13, 1, 1),
  12. ('B', machine.Pin.PB_15, 3, 1),
  13. ('C', machine.Pin.PB_16, 2, 1),
  14. ('W', machine.Pin.PB_08, 4, 100)
  15. ]