Sending a message between HTML and python on the raspberry pi
Maybe you can try to create a nodejs script that create a websocket.
You ca connect to the websocket with python and so, you are able to send data from your website to nodejs and from nodejs to python in real-time.
Have a nice day
I want to do the following. I want to have a button on a HTML page that once It gets pressed a message is sent to some python script I'm running.
For example, once the button is pressed some boolean will turn true, we will call the boolean bool_1. Then that boolean is sent to my python code, or written to a text file. Then in my python code I want to do something depending on that value. Is there a way to do this? Ive been looking at many thing but they haven't worked. I know that in javascript you can't write a text files because of security issues. My python code is constantly running, computing live values from sensors.