Compiled on Mar.30,2024

This commit is contained in:
Comma Device
2024-03-30 12:48:45 +08:00
parent b17cfc684a
commit cd1ae986c2
30 changed files with 26 additions and 18 deletions
+1
View File
@@ -1,5 +1,6 @@
Version 0.9.6 (2024-02-27)
========================
* 新手指南汉化完成 (2024-03-30)
* 新增CSLC巡航辅助 (2024-03-26)
* 修正行车速度显示 (2024-03-19)
* 新增DA驾驶模型 (2024-03-18)
Binary file not shown.
+8 -2
View File
@@ -154,8 +154,14 @@ static void gm_rx_hook(const CANPacket_t *to_push) {
}
if ((addr == 0xC9) && ((gm_hw == GM_CAM) || (gm_hw == GM_SDGM))) {
acc_main_on = GET_BIT(to_push, 29U);
brake_pressed = GET_BIT(to_push, 40U);
// https://github.com/FrogAi/FrogPilot/pull/124
// acc_main_on = GET_BIT(to_push, 29U);
// brake_pressed = GET_BIT(to_push, 40U);
brake_pressed = GET_BIT(to_push, 40U) != 0U;
}
if (addr == 0xC9) {
acc_main_on = GET_BIT(to_push, 29U) != 0U;
}
if (addr == 0x1C4) {
Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 76 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 922 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 92 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 962 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 65 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 996 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 74 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 78 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 76 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 876 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 72 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 840 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 773 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 886 KiB

+2 -2
View File
@@ -544,7 +544,7 @@ class Controls:
self.events.add(EventName.paramsdTemporaryError)
# conservative HW alert. if the data or frequency are off, locationd will throw an error
if any((self.sm.frame - self.sm.recv_frame[s])*DT_CTRL > 10. for s in self.sensor_packets):
if any((self.sm.frame - self.sm.recv_frame[s])*DT_CTRL > 10. for s in self.sensor_packets) and self.random_events:
self.events.add(EventName.sensorDataInvalid)
if not REPLAY:
@@ -580,7 +580,7 @@ class Controls:
# TODO: fix simulator
if not SIMULATION or REPLAY:
# Not show in first 1 km to allow for driving out of garage. This event shows after 5 minutes
if not self.sm['liveLocationKalman'].gpsOK and self.sm['liveLocationKalman'].inputsOK and (self.distance_traveled > 1000):
if not self.sm['liveLocationKalman'].gpsOK and self.sm['liveLocationKalman'].inputsOK and (self.distance_traveled > 1000) and self.random_events:
self.events.add(EventName.noGps)
if self.sm['liveLocationKalman'].gpsOK:
self.distance_traveled = 0
+1 -1
View File
@@ -469,7 +469,7 @@ def get_all_toggle_values():
"MinSteerSpeedStandard", "MinSteerSpeedEngage",
"DashSpeedRatio1", "DashSpeedRatio2", "DashSpeedRatio3", "SetSpeedRatio1", "SetSpeedRatio2", "SetSpeedRatio3", "SpeedDecimal",
"FrogPilotDrives", "FrogPilotKilometers", "FrogPilotMinutes", "CarMake", "CarModel",
"DriverPrivacyProtection", "CSLCEnabled", "CalibrationCircle",
"DriverPrivacyProtectionFake", "CSLCEnabled", "CalibrationCycles",
]
toggle_values = {}
+5 -5
View File
@@ -65,7 +65,7 @@ class Calibrator:
# Read saved calibration
self.params = Params()
self.calibration_circle = max(1, self.params.get_int("CalibrationCircle"))
self.calibration_cycles = max(1, self.params.get_int("CalibrationCycles"))
calibration_params = self.params.get("CalibrationParams")
rpy_init = RPY_INIT
wide_from_device_euler = WIDE_FROM_DEVICE_EULER_INIT
@@ -145,7 +145,7 @@ class Calibrator:
else:
self.calib_spread = np.zeros(3)
if self.valid_blocks < (INPUTS_NEEDED * self.calibration_circle):
if self.valid_blocks < (INPUTS_NEEDED * self.calibration_cycles):
if self.cal_status == log.LiveCalibrationData.Status.recalibrating:
self.cal_status = log.LiveCalibrationData.Status.recalibrating
else:
@@ -193,7 +193,7 @@ class Calibrator:
else:
height_certain = True
certain_if_calib = (rpy_certain and height_certain) or (self.valid_blocks < (INPUTS_NEEDED * self.calibration_circle))
certain_if_calib = (rpy_certain and height_certain) or (self.valid_blocks < (INPUTS_NEEDED * self.calibration_cycles))
if not (straight_and_fast and certain_if_calib):
return None
@@ -237,14 +237,14 @@ class Calibrator:
liveCalibration = msg.liveCalibration
liveCalibration.validBlocks = self.valid_blocks
liveCalibration.calStatus = self.cal_status
liveCalibration.calPerc = min(100 * (self.valid_blocks * BLOCK_SIZE + self.idx) // (INPUTS_NEEDED * self.calibration_circle * BLOCK_SIZE), 100)
liveCalibration.calPerc = min(100 * (self.valid_blocks * BLOCK_SIZE + self.idx) // (INPUTS_NEEDED * self.calibration_cycles * BLOCK_SIZE), 100)
liveCalibration.rpyCalib = smooth_rpy.tolist()
liveCalibration.rpyCalibSpread = self.calib_spread.tolist()
liveCalibration.wideFromDeviceEuler = self.wide_from_device_euler.tolist()
liveCalibration.height = self.height.tolist()
if self.not_car:
liveCalibration.validBlocks = INPUTS_NEEDED * self.calibration_circle
liveCalibration.validBlocks = INPUTS_NEEDED * self.calibration_cycles
liveCalibration.calStatus = log.LiveCalibrationData.Status.calibrated
liveCalibration.calPerc = 100.
liveCalibration.rpyCalib = [0, 0, 0]
+5 -3
View File
@@ -138,10 +138,11 @@ def manager_init() -> None:
("DragonPilotTune", "0"),
("DriverCamera", "0"),
("DriverPrivacyProtection", "0"),
("DriverPrivacyProtectionFake", "0"),
("DriveStats", "1"),
("DynamicPathWidth", "0"),
("EngageVolume", "100"),
("EVTable", "1"),
("EVTable", "0"),
("ExperimentalModeActivation", "1"),
("ExperimentalModeViaDistance", "0"),
("ExperimentalModeViaLKAS", "0"),
@@ -149,7 +150,7 @@ def manager_init() -> None:
("Fahrenheit", "0"),
("FireTheBabysitter", "0"),
("ForceAutoTune", "0"),
("ForceFingerprint", "0"),
("ForceFingerprint", "1"),
("ForceMPHDashboard", "0"),
("FPSCounter", "0"),
("FrogPilotDrives", "0"),
@@ -282,7 +283,8 @@ def manager_init() -> None:
("SetSpeedRatio2", "1.055"),
("SetSpeedRatio3", "1.045"),
("SpeedDecimal", "0"),
("CalibrationCircle", "1"),
("CalibrationCycles", "1"),
("OnStarGPS", "0"),
]
if not PC:
default_params.append(("LastUpdateTime", datetime.datetime.utcnow().isoformat().encode('utf8')))
+1 -1
View File
@@ -11,7 +11,7 @@ def driverview(started: bool, params: Params, params_memory: Params, CP: car.Car
return started or params.get_bool("IsDriverViewEnabled")
def drivermonitor(started: bool, params: Params, params_memory: Params, CP: car.CarParams) -> bool:
return not params.get_bool("DriverPrivacyProtection") and (started or params.get_bool("IsDriverViewEnabled"))
return (not params.get_bool("DriverPrivacyProtection")) and (started or params.get_bool("IsDriverViewEnabled"))
def notcar(started: bool, params: Params, params_memory: Params, CP: car.CarParams) -> bool:
return started and CP.notCar
+3 -4
View File
@@ -327,10 +327,9 @@ def thermald_thread(end_event, hw_queue) -> None:
# TODO: this should move to TICI.initialize_hardware, but we currently can't import params there
if TICI:
if not os.path.isfile("/persist/comma/living-in-the-moment"):
# if not Path("/data/media").is_mount():
# set_offroad_alert_if_changed("Offroad_StorageMissing", True)
# else:
if Path("/data/media").is_mount():
if not Path("/data/media").is_mount() and params.get_bool("RandomEvents"):
set_offroad_alert_if_changed("Offroad_StorageMissing", True)
else:
# check for bad NVMe
try:
with open("/sys/block/nvme0n1/device/model") as f:
Binary file not shown.
BIN
View File
Binary file not shown.