RPI4+LE+Arduino Uno.Video blink problem

  • Hi,
    I have problem with my ambilight,so I set up everything correctly(I guess).No problems with installation hyperion etc.(I install only from hypercon,not from kodi library).
    So when I play any video,the screen is going to all black,but the ambilight is still working,leds are changing colors.
    I`m using the newest libreelec(9.2.0) and kodi(18.x) and rpi4.In the menu leds are all white,and signal led on arduino are blinking fast.I try to use android app,but leds are not responding too.
    In "get log"
    ssh in: LEDDEVICE INFO: configuration:
    ssh in: {
    ssh in: "colorOrder" : "rbg",
    ssh in: "delayAfterConnect" : 0,
    ssh in: "name" : " hyperion.config",
    ssh in: "output" : "/dev/ttyUSB0",
    ssh in: "rate" : 115200,
    ssh in: "type" : "adalight"
    ssh in: }
    ssh in: Opening UART: /dev/ttyUSB0
    ssh in: INFO: Creating linear smoothing
    ssh in: HYPERION (CS) INFO: Created linear-smoothing(interval_ms=33;settlingTime_ms=200;updateDelay=0
    ssh in: EFFECTENGINE INFO: 27 effects loaded from directory /storage/hyperion/effects
    ssh in: EFFECTENGINE INFO: Initializing Python interpreter
    ssh in: INFO: Hyperion started and initialised
    ssh in: INFO: Boot sequence 'Knight rider' EFFECTENGINE INFO: run effect Knight rider on channel 0
    ssh in: BLACKBORDER INFO: threshold set to 0.1 (26)
    ssh in: BLACKBORDER INFO: mode:default
    ssh in: started
    ssh in: INFO: Kodi checker created and started
    ssh in: INFO: Json server created and started on port 19446
    ssh in: INFO: Proto server created and started on port 19447
    ssh in: INFO: Boblight server created and started on port 19333
    ssh in: DISPMANXGRABBER INFO: Display opened with resolution: 1920x1080
    ssh in: BLACKBORDER INFO: threshold set to 0.1 (26)
    ssh in: BLACKBORDER INFO: mode:default
    ssh in: INFO: Frame grabber created and started
    ssh in: KODICHECK ERROR: Kodi Connection error (0)
    ssh in: EFFECTENGINE INFO: effect finished
    ssh in: BORDER SWITCH REQUIRED!!
    ssh in: CURRENT BORDER TYPE: unknown=0 hor.size=0 vert.size=4
    ssh in: BORDER SWITCH REQUIRED!!
    ssh in: CURRENT BORDER TYPE: unknown=0 hor.size=0 vert.size=0
    ssh in: KODICHECK INFO: Kodi Connected

    My arduino sketch:
    /*
    * Arduino interface for the use of WS2812 strip LEDs
    * Uses Adalight protocol and is compatible with Boblight, Prismatik etc...
    * "Magic Word" for synchronisation is 'Ada' followed by LED High, Low and Checksum
    * @author: Wifsimster <wifsimster@gmail.com>
    * @library: FastLED v3.001
    * @date: 11/22/2015
    */
    #include "FastLED.h"
    #define NUM_LEDS 33
    #define DATA_PIN 5


    // Baudrate, higher rate allows faster refresh rate and more LEDs (defined in /etc/boblight.conf)
    #define serialRate 115200


    // Adalight sends a "Magic Word" (defined in /etc/boblight.conf) before sending the pixel data
    uint8_t prefix[] = {'A', 'd', 'a'}, hi, lo, chk, i;


    // Initialise LED-array
    CRGB leds[NUM_LEDS];


    void setup() {
    // Use NEOPIXEL to keep true colors
    FastLED.addLeds<NEOPIXEL, DATA_PIN>(leds, NUM_LEDS);
    // Initial RGB flash
    LEDS.showColor(CRGB(255, 0, 0));
    delay(500);
    LEDS.showColor(CRGB(0, 255, 0));
    delay(500);
    LEDS.showColor(CRGB(0, 0, 255));
    delay(500);
    LEDS.showColor(CRGB(0, 0, 0));
    Serial.begin(serialRate);
    // Send "Magic Word" string to host
    Serial.print("Ada\n");
    }


    void loop() {
    // Wait for first byte of Magic Word
    for(i = 0; i < sizeof prefix; ++i) {
    waitLoop: while (!Serial.available()) ;;
    // Check next byte in Magic Word
    if(prefix == Serial.read()) continue;
    // otherwise, start over
    i = 0;
    goto waitLoop;
    }
    // Hi, Lo, Checksum
    while (!Serial.available()) ;;
    hi=Serial.read();
    while (!Serial.available()) ;;
    lo=Serial.read();
    while (!Serial.available()) ;;
    chk=Serial.read();
    // If checksum does not match go back to wait
    if (chk != (hi ^ lo ^ 0x55)) {
    i=0;
    goto waitLoop;
    }
    memset(leds, 0, NUM_LEDS * sizeof(struct CRGB));
    // Read the transmission data and set LED values
    for (uint8_t i = 0; i < NUM_LEDS; i++) {
    byte r, g, b;
    while(!Serial.available());
    r = Serial.read();
    while(!Serial.available());
    g = Serial.read();
    while(!Serial.available());
    b = Serial.read();
    leds.r = r;
    leds.g = g;
    leds.b = b;
    }
    // Shows new values
    FastLED.show();

    }


    Everything working perfect with prismatik on windows.

Jetzt mitmachen!

Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!