# Control Led Bar

**URL:** https://discourse.nodered.org/t/control-led-bar/83849
**Category:** General
**Created:** [20 December 2023 07:31 UTC](https://discourse.nodered.org/t/control-led-bar/83849 "2023-12-20T07:31:40Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![wiwan-wijoyo](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/wiwan-wijoyo/32/48198_2.png) [@wiwan-wijoyo](https://discourse.nodered.org/u/wiwan-wijoyo)
#### Post date: [20 December 2023 07:31 UTC](https://discourse.nodered.org/t/control-led-bar/83849/1 "2023-12-20T07:31:40Z")

</div>

I have android wall with LED Bar, I already to control LED Bar from cmd (adb shell)and working well.  
android wall IP : 192.168.16.129  
port adb : 55555

1. Connect android wall send command “adb connect 192.168.16.129:5555”
2. Send command “adb shell”
3. Send command “su” Super User
4. Send command led bar  
Red : “echo w 0x04 \> ./sys/devices/platform/led\_con\_h/zigbee\_reset”  
Green : :“echo w 0x05 \> ./sys/devices/platform/led\_con\_h/zigbee\_reset”  
Blue : “echo w 0x06 \> ./sys/devices/platform/led\_con\_h/zigbee\_reset”

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/0/c/0ca53c8babca11da2a86dd16e7f59ca962c53b6f.png)

I tried to make it like this can connect

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/f/2/f2bf10f5a9b2284dbcb1ca5497edad72215ccaf6.png)

I tried sending a command to turn on the led bar but not working.

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/0/a/0ad635a3f5698898fe003ea1ec1cce80f63a706a.png)

```auto
[{"id":"8e5a299f2078ef18","type":"inject","z":"9d61395e.8839f8","name":"","props":[{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":510,"y":20,"wires":[["5e206a893ec55ab8"]]},{"id":"5e206a893ec55ab8","type":"change","z":"9d61395e.8839f8","name":"ADB Su","rules":[{"t":"set","p":"payload","pt":"msg","to":"adb shell su","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":640,"y":20,"wires":[["005703620da42047"]]},{"id":"005703620da42047","type":"function","z":"9d61395e.8839f8","name":"\\n","func":"msg.payload +=\"\\n\"\nreturn msg;\n","outputs":1,"timeout":0,"noerr":0,"initialize":"","finalize":"","libs":[],"x":810,"y":60,"wires":[["b6bd595fa6ef2c91"]]},{"id":"feb5d98b9bda9655","type":"change","z":"9d61395e.8839f8","name":"Red","rules":[{"t":"set","p":"payload","pt":"msg","to":"echo w 0x04 > ./sys/devices/platform/led_con_h/zigbee_reset","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":650,"y":60,"wires":[["005703620da42047"]]},{"id":"fcf302e9dd88abe8","type":"change","z":"9d61395e.8839f8","name":"Blue","rules":[{"t":"set","p":"payload","pt":"msg","to":"echo w 0x05 > ./sys/devices/platform/led_con_h/zigbee_reset","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":650,"y":140,"wires":[["005703620da42047"]]},{"id":"8d4142f0f883e09c","type":"change","z":"9d61395e.8839f8","name":"Green","rules":[{"t":"set","p":"payload","pt":"msg","to":"echo w 0x06 > ./sys/devices/platform/led_con_h/zigbee_reset","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":650,"y":100,"wires":[["005703620da42047"]]},{"id":"b6bd595fa6ef2c91","type":"exec","z":"9d61395e.8839f8","command":"","addpay":"payload","append":"","useSpawn":"false","timer":"","winHide":false,"oldrc":false,"name":"Connect","x":1000,"y":100,"wires":[["e25adfe44484b975"],[],[]]},{"id":"e6063021c3274d45","type":"inject","z":"9d61395e.8839f8","name":"","props":[{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":510,"y":60,"wires":[["feb5d98b9bda9655"]]},{"id":"d2dba536546e646f","type":"inject","z":"9d61395e.8839f8","name":"","props":[{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":510,"y":140,"wires":[["fcf302e9dd88abe8"]]},{"id":"dc295a96031cc654","type":"inject","z":"9d61395e.8839f8","name":"","props":[{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":510,"y":100,"wires":[["8d4142f0f883e09c"]]},{"id":"564a567e3beedf50","type":"change","z":"9d61395e.8839f8","name":"ADB Connect","rules":[{"t":"set","p":"payload","pt":"msg","to":"adb connect 192.168.16.129:5555","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":680,"y":220,"wires":[["b6bd595fa6ef2c91"]]},{"id":"e25adfe44484b975","type":"switch","z":"9d61395e.8839f8","name":"State","property":"payload","propertyType":"msg","rules":[{"t":"else"}],"checkall":"false","repair":false,"outputs":1,"x":1150,"y":80,"wires":[["784c69a350bd1379"]],"outputLabels":["Succes"]},{"id":"6c97af3a43ef19f0","type":"inject","z":"9d61395e.8839f8","name":"","props":[{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","x":510,"y":220,"wires":[["564a567e3beedf50"]]},{"id":"784c69a350bd1379","type":"debug","z":"9d61395e.8839f8","name":"debug","active":true,"tosidebar":true,"console":false,"tostatus":true,"complete":"true","targetType":"full","statusVal":"payload","statusType":"auto","x":1330,"y":80,"wires":[]}]

```

