Git Product home page Git Product logo

Comments (4)

mariusmotea avatar mariusmotea commented on August 10, 2024

Hi,

Entertainment mode works this way:

Entertainment app broadcast udp frames acording to entertainment protocol. This use a dtls encryption that is not available in python libraries, for this reason we use a proxy udp server compiled in c++ that is started only when entertainment mode is enabled and only purpose is to remove encryption and send raw udp data to hue emulator (python based) on secondary port 2001/udp listener (not remember exactly if this is the port). At this point the hue emulator parse the data to see what type is the light that need to receive the request. If this is an esp8266 based light with dedicated udp server for entertainment mode the rgb data of the frame is forwarded there, otherwise conversion is applied and delay added because all other types of lights are not able to process light data so fast. ESP8266 light receive all 24 updates per second, all other types of lighs receive just one update per second. I believe Yeelight receive more updates (~2) per second, i need check as i don't remeber exactly.

from lights.

obelix05 avatar obelix05 commented on August 10, 2024

Hi.
Thanks for quick reply.
I'm interested in this three lines of code from "Generic_WS2812_Strip.ino"

    for (uint8_t i = 0; i < packetSize / 4; i++) {
      lights[packetBuffer[i * 4]].currentColors[0] = packetBuffer[i * 4 + 1];
      lights[packetBuffer[i * 4]].currentColors[1] = packetBuffer[i * 4 + 2];
      lights[packetBuffer[i * 4]].currentColors[2] = packetBuffer[i * 4 + 3];
    }

What does the packetBuffer look like if there is a unregistered light?
Imagine my diyLight has 3 Lights and i want to have entertainment on light 1 and 3, light 2 should stay in the "normal" mode. Is the packetBuffer for light 2 None or 0 or sth. like this?
The question comes up because I don't have a really good debugging idea for the lights on an ESP8266.

from lights.

mariusmotea avatar mariusmotea commented on August 10, 2024

But your issue must not be an issue. If you exclude lights from entertainment area will simply skip that lights. I believe you use ws2812 strip.

from lights.

obelix05 avatar obelix05 commented on August 10, 2024

Hi. Yes you're right. It is not an issue, but rather a general question. I didn't know where to ask my question.
And I'm sorry for my question.I have not seen that all lights that are not configured are left out. And I had a bug in my code. Thanks for your advice. Sorry to disturb you.
Anyway: Thank you so much for your great work.

from lights.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.