I'm using python to push every nth image from a scientific camera to a web page. The webpage updates the image using .replace()
. It's probably important to note that this is not a webcam - it's a scientific cam. I'm using the developer software to save an image to the server every n seconds, which is then grabbed by the client.
I'm using HTML, JavaScript, Jquery, and python.
I also have a bunch of web sockets (using socketio on the client side, and flask on the server side) such that when a button is clicked it emits a command to move a motor connected to the server. When this happens, the image stops updating until that emit function on the server is finished.
I have thought about using a background thread to push the image to the server every n seconds (based on user request for refresh rate), but not sure this would help at all... or where to start, really.
Thanks in advance.