Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Automatic signal recognition causes LED to be stuck some time #407

Closed
Duese123 opened this issue Nov 9, 2022 · 31 comments · Fixed by #410
Closed

Automatic signal recognition causes LED to be stuck some time #407

Duese123 opened this issue Nov 9, 2022 · 31 comments · Fixed by #410
Labels
bug Something isn't working

Comments

@Duese123
Copy link
Contributor

Duese123 commented Nov 9, 2022

https://pastebin.com/h9VfTBj5
https://youtu.be/oqHlRWs-t08

Bug report, debug log and your config file (FULL LOGS ARE MANDATORY)

Steps to reproduce

PS5 go to GameMenü and back to Game like for 10 times OR
Sometimes while TV especially with Strong parts of Black like in comercial changes causes also the problem

What is expected?

Lights working flawlessly

What is actually happening?

Lights are stuck for 1-2 seconds. For example in comercial is ending and New ones began the colors are off 1 second. Or in Game Menü PS5 are stuck shortly go off directly again back on
It turned out that is coming due to having signal recognition Set to on. (IT is calibrated during Black screen). Function itself working very good and turns leds off and grabber to low fps grabbing but seems to sometime realize it as Output is off though the picture is in full screen with color. Picturefreeze will not cause into this. Was also present in V18. Manual recogniton is working bit will not reduce Grabber framerate

System

HyperHDR-Status:
An
Plattform:
Linux (V4L2)
Videogerät
USB3. 0 capture: USB3. 0 captur (video0)
Video Modus
800x600x60 MJPEG
Controller-Typ:
apa102
Beispiel:
LEDs_Fernseher
Ihre HyperHDR-Version:
19.0.0.0beta1
Neueste HyperHDR-Version:
v19.0.0.0beta1

@awawa-dev
Copy link
Owner

awawa-dev commented Nov 9, 2022

Hi
I saw something disturbing in your logs. Please test new installers from GA https://github.com/awawa-dev/HyperHDR/actions/runs/3432169574 when completed. If that won't help please provide new logs including 'signal detected/lost' events (and please disable blackborder detection if it's enabled for diagnostic process).

@Duese123
Copy link
Contributor Author

Duese123 commented Nov 9, 2022

Okay
-> New version flashed (reinstall option)
-> deactivated black border detection

Problem is still there and reproducible. If iam some time in the game Menü and nothing changed (like 5 seconds) and go back to game the LEDs turning off and on again.

Log -> https://pastebin.com/tF7VxQD0

Edit: i took also a Look onto live capturing and the screen is stuck for that moment where the LEDs turned off.
So for that Moment i exit the Menü (with no changing content) the frame decimator Set to higher Level and the signal is lost for one sec (according to log)

@awawa-dev
Copy link
Owner

Could you post 'about' page screen shot (with a HyperHDR commit hash)?

@Duese123
Copy link
Contributor Author

Duese123 commented Nov 9, 2022

Screenshot_20221110_004303_Chrome

@awawa-dev
Copy link
Owner

thanks

2022-11-09T23:19:24.239Z [SIGNAL_AUTO] No signal detected. The cognition model's probability: 99%
2022-11-09T23:19:29.788Z [SIGNAL_AUTO] THE SIGNAL IS LOST
2022-11-09T23:19:30.038Z [SIGNAL_AUTO] Signal detected. The cognition model's probability: 70%
2022-11-09T23:19:31.041Z [SIGNAL_AUTO] THE SIGNAL IS RESTORED

2022-11-09T23:19:34.100Z [SIGNAL_AUTO] No signal detected. The cognition model's probability: 100%
2022-11-09T23:19:39.332Z [SIGNAL_AUTO] THE SIGNAL IS LOST
2022-11-09T23:19:39.702Z [SIGNAL_AUTO] Signal detected. The cognition model's probability: 86%
2022-11-09T23:19:40.703Z [SIGNAL_AUTO] THE SIGNAL IS RESTORED

2022-11-09T23:19:42.344Z [SIGNAL_AUTO] No signal detected. The cognition model's probability: 99%
2022-11-09T23:19:48.862Z [SIGNAL_AUTO] THE SIGNAL IS LOST
2022-11-09T23:19:49.367Z [SIGNAL_AUTO] Signal detected. The cognition model's probability: 100%
2022-11-09T23:19:50.699Z [SIGNAL_AUTO] THE SIGNAL IS RESTORED

