Skip to content

Commit

Permalink
Merge pull request #2104 from iNavFlight/MrD_Consolidate-the-old-`Pro…
Browse files Browse the repository at this point in the history
…file`-and-`PID-Profile`-in-to-`Control-Profile`
  • Loading branch information
MrD-RC authored Jun 6, 2024
2 parents e65f412 + 58f3d57 commit c491658
Show file tree
Hide file tree
Showing 6 changed files with 28 additions and 21 deletions.
20 changes: 10 additions & 10 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -95,16 +95,6 @@ <h1 class="modal__title modal__title" data-i18n="appUpdateNotificationHeader"></
<div class="legend" i18n="sensorDataFlashFreeSpace"></div>
</li>
</ul>
<div id="mixer_profile_change">
<div class="dropdown dropdown-dark">
<form name="mixer-profile-change" id="mixer-profile-change">
<select class="dropdown-select" id="mixerprofilechange">
<option value="0" i18n="mixerProfile1"></option>
<option value="1" i18n="mixerProfile2"></option>
</select>
</form>
</div>
</div>
<div id="profile_change">
<div class="dropdown dropdown-dark">
<form name="profile-change" id="profile-change">
Expand All @@ -117,6 +107,16 @@ <h1 class="modal__title modal__title" data-i18n="appUpdateNotificationHeader"></
</form>
</div>
</div>
<div id="mixer_profile_change">
<div class="dropdown dropdown-dark">
<form name="mixer-profile-change" id="mixer-profile-change">
<select class="dropdown-select" id="mixerprofilechange">
<option value="0" i18n="mixerProfile1"></option>
<option value="1" i18n="mixerProfile2"></option>
</select>
</form>
</div>
</div>
<div id="battery_profile_change">
<div class="dropdown dropdown-dark">
<form name="battery-profile-change" id="battery-profile-change">
Expand Down
4 changes: 2 additions & 2 deletions js/logicConditionOperantTypes.js
Original file line number Diff line number Diff line change
Expand Up @@ -53,13 +53,13 @@ const OPERAND_TYPES = {
30: "CRSF SNR",
31: "GPS Valid Fix",
32: "Loiter Radius [cm]",
33: "Active PID Profile",
33: "Active Control Profile",
34: "Battery cells",
35: "AGL status [0/1]",
36: "AGL [cm]",
37: "Rangefinder [cm]",
38: "Active Mixer Profile",
39: "MixerTransition Active",
39: "Mixer Transition Active",
40: "Yaw [deg]",
41: "FW Land State",
42: "Active Battery Profile",
Expand Down
9 changes: 8 additions & 1 deletion js/logicConditionOperators.js
Original file line number Diff line number Diff line change
Expand Up @@ -242,14 +242,21 @@ const LOGIC_OPERATORS = {
output: "boolean"
},

39: {
name: "Set Heading Target",
operandType: "Set Flight Parameter",
hasOperand: [true, false],
output: "raw"
},

41: {
name: "Override Loiter Radius",
operandType: "Set Flight Parameter",
hasOperand: [true, false],
output: "boolean"
},
42: {
name: "Set Profile",
name: "Set Control Profile",
operandType: "Set Flight Parameter",
hasOperand: [true, false],
output: "boolean"
Expand Down
2 changes: 1 addition & 1 deletion js/msp/MSPHelper.js
Original file line number Diff line number Diff line change
Expand Up @@ -1319,7 +1319,7 @@ var mspHelper = (function () {
console.log('Looptime saved');
break;
case MSPCodes.MSP_SET_RESET_CURR_PID:
console.log('Current PID profile reset');
console.log('Current Control profile reset');
break;
case MSPCodes.MSP_SET_3D:
console.log('3D settings saved');
Expand Down
10 changes: 5 additions & 5 deletions locale/en/messages.json
Original file line number Diff line number Diff line change
Expand Up @@ -5132,10 +5132,10 @@
"message": "Enable if the motor direction is reversed and the props are mounted in the opposite direction."
},
"mixer_pid_profile_linking": {
"message": "PID Profile will use same index as Mixer Profile index"
"message": "Control Profile will use same index as Mixer Profile index"
},
"mixer_pid_profile_linking_hint": {
"message": "mixer_pid_profile_linking: Enable on both Mixer Profile if you want PID Profile switching handled by Mixer Profile switching(Recommend in vtol/mixed plaform type setup)"
"message": "mixer_pid_profile_linking: Enable on both Mixer Profile if you want Control Profile switching handled by Mixer Profile switching(Recommend in vtol/mixed plaform type setup)"
},
"blackboxFields": {
"message": "Blackbox fields"
Expand Down Expand Up @@ -5459,13 +5459,13 @@
"message": "Mixer Profile 2"
},
"sensorProfile1": {
"message": "PID Profile 1"
"message": "Control Profile 1"
},
"sensorProfile2": {
"message": "PID Profile 2"
"message": "Control Profile 2"
},
"sensorProfile3": {
"message": "PID Profile 3"
"message": "Control Profile 3"
},
"sensorBatteryProfile1": {
"message": "Battery Profile 1"
Expand Down
4 changes: 2 additions & 2 deletions src/css/main.css
Original file line number Diff line number Diff line change
Expand Up @@ -1700,7 +1700,7 @@ dialog {

}

#mixer_profile_change {
#profile_change {
color: white;
margin-top: 16px;
width: 130px;
Expand All @@ -1709,7 +1709,7 @@ dialog {
line-height: 12px;
}

#profile_change {
#mixer_profile_change {
color: white;
margin-top: 16px;
width: 130px;
Expand Down

0 comments on commit c491658

Please sign in to comment.