
So you also don’t need to put your credentials. What I like is that anyone can control the Photon. The problem is that serving HTML, CSS and JavaScript (I’m not even talking about images) eats up a lot of memory space on your Photon. There are some implementations that serve a complete webpage from the Photon. The idea is to be able to directly control Photon by sending data over the local network. Rickkas7 has some code that does this better, with some modifications this might be a better and more stable alternative. It doesn’t manage client/server connections. In my experience the Webduino library is not always stable. I’ve removed the added delay and the communication speed changed to 15-20 milliseconds for one message.

I’ve found the cause the code, an added delay which was added to solve a bug on the Particle Core. My expectation was that it should be way faster. To my surprise it took 300 milliseconds to send a message on my local network almost the same time as it took when communicating over the Particle Cloud. Luckily there is the Webduino library. It makes use of the existing TCPServer and TCPClient functions on the Photon and adds the HTTP layer on top of that. I’ve forked and updated the library ported by Matthew McGowan, because I noticed that in the previous version communication was slowed-down because of some kind of bug in the Particle Core.

For the SoftAP configuration page this is already used, but that only works in Listen mode.

Maybe it will come a the near future, because WICED (the Broadcom SDK for the microchip on the Particle Photon) implements a HTTP server (Adafruit implemented this HTTP-API for their WICED feather WiFi). The idea is to run a small webserver on the Photon. Unfortunately there isn’t yet an HTTP server available in the Particle API.
