mirror of
https://github.com/rstrouse/ESPSomfy-RTS.git
synced 2025-12-13 11:02:12 +01:00
Bug Fix Prog
* Added filter for prog frame #27 * Expanded link remote json buffer #25 * Display tilt position on edit shade screen
This commit is contained in:
parent
5a16977ea9
commit
1174bed558
5 changed files with 19 additions and 2 deletions
16
Somfy.cpp
16
Somfy.cpp
|
|
@ -1022,6 +1022,19 @@ void SomfyShade::processFrame(somfy_frame_t &frame, bool internal) {
|
|||
}
|
||||
break;
|
||||
case somfy_commands::StepUp:
|
||||
// With the step commands and integrated shades
|
||||
// the motor must tilt in the direction first then move
|
||||
// so we have to calculate the target with this in mind.
|
||||
if(this->tiltType == tilt_types::integrated) {
|
||||
// First check to see if the tilt is 0. If it is not then we need to tilt.
|
||||
if(this->currentTiltPos != 0.0f) {
|
||||
this->tiltTarget = max(0.0f, this->currentTiltPos - 0.5f);
|
||||
}
|
||||
else {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
if(!internal) {
|
||||
this->lastFrame.await = millis() + 200;
|
||||
}
|
||||
|
|
@ -1178,6 +1191,9 @@ void SomfyShade::sendCommand(somfy_commands cmd, uint8_t repeat) {
|
|||
this->tiltTarget = this->currentTiltPos;
|
||||
}
|
||||
}
|
||||
else {
|
||||
SomfyRemote::sendCommand(cmd, repeat);
|
||||
}
|
||||
}
|
||||
void SomfyShade::sendTiltCommand(somfy_commands cmd) {
|
||||
if(cmd == somfy_commands::Up) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue