diff --git a/components/ratgdo/ratgdo.cpp b/components/ratgdo/ratgdo.cpp index a7ab774..5f2bd21 100644 --- a/components/ratgdo/ratgdo.cpp +++ b/components/ratgdo/ratgdo.cpp @@ -18,6 +18,22 @@ namespace esphome { namespace ratgdo { static const char *const TAG = "ratgdo"; +/*** Static Codes ***/ +static const byte SYNC1[] = {0x55, 0x01, 0x00, 0x61, 0x12, 0x49, 0x2c, 0x92, 0x5b, 0x24, + 0x96, 0x86, 0x0b, 0x65, 0x96, 0xd9, 0x8f, 0x26, 0x4a}; +static const byte SYNC2[] = {0x55, 0x01, 0x00, 0x08, 0x34, 0x93, 0x49, 0xb4, 0x92, 0x4d, + 0x20, 0x26, 0x1b, 0x4d, 0xb4, 0xdb, 0xad, 0x76, 0x93}; +static const byte SYNC3[] = {0x55, 0x01, 0x00, 0x06, 0x1b, 0x2c, 0xbf, 0x4b, 0x6d, 0xb6, + 0x4b, 0x18, 0x20, 0x92, 0x09, 0x20, 0xf2, 0x11, 0x2c}; +static const byte SYNC4[] = {0x55, 0x01, 0x00, 0x95, 0x29, 0x36, 0x91, 0x29, 0x36, 0x9a, + 0x69, 0x05, 0x2f, 0xbe, 0xdf, 0x6d, 0x16, 0xcb, 0xe7}; +static const byte *SYNC_CODE[] = {SYNC1, SYNC2, SYNC3, SYNC4}; + +static const byte DOOR_CODE[] = {0x55, 0x01, 0x00, 0x94, 0x3f, 0xef, 0xbc, 0xfb, 0x7f, 0xbe, + 0xfc, 0xa6, 0x1a, 0x4d, 0xa6, 0xda, 0x8d, 0x36, 0xb3}; + +static const byte LIGHT_CODE[] = {0x55, 0x01, 0x00, 0x94, 0x3f, 0xef, 0xbc, 0xfb, 0x7f, 0xbe, + 0xff, 0xa6, 0x1a, 0x4d, 0xa6, 0xda, 0x8d, 0x76, 0xb1}; void RATGDOComponent::setup() { this->pref_ = global_preferences->make_preference(this->get_object_id_hash());