Did you set sleep signal for ~5 seconds and wakeup time ~1 time?

@Duese123
Copy link
Contributor Author

Duese123 commented Nov 9, 2022

Yes indeed

@awawa-dev
Copy link
Owner

awawa-dev commented Nov 9, 2022

not sure why it immediately wakes up but there is something on the input that fits the model. When you disable 'power saving' option for automatic signal detection it works fine?

@Duese123
Copy link
Contributor Author

Duese123 commented Nov 9, 2022

For calibration I was turn off the input from the Switch (changed input on avr) then All goes to black and i clicked on calibration (leds turning then on flickering during calibration and going back off).. when i now shit down the signal detection works well and turn the LEDs off and also back on again

@Duese123
Copy link
Contributor Author

Duese123 commented Nov 9, 2022

Power saving -> off
Behavior still the same
After 5 sec wait time in the menu led as device is normal on and grabber is working at 60 fps. Is is just after havin other picture -> signal lost recognition is toggled once

I made a Video https://youtube.com/shorts/KvIy_fRTIe4?feature=share

@awawa-dev
Copy link
Owner

awawa-dev commented Nov 10, 2022

i clicked on calibration (leds turning then on flickering during calibration and going back off).

the LED shouldn't be flickering during your calibration

2022-11-09T21:06:11.113Z [SIGNAL_AUTO] (DetectionAutomatic.cpp:273) Capturing SDR frames
2022-11-09T21:06:11.314Z [IMAGETOLED0] Total index number is: 39544 (memory: 39544). User sparse processing is: disabled, image size: 800 x 600, area number: 338
2022-11-09T21:06:12.777Z [V4L2:USB3. 0 CAPTUR] (V4L2Grabber.cpp:125) setHdrToneMappingMode to: Fullscreen
2022-11-09T21:06:12.777Z [V4L2:USB3. 0 CAPTUR] (V4L2Grabber.cpp:131) setHdrToneMappingMode replacing LUT and restarting
2022-11-09T21:06:12.777Z [V4L2:USB3. 0 CAPTUR] (V4L2Grabber.cpp:105) LUT folder location: '/usr/share/hyperhdr/lut'
2022-11-09T21:06:12.778Z [V4L2:USB3. 0 CAPTUR] (Grabber.cpp:445) LUT file found: /home/pi/.hyperhdr/lut_lin_tables.3d
2022-11-09T21:06:12.778Z [V4L2:USB3. 0 CAPTUR] (Grabber.cpp:455) Index 1 for HDR YUV
2022-11-09T21:06:12.848Z [V4L2:USB3. 0 CAPTUR] Found and loaded LUT: '/home/pi/.hyperhdr/lut_lin_tables.3d'
2022-11-09T21:06:12.849Z [SIGNAL_AUTO] (DetectionAutomatic.cpp:323) Waiting for first HDR frame
2022-11-09T21:06:12.849Z [COMPONENTREG0] HDR (global): enabled
2022-11-09T21:06:13.363Z [SIGNAL_AUTO] (DetectionAutomatic.cpp:281) Capturing HDR frames
2022-11-09T21:06:15.027Z [SIGNAL_AUTO] (DetectionAutomatic.cpp:361) The calibration succeed. The cognition model quality is 100%. Got 322 SDR test points (from 322) and 322 HDR test points (from 322).

there is no information about turning on/off LED. Probably it's a grabber issue. The image should be static (confirm in the preview) and no flickering of LED should happen.

@awawa-dev
Copy link
Owner

There was potential issue in the code before, now I think it's something with your calibration model.

@awawa-dev
Copy link
Owner

