psieg / Lightpack

Lightpack and Prismatik open repository
GNU General Public License v3.0
1.57k stars 188 forks source link

Turn on lights initially for white balance #123

Open dmadison opened 7 years ago

dmadison commented 7 years ago

At the moment, the lights are turned off in the setup wizard while the grab zones are re-arranged, but they are not re-enabled during the white balance adjustment (#95) unless one of the color sliders is moved.

It would be a nice quality of life change if the lights were enabled with the current calibration before the sliders are changed.

psieg commented 7 years ago

The thing is that there is no such thing as a global white balance. In reality, every grab zone has its own. Thus, when the wizard is started (unless all have the same value) there is no "old value"

dmadison commented 7 years ago

Right, but earlier in the wizard you select the profile to either create or modify. So the lights can be enabled with either the pre-existing values in the profile or using 100% on all channels. There's no reason the sliders need to move for the lights to come on.

psieg commented 7 years ago

So you're saying the lights do not turn on when the White Balance Page opens?

dmadison commented 7 years ago

Yes.

psieg commented 7 years ago

...with an Adalight device, right? That is weird, it works with my Lightpack(s)... Not sure how to further investigate this...

dmadison commented 7 years ago

Yes, with an Adalight device. I hooked up the logic analyzer again, and it seems that the lights are sent a few frames of color data when the wizard switches to the "White Balance" page. But all of the color information is '0'. Perhaps related to #124?

psieg commented 7 years ago

Afaik it always sends the maximum of led colors in the wizard. Are the first few ones white or are all of them black? Can you reproduce the problem with a brand new config (just rename all config files)?

dmadison commented 7 years ago

All of them are black. I just tested with a brand new config (renamed the "Prismatik" folder). A properly formatted frame of 255 LEDs is sent but all of the color data is '0' for all channels.

psieg commented 6 years ago

@dmadison does this still happen? With 5.11.2.14 it should send the correct number

dmadison commented 6 years ago

Just checked using a logic analyzer with 5.11.2.15: yes, this still happens. The correct number of LEDs is sent, but the initial frames are pure black.

psieg commented 6 years ago

I just debugged through the steps again. Yes, the first set of colors sent are in fact black (when settings are written they are applied to the current colors, which are black at the end of the configure device page), but the last frame does contain white colors, even without touching the sliders.

Can you confirm this?

dmadison commented 6 years ago

Confirmed. Testing with 5.11.2.17 and 10 LEDs, upon entering the calibration wizard Prismatik sends 6 frames of color data. The first 5 are black, and the sixth is white.

Unfortunately the frames are queued immediately after one-another, so the device drops every other frame (#117). Including the last one with the white color data :anguished:.

psieg commented 6 years ago

5216115138e0a9b4898ee4b2d281d00063ee793a should reduce that to two, but this probably won't even help if every other frame is dropped

psieg commented 5 years ago

@dmadison can you still reproduce this?

dmadison commented 5 years ago

Yes, just tried with the latest version (e8f12bb, building from source). When the wizard loads the white balance page it sends 6 frames to the device. The first 5 are black, the 6th is white.