From 3342c0b4ea5632201815a10dee35fc736f75b2b4 Mon Sep 17 00:00:00 2001
From: lucky lin <8618993@qq.com>
Date: Sun, 14 Apr 2024 21:39:56 +0800
Subject: [PATCH] dashcam
---
.../frogpilot/fleetmanager/fleet_manager.py | 21 +++++++++++++++++--
1 file changed, 19 insertions(+), 2 deletions(-)
diff --git a/selfdrive/frogpilot/fleetmanager/fleet_manager.py b/selfdrive/frogpilot/fleetmanager/fleet_manager.py
index fa8b39d3..4c28dbc8 100644
--- a/selfdrive/frogpilot/fleetmanager/fleet_manager.py
+++ b/selfdrive/frogpilot/fleetmanager/fleet_manager.py
@@ -84,15 +84,32 @@ def route(route):
links = ""
segments = ""
for segment in fleet.segments_in_route(route):
- links += ""+segment+" | qlog
"
+ links += ""+segment+"
"
+ links += "log files: ( qlog | rlog )
"
+ links += "raw videos: [ fcamera | ecamera | qcamera ]
"
segments += "'"+segment+"',"
return render_template("route.html", route=route, query_type=query_type, links=links, segments=segments, query_segment=query_segment)
@app.route("/qlog/")
def qlog_downlod_file(segment):
- # return send_from_directory("/data/media/0/realdata/", segment + "/qlog", as_attachment=True)
return send_file("/data/media/0/realdata/"+segment+"/qlog", as_attachment=True, download_name=segment+".qlog")
+@app.route("/rlog/")
+def rlog_downlod_file(segment):
+ return send_file("/data/media/0/realdata/"+segment+"/rlog", as_attachment=True, download_name=segment+".rlog")
+
+@app.route("/fcam/")
+def fcam_downlod_file(segment):
+ return send_file("/data/media/0/realdata/"+segment+"/fcamera.hevc", as_attachment=True, download_name=segment+"_fcamera.hevc")
+
+@app.route("/ecam/")
+def ecam_downlod_file(segment):
+ return send_file("/data/media/0/realdata/"+segment+"/ecamera.hevc", as_attachment=True, download_name=segment+"_ecamera.hevc")
+
+@app.route("/qcam/")
+def qcam_downlod_file(segment):
+ return send_file("/data/media/0/realdata/"+segment+"/qcamera.ts", as_attachment=True, download_name=segment+"_qcamera.ts")
+
@app.route("/footage/")
@app.route("/footage")
def footage():