🤖Have you ever tried Chat.M5Stack.com before asking??😎
    M5Stack Community
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    RGB Leds Crossfade

    UIFlow
    2
    2
    1.7k
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • H
      Hawksey
      last edited by

      Hi

      I'm trying to get a string of leds to crossfade from one colour to another.
      I've got the start and end colours as RGB values in 6 variables, can get them to flash from to other ok, but stuck
      on how to get them to slowly crossfade from to other. Any pointers? I'm a total beginner with UiFlow. Thanks

      1 Reply Last reply Reply Quote 0
      • H
        holofloh
        last edited by

        This is not an Uiflow specific solution. Try as following:

        • Decide how many steps you want from start color to end color. e.g. 10 steps
        • find the step size from start to end color e.g. you want from value 100 to 200 (difference / steps) = step size 10.
        • loop for the number of steps and increase/decrease the value with the calculated step size.
        1 Reply Last reply Reply Quote 1
        • First post
          Last post