You have to do it one character at a time, using “first letter” and “last letter”. For example (in the if/do/else block):
In C or Python code of course you’d just use sprintf() or the equivalent.
Are all three connectors on the Neo HEX 37 RGB LED Board Grove (2mm pitch) format?
Also, if your sketch has any code that uses Wifi, your device will disconnect from UIflow. It will not reconnect when your sketch is finished. To work around this I keep the M5Burner open; when you click on "configure" it will reset the device via USB. Even then, your device will not connect right away, so go down to the lower left corner of the UIFlow window and clock on "Reconnect".
"App Mode" and "Download" are most useful when you are done testing your code.
I tried calling machine.deepsleep(xxx) in UIFlow and all it did was lock up the device, so tightly that even the power/reset button did not work. It might work from other IDEs , if you could succeed in setting up all the interrupts before putting it to sleep.
@slartibartfast Hate to bump an old topic but this is a problem for me still. The "Original Network Function" blocks place the calls to the wlan class correctly but they don't actually work. This is UIFlow 1.9.6 now. It makes it impossible to use the program except in the coverage area of the SSID hard coded into the program.
For a workaround, you can manually relocate the call to doConnect inside the loop or function where you want it. You can save that, and when you upload the program to the device it seems to send the modified python.
@dave17 There are a few options avaiable to you in UIFlow, none of which I can help with because I have never used them in UIFlow. These are all in the "advanced" section:
@wsanders I got the program to run with lightsleep, but only in "Internet Mode" and not "App Mode". Battery life was no different with lightsleep than with wait, about 2 hr. (Wait is probably is just a call to lightsleep, just in a more organized manner.)
It appears that in 1.9.6 Wifi doesn't come back up after lightsleep, I seem to remember the above callback function worked in 1.9.5 even after lightsleep. Now it hangs.
Back to square one. I think the best way is to have two separate programs, one to sync the watch to NTP, and one to run the clock with the time from the RTC (so I can still use the watch outside of my home wifi network.)