alphaLongToggle=newParamControl("ExperimentalLongitudinalEnabled",tr("openpilot Longitudinal Control (Alpha)"),
QString("<b>%1</b><br><br>%2")
.arg(tr("WARNING: openpilot longitudinal control is in alpha for this car and will disable Automatic Emergency Braking (AEB)."))
.arg(tr("On this car, openpilot defaults to the car's built-in ACC instead of openpilot's longitudinal control. "
"Enable this to switch to openpilot longitudinal control. Enabling Experimental mode is recommended when enabling openpilot longitudinal control alpha.")),
"../assets/offroad/icon_speed_limit.png"
);
alphaLongToggle=newParamControl("ExperimentalLongitudinalEnabled",tr("openpilot Longitudinal Control (Alpha)"),"","../assets/offroad/icon_speed_limit.png");
.arg(tr("WARNING: openpilot longitudinal control is in alpha for this car and will disable Automatic Emergency Braking (AEB)."))
.arg(tr("On this car, openpilot defaults to the car's built-in ACC instead of openpilot's longitudinal control. "
"Enable this to switch to openpilot longitudinal control. Enabling Experimental mode is recommended when enabling openpilot longitudinal control alpha."));
alphaLongToggle->setDescription("<b>"+tr("openpilot longitudinal control may come in a future update.")+"</b>");
}else{
if(is_release){
params.remove("ExperimentalLongitudinalEnabled");
alphaLongToggle->setEnabled(false);
alphaLongToggle->setDescription("<b>"+tr("An alpha version of openpilot longitudinal control can be tested, along with Experimental mode, on non-release branches.")+"</b>");
}
}
// The car already have openpilot longitudinal control and the toggle not is necessary
if(CP.getOpenpilotLongitudinalControl()){
alphaLongToggle->setVisible(false);
}
alphaLongToggle->refresh();
}else{
alphaLongToggle->setDescription("<b>"+tr("openpilot longitudinal control may come in a future update.")+"</b>");