
Minnow Server: Fast and embeddable websocket SSL server for microcontrollers - SEJeff
https://github.com/RealTimeLogic/MinnowServer
======
bjpirt
From personal experience: using WebSockets for realtime communication with a
microcontroller works really well. I've put together a number of products
using ESP8266 to do this and serving out the HTML/JS from an embedded web
server. Works particularly well for streaming out the state of sensors on the
device.

The main issue I had was that only HTTP was well supported on the
Arduino/ESP8266 platform and as we all know that's fallen out of favour.
Unfortunately, it also limits what you can do on resource constrained
microcontrollers. Having HTTPS in this library opens up the ability to build
an SPA which was something I'd always wanted to do.

I don't see any mention of ESP8266 on their site but hopefully, as probably
the most widely available IP enabled microcontroller, it will be supported
too. Time to do some more digging into getting it running.

edit: I obviously didn't look closely enough - there's recently been added
support for ESP8266 - happy days!

~~~
SEJeff
I _highly_ recommend pairing an esp8266 with a ATECC508A crypto chip for
serious tls stuff. It all works nicely with MongooseOS.

Edit: Looks like the MongooseOS team has even blogged about it (a few
different times). Here is an example: [https://mongoose-os.com/blog/mongoose-
esp8266-atecc508-aws/](https://mongoose-os.com/blog/mongoose-
esp8266-atecc508-aws/)

------
j1elo
I've read this README and linked pages, but my lack of experience with these
topics still prevents me from having a clear picture:

Would it be possible to port this for the Atmel (now Microchip) AVR32
architecture? I'm writing some code for the UC3C family and next thing to do
is write code to present a configuration page over an Ethernet port. I'm not
using a RTOS so my plan was to use lwIP directly, altough switching to
FreeRTOS would also be an option (as I'm currently writing code for other
boards and I've not really started writing any code for this specific,
Ethernet-enabled board).

Would appreciate any pointers of how to do this. Never had to implement TCP/IP
and HTTP before on a MCU, so it was a relief discovering that there are
already made and free to use implementations of these stacks :)

I'm also exploring alternative OSes such as Mongoose mentioned here. It seems
there is a lot of options. Having support for OTA updates could save a lot of
work too, because that's another planned feature.

~~~
syn0byte
Minnows README says it supports lwIP-raw. Atmel apparently also has their own
reference example of an lwIP HTTP server for AVR32.(Probably FreeRTOS based)

[http://ultimaserial.com/classroom2.html](http://ultimaserial.com/classroom2.html)

~~~
j1elo
Thanks. I understand from Minnow docs that first lwIp should be set up in the
MCU, and then Minnow can be set up _on top_ of it.

------
ptspts
Where is the SSL and crypto implementation in this project?

~~~
SEJeff
[https://github.com/RealTimeLogic/MinnowServer/blob/fa30b0d5b...](https://github.com/RealTimeLogic/MinnowServer/blob/fa30b0d5be3d7ce13c8f8263bdbbfe73f877e01b/example/src/main.c#L5-L9)

    
    
        The code can be used with or without a TLS stack. The code is tailored for the SharkSSL API and the code automatically uses the SharkSSL API if compiled together with a SharkSSL delivery. The code uses standard non secure connections if not using TLS.

