mirror of
https://github.com/firestar5683/StarPilot.git
synced 2026-09-28 18:33:45 +08:00
ui: remove GPS status from the sidebar (#33304)
* Remove usage of llk in ui * Remove GPS from sidebar * Remove it from test old-commit-hash: c61d504516158d1e9926cf09625bbfc87aba9664
This commit is contained in:
@@ -382,6 +382,7 @@ class Controls:
|
||||
|
||||
# TODO: fix simulator
|
||||
if not SIMULATION or REPLAY:
|
||||
# Not show in first 1.5 km to allow for driving out of garage. This event shows after 5 minutes
|
||||
gps_ok = self.sm.recv_frame[self.gps_location_service] > 0 and (self.sm.frame - self.sm.recv_frame[self.gps_location_service]) * DT_CTRL < 2.0
|
||||
if not gps_ok and self.sm['livePose'].inputsOK and (self.distance_traveled > 1500):
|
||||
self.events.add(EventName.noGps)
|
||||
|
||||
@@ -102,8 +102,6 @@ void Sidebar::updateState(const UIState &s) {
|
||||
ItemStatus pandaStatus = {{tr("VEHICLE"), tr("ONLINE")}, good_color};
|
||||
if (s.scene.pandaType == cereal::PandaState::PandaType::UNKNOWN) {
|
||||
pandaStatus = {{tr("NO"), tr("PANDA")}, danger_color};
|
||||
} else if (s.scene.started && !sm["liveLocationKalman"].getLiveLocationKalman().getGpsOK()) {
|
||||
pandaStatus = {{tr("GPS"), tr("SEARCH")}, warning_color};
|
||||
}
|
||||
setProperty("pandaStatus", QVariant::fromValue(pandaStatus));
|
||||
}
|
||||
|
||||
@@ -116,7 +116,7 @@ class TestUI:
|
||||
|
||||
def setup(self):
|
||||
self.sm = SubMaster(["uiDebug"])
|
||||
self.pm = PubMaster(["deviceState", "pandaStates", "controlsState", 'roadCameraState', 'wideRoadCameraState', 'liveLocationKalman'])
|
||||
self.pm = PubMaster(["deviceState", "pandaStates", "controlsState", 'roadCameraState', 'wideRoadCameraState'])
|
||||
while not self.sm.valid["uiDebug"]:
|
||||
self.sm.update(1)
|
||||
time.sleep(UI_DELAY) # wait a bit more for the UI to start rendering
|
||||
|
||||
@@ -779,14 +779,6 @@ This may take up to a minute.</source>
|
||||
<source>PANDA</source>
|
||||
<translation>PANDA</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>GPS</source>
|
||||
<translation>GPS</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>SEARCH</source>
|
||||
<translation>بحث</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>--</source>
|
||||
<translation>--</translation>
|
||||
|
||||
@@ -762,14 +762,6 @@ This may take up to a minute.</source>
|
||||
<source>PANDA</source>
|
||||
<translation>PANDA</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>GPS</source>
|
||||
<translation>GPS</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>SEARCH</source>
|
||||
<translation>SUCHEN</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>--</source>
|
||||
<translation>--</translation>
|
||||
|
||||
@@ -763,14 +763,6 @@ Esto puede tardar un minuto.</translation>
|
||||
<source>PANDA</source>
|
||||
<translation>PANDA</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>GPS</source>
|
||||
<translation>GPS</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>SEARCH</source>
|
||||
<translation>BÚSQUEDA</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>--</source>
|
||||
<translation>--</translation>
|
||||
|
||||
@@ -763,14 +763,6 @@ Cela peut prendre jusqu'à une minute.</translation>
|
||||
<source>PANDA</source>
|
||||
<translation>PANDA</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>GPS</source>
|
||||
<translation>GPS</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>SEARCH</source>
|
||||
<translation>RECHERCHE</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>--</source>
|
||||
<translation>--</translation>
|
||||
|
||||
@@ -757,14 +757,6 @@ This may take up to a minute.</source>
|
||||
<source>PANDA</source>
|
||||
<translation>PANDA</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>GPS</source>
|
||||
<translation>GPS</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>SEARCH</source>
|
||||
<translation>検索</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>--</source>
|
||||
<translation>--</translation>
|
||||
|
||||
@@ -759,14 +759,6 @@ This may take up to a minute.</source>
|
||||
<source>PANDA</source>
|
||||
<translation>PANDA</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>GPS</source>
|
||||
<translation>GPS</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>SEARCH</source>
|
||||
<translation>검색중</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>--</source>
|
||||
<translation>--</translation>
|
||||
|
||||
@@ -763,14 +763,6 @@ Isso pode levar até um minuto.</translation>
|
||||
<source>PANDA</source>
|
||||
<translation>PANDA</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>GPS</source>
|
||||
<translation>GPS</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>SEARCH</source>
|
||||
<translation>PROCURA</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>--</source>
|
||||
<translation>--</translation>
|
||||
|
||||
@@ -759,14 +759,6 @@ This may take up to a minute.</source>
|
||||
<source>PANDA</source>
|
||||
<translation>PANDA</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>GPS</source>
|
||||
<translation>จีพีเอส</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>SEARCH</source>
|
||||
<translation>ค้นหา</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>--</source>
|
||||
<translation>--</translation>
|
||||
|
||||
@@ -757,14 +757,6 @@ This may take up to a minute.</source>
|
||||
<source>PANDA</source>
|
||||
<translation>PANDA</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>GPS</source>
|
||||
<translation>GPS</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>SEARCH</source>
|
||||
<translation>ARA</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>--</source>
|
||||
<translation>--</translation>
|
||||
|
||||
@@ -759,14 +759,6 @@ This may take up to a minute.</source>
|
||||
<source>PANDA</source>
|
||||
<translation>PANDA</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>GPS</source>
|
||||
<translation>GPS</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>SEARCH</source>
|
||||
<translation>搜索中</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>--</source>
|
||||
<translation>--</translation>
|
||||
|
||||
@@ -759,14 +759,6 @@ This may take up to a minute.</source>
|
||||
<source>PANDA</source>
|
||||
<translation>車輛通訊</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>GPS</source>
|
||||
<translation>GPS</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>SEARCH</source>
|
||||
<translation>車輛通訊</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>--</source>
|
||||
<translation>--</translation>
|
||||
|
||||
+1
-1
@@ -242,7 +242,7 @@ void UIState::updateStatus() {
|
||||
UIState::UIState(QObject *parent) : QObject(parent) {
|
||||
sm = std::make_unique<SubMaster, const std::initializer_list<const char *>>({
|
||||
"modelV2", "controlsState", "liveCalibration", "radarState", "deviceState",
|
||||
"pandaStates", "carParams", "driverMonitoringState", "carState", "liveLocationKalman", "driverStateV2",
|
||||
"pandaStates", "carParams", "driverMonitoringState", "carState", "driverStateV2",
|
||||
"wideRoadCameraState", "managerState", "clocks",
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user