[Dev Log] Knock : Part 1

So I got my stuff on a Sunday. UPS really outdid themselves and awesome packaging my Digikey. Now I know who I am going to be ordering my stuff from, all the time. Interestingly Amazon is late. I understand not many people want eval boards for christmas. Anyway time to get onto the architecture.

Let's start off with a diagram/mind map.

So, the piezo is connected to the controller and the controller is connected to the server over an FTDI cable. The clients are connected to the network and so is the server. So, I am gonna have a Flask server listening to the clients' requests and whenever the request is made the server checks if there is any change in the incoming data.

I can see some potential problem though. Since the client is gonna poll the server, there are gonna be a lot of requests. The requests are gonna land up in a certain window of time that may or may not coincide with the time data is incoming on the Serial port. So, the data window has to be extended. This implies the data coming from the controller has to be padded with the last known value. However, this is just off the top of my head, I'll have to look into that and optimize it further.

Eventually what I'll have to do is figure out some way to make sure the whole system is event/interrupt based. It will work in the other direction then. Instead of the client polling the server, the server will contact the client. But that's high level stuff. Later on that part.