1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Hdmi grabber?

Discussion in 'Hyperion General' started by pigbait, 30 December 2018.

  1. Paulchen-Panther

    Paulchen-Panther Active Member Developer

    Messages:
    196
    @d00mw01f and @pigbait I've made changes to the V4L2 branch. Could you please test again?
    P.S. Thanks again for your detailed feedback :thumbsup:
     
    Last edited: 4 May 2019
  2. d00mw01f

    d00mw01f New Member

    Messages:
    5
    Hardware:
    RPi3, +Arduino
    Hello @Paulchen-Panther. I was a bit busy this week, but I finally came and checked changes.
    First of I tried to make screenshot again using hyperion-v4l2 and had no luck. Even when I specified pixel format mjpeg (which now is valid) I got small black rectangle.
    Code:
    [email protected]:~/hyperion-mjpeg/hyperion.ng/build/bin $ ./hyperion-v4l2 --screenshot --pixel-format mjpeg
    hyperion-v4l2:
            Version   : 2.0.0 (V4L2 (GitHub-325a2fc4/1dba4ee7-1557003366) Git Remote: https://github.com/Paulchen-Panther/hyperion.ng.git)
            build time: May  6 2019 23:10:47
    
    Signal detection informations
    =============================
    dimension after decimation: 26 x 20
    signal detection area  : 6,5 x 19,15
    
    WARNING no red, green or blue "no signal area" detected, signal detection might have problems.
    
    suggested config values for signal detection:
            "redSignalThreshold"   : 0.1,
            "greenSignalThreshold" : 0.1,
            "blueSignalThreshold"  : 0.1,
            "signalDetectionHorizontalOffsetMin" : 0.23,
            "signalDetectionVerticalOffsetMin"   : 0.25,
            "signalDetectionHorizontalOffsetMax" : 0.73,
            "signalDetectionVerticalOffsetMax"   : 0.75

    Then I tried hyperion. Changes I noticed:
    1. Now I'm able to change capturing device without getting errors.
    2. Also video standard option was changed, Earlier it worked only in auto mode, now it works in any mode (testedall) without any difference.
    3. After hyperion startup leds isn't working until I will "restart" led device from web-gui.
    Code:
    [email protected]:~/hyperion-mjpeg/hyperion.ng/build/bin $ ./hyperiond -d
    [hyperiond DAEMON] <DEBUG> <PythonInit.cpp:20:PythonInit()> Initializing Python interpreter
    [hyperiond SettingsManager] <INFO> Selected configuration file: /home/pi/.hyperion/config/hyperion_main.json
    [hyperiond SettingsManager] <DEBUG> <SettingsManager.cpp:129:SettingsManager()> Settings database initialized
    [hyperiond EFFECTFILES] <INFO> 36 effects loaded from directory :/effects/
    [hyperiond EFFECTFILES] <INFO> 19 effect schemas loaded from directory :/effects/schema/
    [hyperiond EFFECTFILES] <INFO> 0 effects loaded from directory /home/pi/.hyperion/custom-effects
    [hyperiond SettingsManager] <INFO> Selected configuration file: /home/pi/.hyperion/config/hyperion_main.json
    [hyperiond SettingsManager] <DEBUG> <SettingsManager.cpp:73:SettingsManager()> Settings database initialized
    [hyperiond BLACKBORDER] <DEBUG> <BlackBorderProcessor.cpp:65:handleSettingsUpdate()> Set mode to: default
    [hyperiond ComponentRegister] <DEBUG> <ComponentRegister.cpp:67:componentStateChanged()> Blackborder detector: enabled
    [hyperiond FLATBUFCONNECTION] <INFO> Connecting to Hyperion: 127.0.0.1:19401
    [hyperiond ComponentRegister] <DEBUG> <ComponentRegister.cpp:67:componentStateChanged()> LED device: enabled
    [hyperiond LEDDEVICE] <DEBUG> <LedDeviceAdalight.cpp:53:init()> Adalight header for 184 leds: Ada 0x00 0xb7 0xe2
    [hyperiond LEDDEVICE] <INFO> LedDevice 'adalight' configured.
    [hyperiond ComponentRegister] <DEBUG> <ComponentRegister.cpp:67:componentStateChanged()> Smoothing: enabled
    [hyperiond LEDDEVICE] <INFO> Opening UART: /dev/ttyUSB0
    [hyperiond EFFECTENGINE] <INFO> run effect Rainbow swirl fast on channel 0
    [hyperiond HYPERION] <DEBUG> <PriorityMuxer.cpp:153:registerInput()> Register new input 'System/EFFECT' with priority 0 as inactive
    [hyperiond HYPERION] <INFO> Inital foreground effect 'Rainbow swirl fast' started
    [hyperiond EFFECTENGINE] <INFO> run effect Trails color on channel 254
    [hyperiond HYPERION] <DEBUG> <PriorityMuxer.cpp:153:registerInput()> Register new input 'System/EFFECT' with priority 254 as inactive
    [hyperiond HYPERION] <INFO> Inital background effect 'Trails color' started
    [hyperiond LEDDEVICE] <DEBUG> <ProviderRs232.cpp:182:tryOpen()> Setting baud rate to 115200
    [hyperiond HYPERION] <DEBUG> <PriorityMuxer.cpp:153:registerInput()> Register new input 'System/V4L' with priority 240 as inactive
    [hyperiond ComponentRegister] <DEBUG> <ComponentRegister.cpp:67:componentStateChanged()> V4L capture device: enabled
    [hyperiond BOBLIGHT] <DEBUG> <BoblightServer.cpp:24:BoblightServer()> Instance created
    [hyperiond LEDDEVICE] <DEBUG> <ProviderRs232.cpp:198:tryOpen()> Device blocked for 1500 ms
    [hyperiond DAEMON] <INFO> Hyperion initialized
    [hyperiond DAEMON] <INFO> set screen capture device to 'dispmanx'
    [hyperiond DISPMANXGRABBER] <DEBUG> <Grabber.cpp:33:setVideoMode()> Set videomode to 0
    [hyperiond DISPMANXGRABBER] <INFO> Display opened with resolution: 1920x1080
    [hyperiond DISPMANXGRABBER] <DEBUG> <Grabber.cpp:82:setWidthHeight()> Set new width: 80, height: 45 for capture
    [hyperiond DAEMON] <INFO> DISPMANX frame grabber created
    [hyperiond V4L2:auto] <DEBUG> <Grabber.cpp:33:setVideoMode()> Set videomode to 0
    [hyperiond V4L2:auto] <INFO> Signal threshold set to: {12, 12, 12}
    [hyperiond V4L2:auto] <INFO> Cropping image: width=0 height=0; crop: left=3 right=2 top=3 bottom=2
    [hyperiond V4L2:auto] <INFO> Signal detection is now disabled
    [hyperiond V4L2:auto] <INFO> Signal detection area set to: 0.250000,0.250000 x 0.750000,0.750000
    [hyperiond DAEMON] <DEBUG> <hyperiond.cpp:419:handleSettingsUpdate()> V4L2 grabber created
    [hyperiond V4L2:auto] <INFO> available V4L2 devices:
            /dev/video0     USB2.0 PC CAMERA
    
    [hyperiond V4L2:auto] <INFO> search for usable video devices
    [hyperiond V4L2:auto] <INFO> test v4l device: /dev/video0
    [hyperiond V4L2:auto] <DEBUG> <V4L2Grabber.cpp:598:init_device()> width=160 height=120
    [hyperiond V4L2:auto] <DEBUG> <V4L2Grabber.cpp:660:init_device()> Pixel format=MJPEG
    [hyperiond V4L2:auto] <INFO> found usable v4l2 device: /dev/video0 (USB2.0 PC CAMERA)
    [hyperiond V4L2:auto] <INFO> Started
    [hyperiond JSONSERVER] <DEBUG> <JsonServer.cpp:23:JsonServer()> Created instance
    [hyperiond JSONSERVER] <INFO> Started on port 19444
    [hyperiond FLATBUFSERVER] <INFO> Started on port 19400
    [hyperiond PROTOSERVER] <INFO> Started on port 19445
    [hyperiond WEBSERVER] <DEBUG> <WebServer.cpp:96:handleSettingsUpdate()> Set document root to: :/webconfig
    [hyperiond WEBSERVER] <INFO> Started on port 8090 name 'Hyperion Webserver'
    [hyperiond HYPERION] <DEBUG> <PriorityMuxer.cpp:231:setInputImage()> Priority 0 is now active
    [hyperiond HYPERION] <DEBUG> <PriorityMuxer.cpp:330:setCurrentTime()> Set visible priority to 0
    [hyperiond HYPERION] <DEBUG> <PriorityMuxer.cpp:231:setInputImage()> Priority 254 is now active
    [hyperiond HYPERION] <DEBUG> <PriorityMuxer.cpp:231:setInputImage()> Priority 240 is now active
    [hyperiond LEDDEVICE] <DEBUG> <ProviderRs232.cpp:216:writeBytes()> 34 frames dropped
    [hyperiond WEBSOCKET] <DEBUG> <WebSocketClient.cpp:32:WebSocketClient()> New connection from ::ffff:192.168.0.3
    [hyperiond LEDDEVICE] <DEBUG> <LedDeviceAdalight.cpp:80:receivedData()> >>received 4 bytes data
    [hyperiond EFFECTENGINE] <INFO> effect finished
    [hyperiond HYPERION] <DEBUG> <PriorityMuxer.cpp:290:setCurrentTime()> Timeout clear for priority 0
    [hyperiond HYPERION] <DEBUG> <PriorityMuxer.cpp:330:setCurrentTime()> Set visible priority to 240
    [hyperiond ComponentRegister] <DEBUG> <ComponentRegister.cpp:67:componentStateChanged()> LED device: disabled
    [hyperiond ComponentRegister] <DEBUG> <ComponentRegister.cpp:67:componentStateChanged()> LED device: enabled
    

    Also there are links to docs, that are closed from guest and hasn't registration. I tried to understand what is "led layout" and I had to do it myself.

    Finally I have question most likely not related to your branch. I tried to calibrate colors and did it with one remark. Yellow color is too red, but only on two edges. And I don't know if I calibrated it wrong or not. Can led strip connection affects colors, but doesn't affect whole led brightness? If it's not connections issue, then I should do calibration for only two sides?

    Thanks.
     
    Last edited: 12 May 2019
    • Thank you Thank you x 1
  3. Paulchen-Panther

    Paulchen-Panther Active Member Developer

    Messages:
    196
    Try to execute the command several times in succession. My HDMI Capture Card brings only a useful picture after repeated executions.

    How many power supply points do you have on your led stips?

    I think that's possible.
     
  4. Paulchen-Panther

    Paulchen-Panther Active Member Developer

    Messages:
    196
    Your external device does not support the video standard option (in MJPEG mode). That's why you do not notice any change. Will try to hide this option if the device does not support it

    Can you please post your config?
     
  5. d00mw01f

    d00mw01f New Member

    Messages:
    5
    Hardware:
    RPi3, +Arduino
    Tried a lot of times, same result. May be it's because I'm not using hdmi capture card as this thread states, but simple composite video grabber with only mjpeg supported?

    1 :) But when I tested red/green/blue/white colors all is fine. Can power issue produce not-solid color when white color is ok? I mean all pixels look powered well and I can imagine problem with data signal, but why with power?

    Attached file.
     

    Attached Files: