From 98fa6b5d8ba57e2edf102ae6e97f90764f2c7ac9 Mon Sep 17 00:00:00 2001 From: "J. Nick Koston" Date: Mon, 5 Jun 2023 19:16:11 -0500 Subject: [PATCH] fix --- components/ratgdo/ratgdo.cpp | 57 +++++++++++++++++++----------------- 1 file changed, 30 insertions(+), 27 deletions(-) diff --git a/components/ratgdo/ratgdo.cpp b/components/ratgdo/ratgdo.cpp index 1100721..aeef48e 100644 --- a/components/ratgdo/ratgdo.cpp +++ b/components/ratgdo/ratgdo.cpp @@ -185,33 +185,36 @@ namespace ratgdo { uint64_t fixed = 0; uint32_t data = 0; - if (strcmp(command, "reboot1") == 0) { - fixed = 0x400000000; - data = 0x0000618b; - } else if (strcmp(command, "reboot2") == 0) { - fixed = 0; - data = 0x01009080; - } else if (strcmp(command, "reboot3") == 0) { - fixed = 0; - data = 0x0000b1a0; - } else if (strcmp(command, "reboot4") == 0) { - fixed = 0; - data = 0x01009080; - } else if (strcmp(command, "reboot5") == 0) { - fixed = 0x300000000; - data = 0x00008092; - } else if (strcmp(command, "reboot6") == 0) { - fixed = 0x300000000; - data = 0x00008092; - } else if (strcmp(command, "door1") == 0) { - fixed = 0x200000000; - data = 0x01018280; - } else if (strcmp(command, "door2") == 0) { - fixed = 0x200000000; - data = 0x01009280; - } else if (strcmp(command, "light") == 0) { - fixed = 0x200000000; - data = 0x00009281; + if(strcmp(command,"reboot1") == 0){ + fixed = 0x400000000; + data = 0x0000618b; + }else if(strcmp(command,"reboot2") == 0){ + fixed = 0; + data = 0x01009080; + }else if(strcmp(command,"reboot3") == 0){ + fixed = 0; + data = 0x0000b1a0; + }else if(strcmp(command,"reboot4") == 0){ + fixed = 0; + data = 0x01009080; + }else if(strcmp(command,"reboot5") == 0){ + fixed = 0x300000000; + data = 0x00008092; + }else if(strcmp(command,"reboot6") == 0){ + fixed = 0x300000000; + data = 0x00008092; + }else if(strcmp(command,"door1") == 0){ + fixed = 0x200000000; + data = 0x01018280; + }else if(strcmp(command,"door2") == 0){ + fixed = 0x200000000; + data = 0x01009280; + }else if(strcmp(command,"light") == 0){ + fixed = 0x200000000; + data = 0x00009281; + }else if(strcmp(command,"lock") == 0){ + fixed = 0x0100000000; + data = 0x0000728c; } else { ESP_LOGD(TAG, "ERROR: Invalid command"); return;