mirror of https://github.com/arendst/Tasmota.git
Updated MagicHome LED strip controller (markdown)
parent
9c97f98431
commit
3aac264523
|
@ -71,4 +71,99 @@ mosquitto_pub -t 'cmnd/light/rule1' -m 'on IrReceived#Data=FFF807 do power OFF e
|
|||
|
||||
The hex codes for the "Data" value come from the data tag when looking at the JSON sent via MQTT. From here you can program it to do what ever you want. See here for more details: https://github.com/arendst/Sonoff-Tasmota/wiki/Rules
|
||||
|
||||
![](https://i.imgur.com/AWXrYTp.jpg)
|
||||
![](https://i.imgur.com/AWXrYTp.jpg)
|
||||
|
||||
# MagicHome with ESP8285
|
||||
|
||||
Yet another MagicHome RGB controller. I specifically had this one: https://www.aliexpress.com/item/DC5-24V-Wireless-WIFI-LED-RGB-Controller-RGBW-Controller-IR-RF-Remote-Control-IOS-Android-for/32827253255.html
|
||||
|
||||
Aside from it going 9-28v, there are no other external model numbers etc, however opening it up revealed a very different configuration inside, using an ESP8285 chip directly on the board.
|
||||
|
||||
<img width="50%" src="https://user-images.githubusercontent.com/816454/43894935-fd83a9d8-9c16-11e8-9a78-b7a058d972de.jpg" alt="opened with cover in view">
|
||||
|
||||
(Right click and view the original image to see the full size image for all images below)
|
||||
|
||||
## Identifying this board
|
||||
|
||||
Looking closely you can see it's an ESP8285, on the main board, it has the part number: `ZJ-WFMN-B V1.1`
|
||||
|
||||
<img width="40%" src="https://user-images.githubusercontent.com/816454/43895058-6fcb4e10-9c17-11e8-8c9c-b99c57a39c55.jpg" alt="board top 1">
|
||||
<img width="40%" src="https://user-images.githubusercontent.com/816454/43895059-6ffdd7b8-9c17-11e8-994e-aeb8f65f47ef.jpg" alt="board top 2">
|
||||
|
||||
## Flashing
|
||||
|
||||
I found that on the back it has pads to solder to so you can flash it.
|
||||
|
||||
<img width="40%" src="https://user-images.githubusercontent.com/816454/43895057-6f80d178-9c17-11e8-8c6f-535d31ea0603.jpg" alt="board back">
|
||||
|
||||
The `IO0` port is `GPIO0` that needs to be pulled to ground when powered on for flashing (as per all ESP devices). I soldered cables to each of these. Note that some are very close to other pads, so be careful. If you want to avoid soldering, also pogo pins work well with the pads.
|
||||
|
||||
<img width="40%" src="https://user-images.githubusercontent.com/816454/43895056-6f41e094-9c17-11e8-95b7-cf565967c89e.jpg" alt="board back with cables">
|
||||
|
||||
## Configuration
|
||||
|
||||
Once flashed, I configured it as follows (using Tasmota v6.1.1):
|
||||
|
||||
ZJ-WFMN-B V1.1
|
||||
|
||||
| Field | Value |
|
||||
|---|---|
|
||||
|Module type|18 Generic|
|
||||
|D1 GPIO5|38 PWM2|
|
||||
|D6 GPIO12|39 PWM3|
|
||||
|D7 GPIO13|40 PWM4|
|
||||
|D5 GPIO14|37 PWM1|
|
||||
|
||||
ZJ-WFMN-A V1.1
|
||||
|
||||
| Field | Value | Function |
|
||||
|---|---|---|
|
||||
|Module type|18 Generic|Module type|
|
||||
|D2 GPIO4|51 IRRecv|IR Remote (optional, view console for debugging!)|
|
||||
|D1 GPIO5|38 PWM2|BLUE|
|
||||
|D6 GPIO12|37 PWM1|RED|
|
||||
|D7 GPIO13|39 PWM3|GREEN|
|
||||
|D8 GPIO15|40 PWM4|WHITE|
|
||||
|
||||
|
||||
ZJ-WFMN-A V1.1(RGB version)
|
||||
|
||||
| Field | Value | Function |
|
||||
|---|---|---|
|
||||
|Module type|18 Generic|Module type|
|
||||
|D1 GPIO5|38 PWM1|RED|
|
||||
|D6 GPIO12|37 PWM2|GREEN|
|
||||
|D7 GPIO13|39 PWM3|BLUE|
|
||||
|
||||
With all that done, one of the critical things I needed to do so I could set the colors was to run the command to set `SetOption15` to `1`. For me, this was sending the MQTT command (you will need to adjust for your config):
|
||||
|
||||
```
|
||||
mosquitto_pub -t 'cmnd/rgbled/SetOption15' -m '1'
|
||||
```
|
||||
|
||||
Once the above was done and the device rebooted, I could set the colors using commands such as (to turn on red and white full):
|
||||
```
|
||||
mosquitto_pub -h openhab.sf -t 'cmnd/rgbled/color' -m '#ff0000ff'
|
||||
```
|
||||
|
||||
### RF control
|
||||
|
||||
If you have the RF variant, you will want to configure the GPIOs like this:
|
||||
|
||||
```
|
||||
{ "MagicHome RF", // Magic Home RF (ESP8266) - (Arilux LC10)
|
||||
GPIO_USER, // GPIO00 Optional Button
|
||||
GPIO_USER, // GPIO01 Serial RXD and Optional sensor
|
||||
GPIO_LED1_INV, // GPIO02 Blue onboard LED (optional)
|
||||
GPIO_USER, // GPIO03 Serial TXD and Optional sensor0
|
||||
GPIO_ARIRFRCV, // GPIO04 RF receiver input
|
||||
GPIO_PWM2, // GPIO05 RGB LED Green
|
||||
0, 0, 0, 0, 0, 0, // Flash connection
|
||||
GPIO_PWM3, // GPIO12 RGB LED Blue
|
||||
GPIO_PWM4, // GPIO13 RGBW LED White
|
||||
GPIO_PWM1, // GPIO14 RGB LED Red
|
||||
GPIO_LED2_INV, // GPIO15 RF receiver control
|
||||
0, 0
|
||||
},
|
||||
```
|
||||
After chosing the correct module type in your Tasmota configuration, press a key on the remote after boot for the device to learn your code.
|
Loading…
Reference in New Issue