I have a lot of boards and usually need to re-use code even for different projects.
cube 3d5d7ea51b Update 'CARDPUTER CircuitPython/wifi_switcher/code.py' vor 1 Monat
..
code.py Update 'CARDPUTER CircuitPython/wifi_switcher/code.py' vor 1 Monat
readme.md Add 'CARDPUTER CircuitPython/wifi_switcher/readme.md' vor 1 Monat
settings.toml sample settings.toml vor 1 Monat

readme.md

set up

  • write ssid and password pairs in settings.toml, the variable names dont matter at all
  • put those variable names into the "wifi options" list in code.py
  • don't need to touch the rest of the code, and you can add more items or delete items from the list, the menu screen will adjust accordingly

to do / notes

  • esc button bypasses any need to connect to wifi - although maybe dont include this in offline projects :P
  • since you can choose, this makes cardputer basically portable since i can turn on hotspot