Force auto tune
This commit is contained in:
@@ -260,6 +260,7 @@ std::unordered_map<std::string, uint32_t> keys = {
|
|||||||
{"ExperimentalModeViaLKAS", PERSISTENT},
|
{"ExperimentalModeViaLKAS", PERSISTENT},
|
||||||
{"ExperimentalModeViaScreen", PERSISTENT},
|
{"ExperimentalModeViaScreen", PERSISTENT},
|
||||||
{"FireTheBabysitter", PERSISTENT},
|
{"FireTheBabysitter", PERSISTENT},
|
||||||
|
{"ForceAutoTune", PERSISTENT},
|
||||||
{"FrogPilotTogglesUpdated", PERSISTENT},
|
{"FrogPilotTogglesUpdated", PERSISTENT},
|
||||||
{"FrogsGoMoo", PERSISTENT},
|
{"FrogsGoMoo", PERSISTENT},
|
||||||
{"GoatScream", PERSISTENT},
|
{"GoatScream", PERSISTENT},
|
||||||
|
|||||||
@@ -677,7 +677,7 @@ class Controls:
|
|||||||
# Update Torque Params
|
# Update Torque Params
|
||||||
if self.CP.lateralTuning.which() == 'torque':
|
if self.CP.lateralTuning.which() == 'torque':
|
||||||
torque_params = self.sm['liveTorqueParameters']
|
torque_params = self.sm['liveTorqueParameters']
|
||||||
if self.sm.all_checks(['liveTorqueParameters']) and torque_params.useParams:
|
if self.sm.all_checks(['liveTorqueParameters']) and (torque_params.useParams or self.force_auto_tune):
|
||||||
self.LaC.update_live_torque_params(torque_params.latAccelFactorFiltered, torque_params.latAccelOffsetFiltered,
|
self.LaC.update_live_torque_params(torque_params.latAccelFactorFiltered, torque_params.latAccelOffsetFiltered,
|
||||||
torque_params.frictionCoefficientFiltered)
|
torque_params.frictionCoefficientFiltered)
|
||||||
|
|
||||||
@@ -1028,6 +1028,7 @@ class Controls:
|
|||||||
self.frogpilot_variables.experimental_mode_via_lkas = experimental_mode_activation and self.params.get_bool("ExperimentalModeViaLKAS")
|
self.frogpilot_variables.experimental_mode_via_lkas = experimental_mode_activation and self.params.get_bool("ExperimentalModeViaLKAS")
|
||||||
|
|
||||||
lateral_tune = self.params.get_bool("LateralTune")
|
lateral_tune = self.params.get_bool("LateralTune")
|
||||||
|
self.force_auto_tune = lateral_tune and self.params.get_float("ForceAutoTune")
|
||||||
|
|
||||||
longitudinal_tune = self.params.get_bool("LongitudinalTune")
|
longitudinal_tune = self.params.get_bool("LongitudinalTune")
|
||||||
self.frogpilot_variables.sport_plus = longitudinal_tune and self.params.get_int("AccelerationProfile") == 3
|
self.frogpilot_variables.sport_plus = longitudinal_tune and self.params.get_int("AccelerationProfile") == 3
|
||||||
|
|||||||
@@ -25,6 +25,7 @@ FrogPilotControlsPanel::FrogPilotControlsPanel(SettingsWindow *parent) : FrogPil
|
|||||||
{"NoUploads", "Disable Uploads", "Turn off all data uploads to comma's servers.\n\nWARNING: This action will prevent your drives from appearing on comma connect which may impact debugging and support!", ""},
|
{"NoUploads", "Disable Uploads", "Turn off all data uploads to comma's servers.\n\nWARNING: This action will prevent your drives from appearing on comma connect which may impact debugging and support!", ""},
|
||||||
|
|
||||||
{"LateralTune", "Lateral Tuning", "Modify openpilot's steering behavior.", "../frogpilot/assets/toggle_icons/icon_lateral_tune.png"},
|
{"LateralTune", "Lateral Tuning", "Modify openpilot's steering behavior.", "../frogpilot/assets/toggle_icons/icon_lateral_tune.png"},
|
||||||
|
{"ForceAutoTune", "Force Auto Tune", "Forces comma's auto lateral tuning for unsupported vehicles.", ""},
|
||||||
|
|
||||||
{"LongitudinalTune", "Longitudinal Tuning", "Modify openpilot's acceleration and braking behavior.", "../frogpilot/assets/toggle_icons/icon_longitudinal_tune.png"},
|
{"LongitudinalTune", "Longitudinal Tuning", "Modify openpilot's acceleration and braking behavior.", "../frogpilot/assets/toggle_icons/icon_longitudinal_tune.png"},
|
||||||
{"AccelerationProfile", "Acceleration Profile", "Change the acceleration rate to be either sporty or eco-friendly.", ""},
|
{"AccelerationProfile", "Acceleration Profile", "Change the acceleration rate to be either sporty or eco-friendly.", ""},
|
||||||
|
|||||||
@@ -39,7 +39,7 @@ private:
|
|||||||
std::set<QString> experimentalModeActivationKeys = {"ExperimentalModeViaDistance", "ExperimentalModeViaLKAS", "ExperimentalModeViaScreen"};
|
std::set<QString> experimentalModeActivationKeys = {"ExperimentalModeViaDistance", "ExperimentalModeViaLKAS", "ExperimentalModeViaScreen"};
|
||||||
std::set<QString> fireTheBabysitterKeys = {"NoLogging", "MuteOverheated", "NoUploads"};
|
std::set<QString> fireTheBabysitterKeys = {"NoLogging", "MuteOverheated", "NoUploads"};
|
||||||
std::set<QString> laneChangeKeys = {};
|
std::set<QString> laneChangeKeys = {};
|
||||||
std::set<QString> lateralTuneKeys = {};
|
std::set<QString> lateralTuneKeys = {"ForceAutoTune"};
|
||||||
std::set<QString> longitudinalTuneKeys = {"AccelerationProfile", "DecelerationProfile", "AggressiveAcceleration"};
|
std::set<QString> longitudinalTuneKeys = {"AccelerationProfile", "DecelerationProfile", "AggressiveAcceleration"};
|
||||||
std::set<QString> mtscKeys = {};
|
std::set<QString> mtscKeys = {};
|
||||||
std::set<QString> qolKeys = {"DisableOnroadUploads"};
|
std::set<QString> qolKeys = {"DisableOnroadUploads"};
|
||||||
|
|||||||
Reference in New Issue
Block a user