Changing Wi-Fi Over USB

I know it is possible to erase the Wi-Fi credentials by holding mode, but is it possible to change over USB when it already has credentials it is attempting to use?

My use case is that it is enclosed with only the USB port exposed. I bring the device to another location with different Wi-Fi credentials and it would be far easier in my case to plug in USB, connect to the device, and update the credentials instead of holding mode. It sits blinking green (trying to connect), but doesn’t appear as a USB port so I can’t connect to update.

Thanks. :slight_smile:

Hi @choosatron,

I think you could have some code watching serial over usb and listening for a “start smart config mode” command definitely. Checkout “SPARK_WLAN_STARTED”, and “Start_Smart_Config” in main.cpp, and spark_wlan.cpp in the firmware – https://github.com/spark/core-firmware/blob/master/src/main.cpp#L258 and https://github.com/spark/core-firmware/blob/master/src/spark_wlan.cpp#L116

Hope that helps! Note - this is definitely possible in the firmware, just depends on how much stuff would need to be tweaked. Might be as simple as setting a single constant. :slight_smile:

Thanks,
David