WiFi LED controller protocol

Comparison and data for A) LEDENET Smart WiFi LED Controller 5 Channels and B) SUPERNIGHT WiFi Wireless LED Smart Controller

Both use the Magic Home WiFi app, or send it data directly on TCP port 5577 (more info on that below)

First the LEDENET unit, I prefer this one for a variety of reasons:
- completely silent operation even when dimming
- nice cross-fade when changing colors
- solid screw terminals for connections
- runs cool (advertised as 4Amp switching per channel)
- extra 4th and 5th channel intended for Warm White/Cool White LEDs but could also be used for relays, status light, nightlight, or otherwise
- internal WiFi module is marked HF-LPB100-1
- runs a webserver (u: admin p: nimda)
  Default IP: 10.10.123.3 (when broadcasting its own wireless SSID and not connected to your own wireless network)
  Note link at the very top right to make the page English
  HTTP page on mine indicates MID: HF-LPB100-ZJ200 and Software v1.0.06 and Web v1.0.14
Packaging label reads "X000ZYJ6KH LEDNET Smart WiFi Controller" and includes door screws and a reset button push-pin.

After sniffing out the network traffic, I learned that it continually tries to update the time from a NTP server located in China, this is likely for the timer functions to stay accurate, but disappointingly there is no way to change the NTP server to something else or disable it entirely. I really hope this is changed in a future firmware update, but since I don't need this I just block it at the firewall.




From the factory it will broadcast its own wireless SSID which you can connect to directly, there is also the much more useful option to have it connect to your own home router/AP's SSID. Here's what the traffic looks like between the smartphone app (on IP .50) and the WiFi controller (on IP .54)





And here is everything I captured...
For module labeled X000ZYJ6KH LEDNET Smart WiFi Controller

71 23 0f a3 on
71 24 0f a4 off

Note: you can send color commands regardless of it being on or off,
so that when turned on, it will immediatly start at that color.

31 ff 00 00 00 00 f0 0f 2f red only
31 00 ff 00 00 00 f0 0f 2f green only
31 00 00 ff 00 00 f0 0f 2f blue only
31 ff ff 00 00 00 f0 0f 2e yellow     (exactly r255 g255 b0  )
31 ff 00 ff 00 00 f0 0f 2e purple     (exactly r255 g0   b255)
31 00 ff ff 00 00 f0 0f 2e lt blue    (exactly r0   g255 b255)
31 ff ff ff 00 00 f0 0f 2d white      (exactly r255 g255 b255) Note: WW and CW at the end
31 00 00 00 00 00 f0 0f 30 colors off (exactly r0   g0   b0  )

31 cc 00 00 00 00 f0 0f fc red only, 80% bright   (exactly r204 g0   b0  )
31 99 00 00 00 00 f0 0f c9 red only, 60% bright   (exactly r153 g0   b0  )
31 66 00 00 00 00 f0 0f 96 red only, 40% bright   (exactly r102 g0   b0  )
31 33 00 00 00 00 f0 0f 63 red only, 20% bright   (exactly r51  g0   b0  )
31 19 00 00 00 00 f0 0f 49 red only, 10% bright   (exactly r26  g0   b0  )

31 00 cc 00 00 00 f0 0f fc green only, 80% bright   (exactly r0   g204 b0  )
31 00 99 00 00 00 f0 0f c9 green only, 60% bright   (exactly r0   g153 b0  )
31 00 66 00 00 00 f0 0f 96 green only, 40% bright   (exactly r0   g102 b0  )
31 00 33 00 00 00 f0 0f 63 green only, 20% bright   (exactly r0   g51  b0  )
31 00 19 00 00 00 f0 0f 49 green only, 10% bright   (exactly r0   g26  b0  )

31 00 00 cc 00 00 f0 0f fc blue only, 80% bright    (exactly r0   g0   b204)
31 00 00 99 00 00 f0 0f c9 blue only, 60% bright    (exactly r0   g0   b153)
31 00 00 66 00 00 f0 0f 96 blue only, 40% bright    (exactly r0   g0   b102)
31 00 00 33 00 00 f0 0f 63 blue only, 20% bright    (exactly r0   g0   b51 )
31 00 00 19 00 00 f0 0f 49 blue only, 10% bright    (exactly r0   g0   b26 )

31 cc cc 00 00 00 f0 0f c8 yellow, 80% bright   (exactly r204 g204 b0  )
31 99 99 00 00 00 f0 0f 62 yellow, 60% bright   (exactly r153 g153 b0  )
31 66 66 00 00 00 f0 0f fc yellow, 40% bright   (exactly r102 g102 b0  )
31 33 33 00 00 00 f0 0f 96 yellow, 20% bright   (exactly r51  g51  b0  )
31 19 19 00 00 00 f0 0f 62 yellow, 10% bright   (exactly r26  g26  b0  )

31 cc 00 cc 00 00 f0 0f c8 purple, 80% bright   (exactly r204 g0   b204)
31 99 00 99 00 00 f0 0f 62 purple, 60% bright   (exactly r153 g0   b153)
31 66 00 66 00 00 f0 0f fc purple, 40% bright   (exactly r102 g0   b102)
31 33 00 33 00 00 f0 0f 96 purple, 20% bright   (exactly r51  g0   b51 )
31 19 00 19 00 00 f0 0f 62 purple, 10% bright   (exactly r26  g0   b26 )

31 00 cc cc 00 00 f0 0f c8 lt blue, 80% bright  (exactly r0   g204 b204)
31 00 99 99 00 00 f0 0f 62 lt blue, 60% bright  (exactly r0   g153 b153)
31 00 66 66 00 00 f0 0f fc lt blue, 40% bright  (exactly r0   g102 b102)
31 00 33 33 00 00 f0 0f 96 lt blue, 20% bright  (exactly r0   g51  b51 )
31 00 19 19 00 00 f0 0f 62 lt blue, 10% bright  (exactly r0   g26  b26 )

31 cc cc cc 00 00 f0 0f 94 white, 80% bright  (exactly r204 g204 b204)
31 99 99 99 00 00 f0 0f fb white, 60% bright  (exactly r153 g153 b153)
31 66 66 66 00 00 f0 0f 62 white, 40% bright  (exactly r102 g102 b102)
31 33 33 33 00 00 f0 0f c9 white, 20% bright  (exactly r51  g51  b51 )
31 19 19 19 00 00 f0 0f 7b white, 10% bright  (exactly r26  g26  b26 )

61 25 10 0f a5 seven color cross fade (menu item 1)

61 26 10 0f a6 red gradual change 50% speed (menu item 2)
61 27 10 0f a7 green gradual change 50% speed (menu item 3)
61 28 10 0f a8 blue gradual change 50% speed (menu item 4)
61 2c 10 0f ac white gradual change 50% speed (menu item 8)

61 2d 10 0f ad red/green cross fade 50% speed (menu item 9)
61 2e 10 0f ae red/blue cross fade 50% speed (menu item 10)
61 2f 10 0f af green/blue cross fade 50% speed (menu item 11)

61 30 10 0f b0 seven color strobe flash 50% speed (menu item 12)
61 31 10 0f b1 red strobe flash 50% speed (menu item 13)
61 32 10 0f b2 green strobe flash 50% speed (menu item 14)
61 33 10 0f b3 blue strobe flash 50% speed (menu item 15)

61 37 01 0f a8 white strobe flash 100% speed
61 37 06 0f ad white strobe flash 80% speed
61 37 10 0f b7 white strobe flash 50% speed (menu item 19)
61 37 1c 0f c3 white strobe flash 10% speed

