()
| 707 | } |
| 708 | } |
| 709 | apScan() { |
| 710 | WiFi.scan({}, item => { |
| 711 | if (!item) { |
| 712 | Timer.set(() => this.apScan(), 60_000); |
| 713 | return; |
| 714 | } |
| 715 | |
| 716 | if (item.ssid !== this.prefs.ssid) |
| 717 | return; |
| 718 | |
| 719 | doRestart(this); // when the stored SSID appears, restart to try re-connecting |
| 720 | }); |
| 721 | } |
| 722 | |
| 723 | setupRtc() { |
| 724 | if (this.prefs.pin == 22 || this.prefs.pin == 21) |