I have gone through the demos and had no trouble connecting to mDash with my esp32 board. I have now written a simple C app but I have been unable to get mDash to see my device. However the logsseem to show success:
mos config-set dash.enable=true device.id=device5 dash.token=redacted
The dashboard just reports “never connected” for the device. I am using a free account so only 3 devices, and I have created and deleted more than that. Currently I have only one device, but could the problem be that I created too many?
Which makes me thing my wifi config is setting the wifi up as an access point instead of a client, and therefore not talking to the cloud. On my phone, I see it listed as an AP. Can it be both an AP and client simultaneously?
From searching, I can’t figure out how to configure it as a station vs an AP.
UPDATE:
I think I figured that out:
mos config-set wifi.sta.enable=true wifi.sta.ssid='Jim LAN' wifi.sta.pass=password
Gives me:
[Oct 3 15:11:00.997] mgos_wifi.c:136 WiFi STA: Connected, BSSID 44:94:fc:61:24:f0 ch 1 RSSI -47
[Oct 3 15:11:01.004] mgos_event.c:135 ev WFI2 triggered 0 handlers
[Oct 3 15:11:01.009] mgos_net.c:89 WiFi STA: connected
[Oct 3 15:11:01.017] mgos_event.c:135 ev NET2 triggered 2 handlers
[Oct 3 15:11:02.233] e[0;32mI (3958) event: sta ip: 192.168.1.23, mask: 255.255.255.0, gw: 192.168.1.1e[0m
[Oct 3 15:11:02.240] mgos_event.c:135 ev WFI3 triggered 0 handlers
[Oct 3 15:11:02.248] mgos_net.c:101 WiFi STA: ready, IP 192.168.1.23, GW 192.168.1.1, DNS 192.168.1.1
[Oct 3 15:11:02.252] mgos_sntp.c:127 SNTP next query in 1017 ms
[Oct 3 15:11:02.258] mgos_event.c:135 ev NET3 triggered 2 handlers
[Oct 3 15:11:03.277] mg_net.c:928 0x3ffbae44 udp://time.google.com:123 -,-,-
[Oct 3 15:11:03.283] mg_net.c:928 0x3ffbaf80 udp://192.168.1.1:53 -,-,-
[Oct 3 15:11:03.289] mg_net.c:796 0x3ffbaf80 udp://192.168.1.1:53
[Oct 3 15:11:03.289] mgos_sntp.c:95 SNTP query to time.google.com
[Oct 3 15:11:03.295] mgos_sntp.c:127 SNTP next query in 2042 ms
[Oct 3 15:11:03.302] mg_net.c:811 0x3ffbaf80 udp://192.168.1.1:53 -> 0
[Oct 3 15:11:03.319] mg_net.c:796 0x3ffbae44 udp://216.239.35.0:123
[Oct 3 15:11:03.319] mg_net.c:811 0x3ffbae44 udp://216.239.35.0:123 -> 0
[Oct 3 15:11:03.325] mgos_sntp.c:48 SNTP sent query to 216.239.35.0
[Oct 3 15:11:03.383] mgos_sntp.c:59 SNTP reply from 216.239.35.0: time 1570129863.770411, local 54.407325, delta 1570129809.363086
[Oct 3 15:11:03.389] mgos_event.c:135 ev MOS3 triggered 2 handlers
[Oct 3 15:11:03.395] mgos_sntp.c:78 SNTP close