Initial commit: reocon camera dashboard project

This commit is contained in:
2026-06-09 22:34:39 +05:30
commit d4847579e6
14 changed files with 985 additions and 0 deletions
+30
View File
@@ -0,0 +1,30 @@
import sys
import logging
from reocon.cameras import get_camera_infos_df
from reocon.dashboard import app
logging.basicConfig(
level=logging.INFO,
format="%(asctime)s [%(levelname)s] %(message)s",
handlers=[logging.StreamHandler()]
)
logger = logging.getLogger(__name__)
def run_console():
logger.info("Running in console mode")
df = get_camera_infos_df()
print(df.to_string(index=False))
def run_web():
logger.info("Starting Flask web dashboard")
app.run(debug=True)
if __name__ == "__main__":
if len(sys.argv) > 1 and sys.argv[1] == "console":
run_console()
else:
run_web()