I hope someone can help me.

---

<div class="post-metadata">

### Author: ![Trying\_to\_learn](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/trying_to_learn/32/28400_2.png) [@Trying\_to\_learn](https://discourse.nodered.org/u/Trying_to_learn)
#### Post date: [20 December 2023 07:37 UTC](https://discourse.nodered.org/t/control-led-bar/83849/2 "2023-12-20T07:37:50Z")

</div>

So what kind of LED's are they?

RGB, NeoPixel?

Why am _I_ seeing `zigbee` mentioned?

---

<div class="post-metadata">

### Author: ![Steve-Mcl](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/steve-mcl/32/4826_2.png) [@Steve-Mcl](https://discourse.nodered.org/u/Steve-Mcl)
#### Post date: [20 December 2023 07:49 UTC](https://discourse.nodered.org/t/control-led-bar/83849/3 "2023-12-20T07:49:25Z")

</div>

If this is a ZigBee device, you could make this all super simple by running ZigBee2mqtt and control it all via MQTT.

---

<div class="post-metadata">

### Author: ![wiwan-wijoyo](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/wiwan-wijoyo/32/48198_2.png) [@wiwan-wijoyo](https://discourse.nodered.org/u/wiwan-wijoyo)
#### Post date: [20 December 2023 09:06 UTC](https://discourse.nodered.org/t/control-led-bar/83849/4 "2023-12-20T09:06:13Z")

</div>

thank's for reply

I have a android wall mount with LED bar

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/8/1/81226ee396557e605975ade07ca15d8a016ea6f3.jpeg)  
Change red color I send the command like this  
 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/e/6/e6110f22254bfe69221f78c489cf5a2c2692391f.jpeg)  
And if change to green color I send it.

---

<div class="post-metadata">

### Author: ![wiwan-wijoyo](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/wiwan-wijoyo/32/48198_2.png) [@wiwan-wijoyo](https://discourse.nodered.org/u/wiwan-wijoyo)
#### Post date: [20 December 2023 09:12 UTC](https://discourse.nodered.org/t/control-led-bar/83849/5 "2023-12-20T09:12:01Z")

</div>

![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/2/a/2a9623f5a99a051f5027e5a949e47c719c966265.png)  
This information from factory

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)
#### Post date: [18 February 2024 09:12 UTC](https://discourse.nodered.org/t/control-led-bar/83849/6 "2024-02-18T09:12:09Z")

</div>

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.
