Hi everyone. I’ve been looking into the SoftAP code the last days wondering if it could be tweaked to do more than just the AP connection setup.
My actual question is, can I access the digital IOs of the ARM core from the broadcom side by adding new JSONCommand classes handling that sort of requests and how would I do that?
@elTo, the intent is to open SoftAP to the user code so it can be used for more. At present, SoftAP is activated in listen mode. The goal is to have it available in non-listening mode as well. I’m not sure when this feature is schedule to be deployed.
I’ve had the SoftAP serving me my customised web pages and I have also been able to switch D7 on and off, flash the on-board RGB LED, rebooted it, displayed free memory in a web page, etc, from code actioned by specific URLs so presume you can do quite a lot more while in that mode. My code is a heavily-modified version of the Particle example.
What I did was enable the SYSTEM thread and then set a flag (int loopaction) from within the SoftAP web server page handler based on the URL requested. The flag is checked within loop(). Don’t do anything in the page handler that takes any significant time because it blocks the HTTP response, hence why I used a flag. My loop() contains a long switch statement. Extract below:
@peekay123, what I like to see is the possibility to create a standalone connectable device with a web interface. One could imagine that it works like the sign in pages of hotspot solution that pop up just after connecting. on the web page then you could interact with whatever that device is capable.
My actual project is to modify a coffee machine so you could connect to it by WiFi and by a press on the appropriate button on the web page it starts making coffee or cappuccino.