61 38 01 0f a9 seven color jumping change 100% speed
61 38 06 0f ae seven color jumping change 80% speed
61 38 10 0f b8 seven color jumping change 50% speed (menu item 20)
61 38 1c 0f c4 seven color jumping change 10% speed

31 00 00 00 ff 00 0f 0f 4e WW, 100% bright (warm white)
31 00 00 00 cc 00 0f 0f 1b WW, 80% bright
31 00 00 00 66 00 0f 0f b5 WW, 40% bright

31 00 00 00 00 ff 0f 0f 4e CW, 100% bright (cool white)
31 00 00 00 00 cc 0f 0f 1b CW, 80% bright
31 00 00 00 00 66 0f 0f b5 CW, 40% bright

31 00 00 00 00 00 0f 0f 4f both WW and CW, off

31 00 00 00 66 66 0f 0f 1b both WW and CW, 40% bright

  Note: WW/CW has ^^ this octet different than with R/G/B

[END]
So if you wanted to send from Windows command-line or batch...
   packetsender.com -q [IP of module] [port] [data in quotes]
For example, send "on"
   packetsender.com -q 192.168.1.54 5577 "71 23 0f a3"
For example, send "red" at full brightness
   packetsender.com -q 192.168.1.54 5577 "31 ff 00 00 00 00 f0 0f 2f"

A checksum of sorts is always the last octet, for example when sending "lt blue"
31 00 cc cc 00 00 f0 0f c8
  c8 is the checksum, which you can find yourself by adding up all the values:
31+00+cc+cc+00+00+f0+0f AND 255 like this...   Here's a link defuse.ca/big-number-calculator.htm

A handful of other people have "documented" the protocol for similar/older WiFi LED controllers and made scripts dependant on some 3rd party IoT service. I don't care for any of that risk or complexity just to control an LED strip on my LAN, but if you insist, here you go...
- node-red
- python
- zengge-lightcontrol
- fibaro
- node.js
- ESP8266 commercial H801
- Stephen Radford
- Shauna Ruyle

Now for the SUPERNIGHT unit, while it certainly works and has the added benefit of an IR remote (incase you lost your smartphone? or don't trust your guests on your WiFi?) here are some things I noticed:
- when dimming any color LED (or mixing colors) it makes a high-pitched whine that annoys me
- no cross-fade when changing colors
- it gets VERY warm
- there is a solder pad on the board (and the accompanying transistor) marked W, as if there was a 4th channel for White LEDs, but I found no way to turn it on so perhaps this is only enabled in a different model firmware
- internal WiFi module is marked ESP-12S
- doesn't seem to run any webserver
- it still works if you de-solder the IR receiver
For these reasons I decided to only trust this unit to trigger 3 relays (one attached to each of the R, G, B pins and with a flyback diode) to automate a children's toy, it runs cooler in this way.

The capture for this one...
For module labeled SUPERNIGHT WiFi Wireless LED Smart Controller

71 23 0f a3 on
71 24 0f a4 off

31 ff 00 00 00 00 0f 3f red only
31 00 ff 00 00 00 0f 3f green only
31 00 00 ff 00 00 0f 3f blue only

31 ff ff 01 00 00 0f 3f red and green

31 00 00 00 00 00 0f 40 colors off

[END]
Conclusions:
If you wanted to use these to switch bigger loads, perhaps by connecting a relay directly to the channel output, then the SUPERNIGHT unit is easier because sending the command for red at 100% brightness will immediately turn red on full, whereas the LEDNET unit insists on doing a nice "fade in" or "ramp up" from 0% to 100% which makes a relay scream prior to picking. Controlling something like a DC motor, since any channel output is already PWM, would be much easier. Both modules are affordable and an easy way to add WiFi control options (or an IR remote) to any project, not just LED strips. Besides controlling these from Windows/command-line, the protocol is easy enough to control from a network connected Arduino or RasPi board.
For a video comparison see here, and please thumbs up if this helped you in some way.