# JSON segment different animation not sticking

**URL:** <https://wled.discourse.group/t/json-segment-different-animation-not-sticking/1459>\
**Category:** Issues\
**Created:** [November 28, 2020, 5:49pm UTC](https://wled.discourse.group/t/json-segment-different-animation-not-sticking/1459 "2020-11-28T17:49:01Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![nodiaque](https://avatars.discourse-cdn.com/v4/letter/n/a87d85/32.png) [@nodiaque](https://wled.discourse.group/u/nodiaque)\
**Post date:** [November 28, 2020, 5:49pm UTC](https://wled.discourse.group/t/json-segment-different-animation-not-sticking/1459/1 "2020-11-28T17:49:01Z")

</div>

Hello,

I have a WS2815 5m led strip connected to a nodemcu. I started using node-red to send json data so I can have custom animation. One of these is using 3 segments and 2 different animation. The JSON is as follow:

```
msg.payload = 
{
    "on":true,
    "bri":255,
    "transition":5,
    "ps":-1,
    "pss":0,
    "pl":-1,
    "mainseg":0,
    "seg":
    [
        {
            "id":0,
            "desc":"Left",
            "start":0,
            "stop":100,
            "grp":1,
            "spc":0,
            "on":true,
            "bri":255,
            "col":
            [
                [255,0,0],
                [0,0,0],
                [255,255,255]
            ],
            "fx":76,
            "sx":93,
            "ix":142,
            "pal":0,
            "sel":true,
            "rev":true,
            "mi":false
        },
        {
            "id":1,
            "desc":"Top",
            "start":100,
            "stop":200,
            "grp":1,
            "spc":0,
            "on":true,
            "bri":255,
            "col":
            [
                [255,0,0],
                [0,0,255],
                [0,0,0]
            ],
            "fx":108,
            "sx":150,
            "ix":151,
            "pal":0,
            "sel":true,
            "rev":true,
            "mi":true
        },
        {
            "id":2,
            "desc":"Right",
            "start":200,
            "stop":300,
            "grp":1,
            "spc":0,
            "on":true,
            "bri":255,
            "col":
            [
                [255,0,0],
                [0,0,0],
                [255,255,255]
            ],
            "fx":76,
            "sx":93,
            "ix":142,
            "pal":0,
            "sel":true,
            "rev":false,
            "mi":false
        }
    ]
}

```

Now, when I send the data, it does like I want, left and right does a sort of falling down segment and the top segment does another animation. But after a random amount of seconds (under 10), the top segment will change animation and follow left and right (like if left and right segment where now 1-150 and 150-300). I’ve checked in the ui and all segment are correctly configured. It seems something in the loop doesn’t work properly.

edit: here’s a video to show what I’m talking about  
[https://youtu.be/\_ZUHkXSLwas](https://youtu.be/_ZUHkXSLwas)

newedit: I found out that it revert to the mainseq fx (but retain color). I don’t want that and I haven’t found how to not use that

Thank you

---

<div class="post-metadata">

**Author:** ![Def3nder](https://yyz2.discourse-cdn.com/free1/user_avatar/wled.discourse.group/def3nder/32/62_2.png) [@Def3nder](https://wled.discourse.group/u/Def3nder)\
**Post date:** [November 28, 2020, 8:48pm UTC](https://wled.discourse.group/t/json-segment-different-animation-not-sticking/1459/2 "2020-11-28T20:48:17Z")

</div>

Hi @nodiaque, is there any other WLED instance running in the same network ?

…just to test, could you pls. add `"udpn":{"recv":false},` in the JSON ?

> msg.payload =  
> {  
> “on”:true,  
> “bri”:255,  
> “transition”:5,  
> “ps”:-1,  
> “pss”:0,  
> “pl”:-1,  
> “mainseg”:0,  
> “udpn”:{“recv”:false},  
> “seg”:  
> [  
> { … etc.

So we can ensure that no UDP packet is doing this change…

Greetings from Berlin,  
Ralf aka Def3nder

---

<div class="post-metadata">

**Author:** ![nodiaque](https://avatars.discourse-cdn.com/v4/letter/n/a87d85/32.png) [@nodiaque](https://wled.discourse.group/u/nodiaque)\
**Post date:** [November 28, 2020, 9:25pm UTC](https://wled.discourse.group/t/json-segment-different-animation-not-sticking/1459/3 "2020-11-28T21:25:38Z")

</div>

Hello,

I don’t have any other WLED instance. Weirdly, it now works!

I’ve disabled all broadcast feature over UDP, don’t know why it was doing that but since I don’t use that, I don’t care.

Thanks!
