MCPcopy Create free account
hub / github.com/Moddable-OpenSource/moddable / apScan

Method apScan

contributed/modClock/main.js:709–721  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

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)

Callers

nothing calls this directly

Calls 3

doRestartFunction · 0.70
setMethod · 0.65
scanMethod · 0.45

Tested by

no test coverage detected