You also may lower tolerance for the automatic signal detection (it's 9 now)

@Duese123
Copy link
Contributor Author

Duese123 commented Nov 10, 2022

I can confirm that the problematic is only there if hdr is active (with this signal lost issue)

Regarding calibration: before Calibration black screen as expected. But during i found out it is showing some Strange points.

Screenshot_20221110_011344_Chrome

@awawa-dev
Copy link
Owner

That points on the image are normal during the calibration: it shows test points that it captures.

@awawa-dev
Copy link
Owner

First we measure test board with hdr off, then with hdr on. So later when the signal detection works it selects proper set of captured points set. hdr mode increases black level usually. Set tolerance to 1 or 2.

@Duese123
Copy link
Contributor Author

Duese123 commented Nov 10, 2022

So iam assuming everything is normal
Except that after some time with same picture and then moving the picture the algortihm is shortly recognizing an led off signal and toggling it directly back on. I checked this with standby pic (menu) theled device is normal active and grabber is normal grabbing at 60 fps

It is only occuring with HDR activated. Lut file for MS2109 is also used and the 1 / 128 / 128 setting.

@awawa-dev
Copy link
Owner

You did a calibration for these settings

2022-11-09T20:51:52.343Z [V4L2:USB3. 0 CAPTUR] Set framerate to 60 FPS
2022-11-09T20:51:52.343Z [V4L2:USB3. 0 CAPTUR] Brightness set to: -11 (default)
2022-11-09T20:51:52.343Z [V4L2:USB3. 0 CAPTUR] Contrast set to: 148 (default)
2022-11-09T20:51:52.343Z [V4L2:USB3. 0 CAPTUR] Saturation set to: 180 (default)

@Duese123
Copy link
Contributor Author

I made a New one.. still the same. Also with 1% tolerante the problem is there... i have to revise my notice. Problem is also there with HDR off.
The grabber will be turned off after you go out of the game menu...and will be directly turned on

@awawa-dev
Copy link
Owner

awawa-dev commented Nov 10, 2022

If you have MS2109 then the no-signal board should be a rainbow: no black screen visible on your screenshot from calibration.

@awawa-dev
Copy link
Owner

This is MS2109 no signal board:
https://i.postimg.cc/63fc3MKn/automatic3.jpg

@Duese123
Copy link
Contributor Author

I think it becomes a black screen from AVR.
I connected to second Monitor out a splitter to simulate edid. And then to Macrosilicon. HDR, Dolby Vision everything is working fine. Colors are good. If i turn of leds are going to black AND it recognize screen of so also it deactivating led device in HyperHDR and also grabber reduces framerate as expected.

There should be an problem with maybe no changing pictures -> changing pictures it triggern the signal lost recognition once....

@awawa-dev
Copy link
Owner

I think you should watch live preview and the log tab at the same time. Notice what you have in the live preview when the no signal/signal restore appear. There is an option for log auto-scrolling that can help.

@Duese123
Copy link
Contributor Author

Duese123 commented Nov 10, 2022

Oh gosh... it turned out i have 1080p grabber and ms2109 is 4k right?
https://www.berrybase.de/usb-hdmi-video-grabber-1080p
Not sure which Chip is inside.. i removed the cable and it shows a Black screen!

Question is of course makes this a difference? I thought it will "learn" the picture for turn off...

Edit: when the problem appears the picture from live screen is stuck for that moment where the signal says it is lost.

Without signal detection there are no problems

Edit2: Nah should be MS2109... 1080p is Output.. it is confusing named:-)

@awawa-dev
Copy link
Owner

your grabber is also 4k, but modified and fake USB3.0. Typical MS2109 should send us rainbow no-signal board, not sure what happen with your grabbers: maybe it stops capturing at all? Probably you should also calibrate your own LUT table.

@Duese123
Copy link
Contributor Author

I had my own lut before. Used a picture from grabber for generating. Almost no difference beteeen HDR and non HDR Also with the ms2109 LUT. I Red somewhere it should be also ms2109 and it is also saying that on the webpage.

It never has These rainbows. Checked this again. Grabbing ist still there without cable but picture is getting black.

Then i have to deactivate this signal Thing. Seems to have problems with black calibrated shutdown pictures. The grabbing in the menu is working normal just after go outside it is the wake time. Also had this in Television commercial sometimes leds are off according to that wake time.. if i set this to 0 there is no offtime. But you can See in log that signal lost is triggered.
Not sure if this is now a Bug or has something to Do with grabber...

Btw: can i make the Translation for germany? There are some words completely strange :)

@awawa-dev
Copy link
Owner

awawa-dev commented Nov 10, 2022

Almost no difference beteeen HDR and non HDR

You should not use HDR option at all. Probably you are receiving SDR signal and HDR tone mapping will break some things. Not sure if the signal detection is affected but it's not it was designed for. I assure you, than you would see the difference on captured HDR source without tone mapping.

