# Controlling segments via node-red does not work as expected

**URL:** <https://wled.discourse.group/t/controlling-segments-via-node-red-does-not-work-as-expected/8200>\
**Category:** Questions\
**Created:** [May 3, 2023, 3:16pm UTC](https://wled.discourse.group/t/controlling-segments-via-node-red-does-not-work-as-expected/8200 "2023-05-03T15:16:04Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![numark1](https://avatars.discourse-cdn.com/v4/letter/n/49beb7/32.png) [@numark1](https://wled.discourse.group/u/numark1)\
**Post date:** [May 3, 2023, 3:16pm UTC](https://wled.discourse.group/t/controlling-segments-via-node-red-does-not-work-as-expected/8200/1 "2023-05-03T15:16:05Z")

</div>

Hi,

I have a nearly WS2812 LED Strip with nearly 200 LEDs splitted to 3 segments. I control everything with WLED on a WemosD1 mini and can control everything as expected. For automation I want to control the segments via node-red and the wled2 palette. The Problem is that I can turn on each segment as expected, but when I run the command for turning off a segment it always power off the “whole” system. Dont know how to describe but in the WLED UI there is a global powerbutton top left and then there is a powerbutton for each segment. When I trigger the workflow from node-red for 1 segment it always trigger the global power butten and then I loose control over the whole strip.

 ![image](https://global.discourse-cdn.com/free1/uploads/wled/original/2X/f/f3437f8b0394657ee1ae57107fdf6781ed06202f.png)

This is my node for turn a segment on, WLED server, Segment ID = 1 and State = on, this activates the intended segment with the correct color/effect.

Then I copy the node and select state = off and no matter which segment I choose it always turns off the complete system.

I dont see it what I’m doing wrong… is it the wrong palette or something ? Is it better to do this via HTTP post request or something completely different ?

Thanks in advance !
