diff --git a/.gitignore b/.gitignore index d11457f..5609aab 100644 --- a/.gitignore +++ b/.gitignore @@ -9,6 +9,7 @@ SomfyController.ino.esp32c3.bin SomfyController.ino.esp32s2.bin .vscode/ .pio/ +.claude/ data/ build/ coredump_report.txt diff --git a/src/Somfy.cpp b/src/Somfy.cpp index 30bf84a..5feb36d 100644 --- a/src/Somfy.cpp +++ b/src/Somfy.cpp @@ -156,9 +156,9 @@ void somfy_frame_t::decodeFrame(byte* frame) { this->proto = radio_proto::RTV; this->cmd = (somfy_commands)(this->encKey - 148); } - else if(this->encKey > 133) { + else if(this->encKey >= 133) { this->proto = radio_proto::RTW; - this->cmd = (somfy_commands)(this->encKey - 133); + this->cmd = this->encKey == 133 ? somfy_commands::My : (somfy_commands)(this->encKey - 133); } } else this->proto = radio_proto::RTS;