Also

I connected to second Monitor out a splitter to simulate edid. And then to Macrosilicon. HDR, Dolby Vision everything is working fine

MS2109 nor any other USB grabber is not capable of capturing real DV. So probable something in between is doing something to the video signal.

Btw: can i make the Translation for germany? There are some words completely strange :)

Sure :) Automatic translation sometimes provides strange result: for example ms (milliseconds) was translated in previous version to Frau ;) Open pull request and I update the resources. https://github.com/awawa-dev/HyperHDR/blob/master/assets/webconfig/i18n/de.json

@awawa-dev awawa-dev added the bug Something isn't working label Nov 10, 2022
@awawa-dev
Copy link
Owner

awawa-dev commented Nov 10, 2022

I have found another unpatched route and fixed it now. Also I managed to replicate the behavior from your logs using video camera. Definitely it's a bug, I described the behavior in: #410 and at least it fixed the bug for me. BTW try to setup 'wake up' and 'sleep time' equal or above 5000ms and control HyperHDR behavior using its video live frame window and 'logs' tabs: just as I described before.

Installers: https://github.com/awawa-dev/HyperHDR/actions/runs/3438779116

@Duese123
Copy link
Contributor Author

Nice to hear that #

You should not use HDR option at all. Probably you are receiving SDR signal and HDR tone mapping will break some things. Not sure if the signal detection is affected but it's not it was designed for. I assure you, than you would see the difference on captured HDR source without tone mapping.

maybe i explained a bit wrong was late yesterday... So i receiving an SDR signal which is okay. When i receiving an HDR signal the coloros are washed out and i programmed an script that readout from Denon AVR the stream If HDR is recognized HDR global will be activated over Json RPC in HyperHDR which is working pretty fine. Also for Dolby Vision it is working (not pink). I connected to second Monitor out from AVR a Splitter from Xolor which simulates EDID and then the grabber so that the AVR never will change Monitor 1 (where TV is connected)

MS2109 nor any other USB grabber is not capable of capturing real DV. So probable something in between is doing something to the video signal.

Yes i know it should be the AVR :-) it will priorize the DV to Monitor1 only. The grabber becomes a washed out picture i think (not tested in deep)

Definitely it's a bug

ah great that you got it!

what i not exactly understood. You have a lut for this MS2109
image
do i have to config this when HDR is active or SDR?

@awawa-dev
Copy link
Owner

awawa-dev commented Nov 10, 2022

maybe i explained a bit wrong was late yesterday... So i receiving an SDR signal which is okay. When i receiving an HDR signal the coloros are washed out and i programmed an script that readout from Denon AVR the stream If HDR is recognized HDR global will be activated over Json RPC in HyperHDR which is working pretty fine. Also for Dolby Vision it is working (not pink). I connected to second Monitor out from AVR a Splitter from Xolor which simulates EDID and then the grabber so that the AVR never will change Monitor 1 (where TV is connected)

Ok, now it's clear to me :)

Yes i know it should be the AVR :-) it will priorize the DV to Monitor1 only. The grabber becomes a washed out picture i think (not tested in deep)

I have some suspicions... maybe DV is working in LLDV mode? It should behave as HDR10 and also there is no pink saturation side-effect.

do i have to config this when HDR is active or SDR?

Always. For SDR and HDR. There were some articals about MS2109 & SDR ( https://ciko.io/posts/cheap_usb_hdmi/ ) but I measured it using automatic calibration and it works also for HDR with minimal error. You can experiment and fine tune these settings to achieve even better results.

@Duese123
Copy link
Contributor Author

I have found another unpatched route and fixed it now. Also I managed to replicate the behavior from your logs using video camera. Definitely it's a bug, I described the behavior in: #410 and at least it fixed the bug for me. BTW try to setup 'wake up' and 'sleep time' equal or above 5000ms and control HyperHDR behavior using its video live frame window and 'logs' tabs: just as I described before.

i installed the version and it is working fine right now. No shutoff any more! Great!! Thanks a lot

@awawa-dev
Copy link
Owner

Great. I give it some time before I merge the fix. Thank you for proofreading the translation 👍 Also will be included in final v19.

@awawa-dev awawa-dev linked a pull request Nov 10, 2022 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants