The wireless outlets use a very trivial protocol. We grabbed some codes from the rfoutlet project. After converting the codes into binary, and some trial and error, the pattern becomes apparent.
The protocol is a 20bit "identifier" followed by the ON / OFF code (0011 / 1100, respectively). The outlets can learn from either an ON or an OFF code. Each code is paired with its significant other automagically.
So, for example, the lowest code pair that works is:
000000000000000000010011 (ON Code) (19) 000000000000000000011100 (OFF Code) (28)The largest being:
111111111111111111111100 (OFF Code) (16777212) 111111111111111111110011 (ON Code) (16777203)
We tested this with rfoutlet's codesend.cpp, using a pulsewidth of 189.
- The codes are passed as an argument in decimal, while the outlets are in "Learning Mode".
- The outlets can be put in "Learning Mode" by holding down the button on the side until the red light starts blinking (about 3 secs).
- The code needs to be sent while the light is blinking ( > 10 sec window).
- The light will blink rapidly and the outlet will go into OFF mode after it has learned the code.
Discussions
Become a Hackaday.io Member
Create an account to leave a comment. Already have an account? Log In.