wip
@@ -41,7 +41,7 @@ def create_steering_messages(packer, CP, CAN, enabled, lat_active, apply_steer):
|
||||
ret = []
|
||||
|
||||
values = {
|
||||
"LKA_MODE": 2, # CP: Whats this?
|
||||
"LKA_MODE": 2,
|
||||
"LKA_ICON": 2 if enabled else 1 if lat_active else 0, # right mode icon
|
||||
"TORQUE_REQUEST": apply_steer,
|
||||
"LKA_ASSIST": 0,
|
||||
@@ -137,7 +137,8 @@ def create_lfahda_cluster(packer, CAN, enabled, lat_active):
|
||||
# 0 off, 1 gray, 2 green, 3 blinking (wheel icon)
|
||||
# CP: Is this actually the wheel? Might this be the HDA2 thing?
|
||||
"HDA_ICON": 0, # Intention is to have this represent stock HDA mode
|
||||
"LFA_ICON": 0 if no_lat_lane_change else 2 if enabled else 1 if lat_active else 0,
|
||||
"LFA_ICON": 0,
|
||||
# "LFA_ICON": 0 if no_lat_lane_change else 2 if enabled else 1 if lat_active else 0,
|
||||
}
|
||||
|
||||
return packer.make_can_msg("LFAHDA_CLUSTER", CAN.ECAN, values)
|
||||
|
||||
|
Before Width: | Height: | Size: 117 KiB After Width: | Height: | Size: 1.4 KiB |
BIN
selfdrive/clearpilot/theme/clearpilot/images/boot_logo.png~
Normal file
|
After Width: | Height: | Size: 35 KiB |
|
Before Width: | Height: | Size: 47 KiB After Width: | Height: | Size: 1.6 KiB |
|
Before Width: | Height: | Size: 47 KiB After Width: | Height: | Size: 1.5 KiB |
|
Before Width: | Height: | Size: 51 KiB After Width: | Height: | Size: 24 KiB |
|
After Width: | Height: | Size: 117 KiB |
|
After Width: | Height: | Size: 47 KiB |
|
After Width: | Height: | Size: 49 KiB |
|
After Width: | Height: | Size: 47 KiB |
|
After Width: | Height: | Size: 49 KiB |
|
Before Width: | Height: | Size: 1.8 KiB After Width: | Height: | Size: 1.8 KiB |
BIN
selfdrive/clearpilot/theme/clearpilot_release/images/ready.png
Normal file
|
After Width: | Height: | Size: 51 KiB |
BIN
selfdrive/clearpilot/theme/clearpilot_release/images/ready.png~
Normal file
|
After Width: | Height: | Size: 53 KiB |
|
Before Width: | Height: | Size: 4.7 KiB After Width: | Height: | Size: 4.7 KiB |
|
Before Width: | Height: | Size: 4.7 KiB After Width: | Height: | Size: 4.7 KiB |
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 44 KiB After Width: | Height: | Size: 44 KiB |
|
Before Width: | Height: | Size: 12 KiB After Width: | Height: | Size: 12 KiB |
|
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 10 KiB |
BIN
selfdrive/clearpilot/theme/pacman_dev/images/button_settings.png
Normal file
|
After Width: | Height: | Size: 1.8 KiB |
|
Before Width: | Height: | Size: 24 KiB After Width: | Height: | Size: 24 KiB |
BIN
selfdrive/clearpilot/theme/pacman_dev/images/turn_signal_1.png
Normal file
|
After Width: | Height: | Size: 4.7 KiB |
BIN
selfdrive/clearpilot/theme/pacman_dev/images/turn_signal_1.png~
Normal file
|
After Width: | Height: | Size: 4.7 KiB |
|
After Width: | Height: | Size: 1.1 KiB |
BIN
selfdrive/clearpilot/theme/pacman_dev/images/turn_signal_2.png
Normal file
|
After Width: | Height: | Size: 1.1 KiB |
BIN
selfdrive/clearpilot/theme/pacman_dev/images/turn_signal_3.png
Normal file
|
After Width: | Height: | Size: 1.1 KiB |
BIN
selfdrive/clearpilot/theme/pacman_dev/images/turn_signal_4.png
Normal file
|
After Width: | Height: | Size: 1.1 KiB |
BIN
selfdrive/clearpilot/theme/pacman_dev/sounds/disengage.wav
Normal file
BIN
selfdrive/clearpilot/theme/pacman_dev/sounds/engage.wav
Normal file
BIN
selfdrive/clearpilot/theme/pacman_dev/sounds/firefox.wav
Normal file
BIN
selfdrive/clearpilot/theme/pacman_dev/sounds/prompt.wav
Normal file
BIN
selfdrive/clearpilot/theme/pacman_dev/sounds/refuse.wav
Normal file
BIN
selfdrive/clearpilot/theme/pacman_dev/sounds/warning_soft.wav
Normal file
@@ -568,19 +568,23 @@ EVENTS: dict[int, dict[str, Alert | AlertCallbackType]] = {
|
||||
ET.WARNING: below_steer_speed_alert,
|
||||
},
|
||||
|
||||
# Clearpilot - move this to status bar only on lane_change_suspend_lat
|
||||
# restore small size on other modes
|
||||
EventName.preLaneChangeLeft: {
|
||||
ET.WARNING: Alert(
|
||||
"Steer Left to Start Lane Change Once Safe",
|
||||
"",
|
||||
AlertStatus.normal, AlertSize.small,
|
||||
AlertStatus.normal, AlertSize.none,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.none, .1, alert_rate=0.75),
|
||||
},
|
||||
|
||||
# Clearpilot - move this to status bar only on lane_change_suspend_lat
|
||||
# restore small size on other modes
|
||||
EventName.preLaneChangeRight: {
|
||||
ET.WARNING: Alert(
|
||||
"Steer Right to Start Lane Change Once Safe",
|
||||
"",
|
||||
AlertStatus.normal, AlertSize.small,
|
||||
AlertStatus.normal, AlertSize.none,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.none, .1, alert_rate=0.75),
|
||||
},
|
||||
|
||||
@@ -592,11 +596,12 @@ EVENTS: dict[int, dict[str, Alert | AlertCallbackType]] = {
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.prompt, .1),
|
||||
},
|
||||
|
||||
# Clearpilot - move this to status bar only on lane_change_suspend_lat
|
||||
EventName.laneChange: {
|
||||
ET.WARNING: Alert(
|
||||
"Changing Lanes",
|
||||
"",
|
||||
AlertStatus.normal, AlertSize.small,
|
||||
AlertStatus.normal, AlertSize.none,
|
||||
Priority.LOW, VisualAlert.none, AudibleAlert.none, .1),
|
||||
},
|
||||
|
||||
|
||||
@@ -98,6 +98,11 @@ void OnroadWindow::updateState(const UIState &s) {
|
||||
}
|
||||
|
||||
QColor bgColor = bg_colors[s.status];
|
||||
// Clearpilot
|
||||
if (paramsMemory.getInt("no_lat_lane_change") == 1) {
|
||||
bg = bg_colors[STATUS_DISENGAGED];
|
||||
}
|
||||
|
||||
Alert alert = Alert::get(*(s.sm), s.scene.started_frame);
|
||||
alerts->updateAlert(alert);
|
||||
|
||||
@@ -109,11 +114,6 @@ void OnroadWindow::updateState(const UIState &s) {
|
||||
|
||||
nvg->updateState(s);
|
||||
|
||||
// Clearpilot
|
||||
if (paramsMemory.getInt("no_lat_lane_change") == 1) {
|
||||
bg = bg_colors[STATUS_DISENGAGED];
|
||||
}
|
||||
|
||||
if (bg != bgColor) {
|
||||
// repaint border
|
||||
bg = bgColor;
|
||||
@@ -899,29 +899,25 @@ void AnnotatedCameraWidget::drawLaneLines(QPainter &painter, const UIState *s) {
|
||||
painter.setBrush(path_gradient);
|
||||
painter.drawPolygon(scene.track_vertices);
|
||||
|
||||
// Paint path edges
|
||||
// don't paint if not engaged color
|
||||
// if (bg != bg_colors[STATUS_DISENGAGED]) {
|
||||
// Use current background color
|
||||
// Paint path edges ,Use current background color
|
||||
QColor bgColor = bg_colors[uiState().status];
|
||||
// Clearpilot
|
||||
if (paramsMemory.getInt("no_lat_lane_change") == 1) {
|
||||
bgColor = bg_colors[STATUS_DISENGAGED];
|
||||
}
|
||||
if (bgColor != bg_colors[STATUS_DISENGAGED]) {
|
||||
QLinearGradient edge_gradient;
|
||||
// QColor test_color = QColor(201, 41, 204, 0xd1);
|
||||
QColor test_color;
|
||||
test_color = bg;
|
||||
// edge_gradient.setColorAt(0.0, QColor(test_color.red(), test_color.green(), test_color.blue(), static_cast<int>(OTHER_LANE_ALPHA * 255)));
|
||||
// edge_gradient.setColorAt(0.5, QColor(test_color.red(), test_color.green(), test_color.blue(), static_cast<int>(OTHER_LANE_ALPHA * 255 * 0.5)));
|
||||
// edge_gradient.setColorAt(1.0, QColor(test_color.red(), test_color.green(), test_color.blue(), static_cast<int>(OTHER_LANE_ALPHA * 255 * 0.1)));
|
||||
edge_gradient.setColorAt(0.0, QColor(bg.red(), bg.green(), bg.blue(), static_cast<int>(255)));
|
||||
edge_gradient.setColorAt(0.5, QColor(bg.red(), bg.green(), bg.blue(), static_cast<int>(255 * 0.7) ));
|
||||
edge_gradient.setColorAt(1.0, QColor(bg.red(), bg.green(), bg.blue(), static_cast<int>(255 * 0.5)));
|
||||
edge_gradient.setColorAt(0.0, QColor(bgColor.red(), bgColor.green(), bgColor.blue(), static_cast<int>(255)));
|
||||
edge_gradient.setColorAt(0.5, QColor(bgColor.red(), bgColor.green(), bgColor.blue(), static_cast<int>(255 * 0.7) ));
|
||||
edge_gradient.setColorAt(1.0, QColor(bgColor.red(), bgColor.green(), bg.blue(), static_cast<int>(255 * 0.5)));
|
||||
|
||||
QPainterPath path;
|
||||
path.addPolygon(scene.track_vertices);
|
||||
path.addPolygon(scene.track_edge_vertices);
|
||||
|
||||
// painter.setBrush(path_gradient);
|
||||
painter.setBrush(edge_gradient);
|
||||
painter.drawPath(path);
|
||||
// }
|
||||
}
|
||||
|
||||
// Paint blindspot path
|
||||
if (scene.blind_spot_path) {
|
||||
|
||||