Skip to content

Commit dfd1449

Browse files
authored
Merge pull request #581 from doudar/parameter-alignment
parameter alignment
2 parents 77c5f21 + 8e3bccb commit dfd1449

File tree

4 files changed

+10
-8
lines changed

4 files changed

+10
-8
lines changed

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
5252
- Continue updating power metrics to other clients if one client disconnects.
5353
- Freed 19k of ram by consolidating tasks and using timers instead of delays.
5454
- Updated baud rate to 115200 to ensure compatibility with other ESP32 variants.
55+
- Added a final test to check if ERG mode has commanded a move in the proper direction.
56+
- Aligned the values between the config app and web interface.
5557
- Added ability to send target watts through the custom characteristic.
5658
- Added a final test to check if ERG mode has commanded a move in the proper direction.
5759

data/bluetoothscanner.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ <h2>
7676
<input type='button' onclick="clickStep(document.getElementById('powerCorrectionFactor'), this.value)"
7777
value="-">
7878
<input style="width:50%; position: relative; top: 5px; left: 0px;" type="range"
79-
id="powerCorrectionFactor" name="powerCorrectionFactor" value="1.00" min="0.5" max="2.5" step="0.01"
79+
id="powerCorrectionFactor" name="powerCorrectionFactor" value="1.00" min="0.4" max="2.5" step="0.01"
8080
class="slider1"
8181
onchange="updateSlider(this.value, document.getElementById('powerCorrectionFactorValue'))" />
8282
<input type='button' onclick="clickStep(document.getElementById('powerCorrectionFactor'), this.value)"

data/settings.html

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ <h2>
8585
</div>
8686
<input type='button' onclick="clickStep(document.getElementById('shiftStep'), this.value)" value="-">
8787
<input style="width:50%; position: relative; top: 5px;" type="range" id="shiftStep" name="shiftStep"
88-
min="50" max="6000" value="0" step="50" class="slider1"
88+
min="10" max="6000" value="0" step="50" class="slider1"
8989
onchange="updateSlider(this.value, document.getElementById('shiftStepValue'))" />
9090
<input type='button' onclick="clickStep(document.getElementById('shiftStep'), this.value)" value="+">
9191
</td>
@@ -131,7 +131,7 @@ <h2>
131131
<input type='button' onclick="clickStep(document.getElementById('ERGSensitivity'), this.value)"
132132
value="-">
133133
<input style="width:50%; position: relative; top: 5px;" type="range" id="ERGSensitivity"
134-
name="ERGSensitivity" value="1.0" min=".5" max="20" step=".1" class="slider1"
134+
name="ERGSensitivity" value="1.0" min=".1" max="20" step=".1" class="slider1"
135135
onchange="updateSlider(this.value, document.getElementById('ERGSensitivityValue'))" />
136136
<input type='button' onclick="clickStep(document.getElementById('ERGSensitivity'), this.value)"
137137
value="+">
@@ -191,7 +191,7 @@ <h2>
191191
</div>
192192
<input type='button' onclick="clickStep(document.getElementById('stepperPower'), this.value)" value="-">
193193
<input style="width:50%; position: relative; top: 5px;" type="range" id="stepperPower"
194-
name="stepperPower" min="500" max="2000" value="0" step="100" class="slider1"
194+
name="stepperPower" min="100" max="2000" value="0" step="100" class="slider1"
195195
onchange="updateSlider(this.value, document.getElementById('stepperPowerValue'))" />
196196
<input type='button' onclick="clickStep(document.getElementById('stepperPower'), this.value)" value="+">
197197
</td>

src/HTTP_Server_Basic.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -487,14 +487,14 @@ void HTTP_Server::settingsProcessor() {
487487
}
488488
if (!server.arg("shiftStep").isEmpty()) {
489489
uint64_t shiftStep = server.arg("shiftStep").toInt();
490-
if (shiftStep >= 50 && shiftStep <= 6000) {
490+
if (shiftStep >= 10 && shiftStep <= 6000) {
491491
userConfig->setShiftStep(shiftStep);
492492
}
493493
wasSettingsUpdate = true;
494494
}
495495
if (!server.arg("stepperPower").isEmpty()) {
496496
uint64_t stepperPower = server.arg("stepperPower").toInt();
497-
if (stepperPower >= 500 && stepperPower <= 2000) {
497+
if (stepperPower >= 100 && stepperPower <= 2000) {
498498
userConfig->setStepperPower(stepperPower);
499499
ss2k->updateStepperPower();
500500
}
@@ -513,7 +513,7 @@ void HTTP_Server::settingsProcessor() {
513513
}
514514
if (!server.arg("ERGSensitivity").isEmpty()) {
515515
float ERGSensitivity = server.arg("ERGSensitivity").toFloat();
516-
if (ERGSensitivity >= .5 && ERGSensitivity <= 20) {
516+
if (ERGSensitivity >= .1 && ERGSensitivity <= 20) {
517517
userConfig->setERGSensitivity(ERGSensitivity);
518518
}
519519
}
@@ -548,7 +548,7 @@ void HTTP_Server::settingsProcessor() {
548548
}
549549
if (!server.arg("inclineMultiplier").isEmpty()) {
550550
float inclineMultiplier = server.arg("inclineMultiplier").toFloat();
551-
if (inclineMultiplier >= 1 && inclineMultiplier <= 10) {
551+
if (inclineMultiplier >= 0 && inclineMultiplier <= 10) {
552552
userConfig->setInclineMultiplier(inclineMultiplier);
553553
}
554554
}

0 commit comments

Comments
 (0)