Skip to content

Commit

Permalink
Remove Tuning: for speech module's workaround
Browse files Browse the repository at this point in the history
  • Loading branch information
MichelleRos committed Jul 14, 2024
1 parent c5a8f69 commit 79ea883
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions libraries/AP_Quicktune/AP_Quicktune.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ void AP_Quicktune::update(){
slew_steps = slew_steps - 1;
logger->WriteStreaming("QUIK","TimeUS,SRate,Gain,Param,ParamNo", "QffNI", AP_HAL::micros64(), get_slew_rate(axis), P, get_param_name(slew_parm), int(slew_parm));
if (slew_steps == 0){
GCS_SEND_TEXT(MAV_SEVERITY_INFO, "Tuning: %s %.4f", get_param_name(slew_parm), P);
GCS_SEND_TEXT(MAV_SEVERITY_INFO, "%s %.4f", get_param_name(slew_parm), P);
slew_parm = param_s::END;
if (get_current_axis() == axis_names::DONE){
GCS_SEND_TEXT(MAV_SEVERITY_NOTICE, "Tuning: DONE");
Expand Down Expand Up @@ -203,7 +203,7 @@ void AP_Quicktune::update(){
}

if (!item_in_bitmask(uint8_t(axis), filters_done)){
GCS_SEND_TEXT(MAV_SEVERITY_INFO, "Tuning: Starting %s tune", get_axis_name(axis));
GCS_SEND_TEXT(MAV_SEVERITY_INFO, "Starting %s tune", get_axis_name(axis));
setup_filters(axis);
}

Expand Down Expand Up @@ -231,7 +231,7 @@ void AP_Quicktune::update(){
param_s P_name = param_s(uint8_t(pname)-2); //from D to P
float old_P = get_param_value(P_name);;
float new_P = old_P * ratio;
GCS_SEND_TEXT(MAV_SEVERITY_INFO, "Tuning: Adjusting %s %.3f -> %.3f", get_param_name(P_name), old_P, new_P);
GCS_SEND_TEXT(MAV_SEVERITY_INFO, "Adjusting %s %.3f -> %.3f", get_param_name(P_name), old_P, new_P);
adjust_gain_limited(P_name, new_P);
}
// Set up slew gain
Expand All @@ -253,7 +253,7 @@ void AP_Quicktune::update(){
logger->WriteStreaming("QUIK","TimeUS,SRate,Gain,Param,ParamNo", "QffNI", AP_HAL::micros64(), srate, P, get_param_name(pname), int(pname));
if (get_time() - last_gain_report > 3){
last_gain_report = get_time();
GCS_SEND_TEXT(MAV_SEVERITY_INFO, "Tuning: %s %.4f sr:%.2f", get_param_name(pname), new_gain, srate);
GCS_SEND_TEXT(MAV_SEVERITY_INFO, "%s %.4f sr:%.2f", get_param_name(pname), new_gain, srate);
}
}
}
Expand Down Expand Up @@ -377,7 +377,7 @@ float AP_Quicktune::limit_gain(AP_Quicktune::param_s param, float value)
float reduction_pct = 100.0 * (saved_value - value) / saved_value;
if (reduction_pct > max_reduce){
float new_value = saved_value * (100 - max_reduce) * 0.01;
GCS_SEND_TEXT(MAV_SEVERITY_INFO, "Tuning: Limiting %s %.3f -> %.3f", get_param_name(param), value, new_value);
GCS_SEND_TEXT(MAV_SEVERITY_INFO, "Limiting %s %.3f -> %.3f", get_param_name(param), value, new_value);
value = new_value;
}
}
Expand Down

0 comments on commit 79ea883

Please sign in to comment.