[Python] How to have python code that dynamically updates a static HTML website every 30...

Discussão em 'Python' iniciado por Stack, Abril 14, 2025.

  1. Stack

    Stack Membro Participativo

    So I have a project that involves three Rasperri Pi's. (all running bookworm)

    Device 1 & 2 have a peice of Python code that runs and counts people walking past them (OpenCV and Rasperi-pi camera). They are on a network that has a firewall which only allows outbound communication and intranet communication.

    Device 3 Is a webserver, hosting a static Https page on a separate network.

    I'm wondering how to A: Have device 1 & 2 share some sort of variable between the two running scripts

    and B: Have Device 2 send this variable (or push) this variable to the Web Server on a seperate network.

    From our research, it seems that FLASK would be a good communication standard? I just wanted to double check, and maybe get some answers to how to utilize it?

    We've tried SFTP, JSON files, and also tried looking into python physically changing HTML code every 30 secs but that would mean the user would have to refresh the page :(

    Continue reading...

Compartilhe esta Página