xLightsSequencer / xLights

xLights is a sequencer for Lights. xLights has usb and E1.31 drivers. You can create sequences in this object oriented program. You can create playlists, schedule them, test your hardware, convert between different sequencers.
GNU General Public License v3.0
569 stars 211 forks source link

Skulltronix Servo Value Curves broken #1750

Closed ksjoberg closed 5 years ago

ksjoberg commented 5 years ago

When using the Servo effect to control a channel defined in the Skulltronix model setup, it does not follow any value curve set up.

From what I can gather, the Skulltronix model maps the 0.0 -- 100.0 values to a 16-bit value defined by the selected node's (pan/tilt/nod/jaw) min/max values. For instance, if I set the jaw's min-value to be 1100, and max-value to be 2000, a Value of 50.0 would set the 16-bit value pushed over E1.31 to 1550 ((2000-1100)*50.0+1100).

To Reproduce Specify that the value of a (16-bit) Servo effect should follow a Value Curve, using the Skulltronix value mapping nothing happens for the duration of the effect; the outputted 16-bit value stays constant.

Expected behavior The resulting 16-bit value pushed over E1.31 should follow the value curve set up in the servo effect.

Screenshots

Skulltronix setup First servo effect

((2200-1700)*0.693)+1700 == 2046 == 0x7fe

Second servo effect Third servo effect with value curve Value curve setup

This video shows the data sent on the wire, showing that xLights does not modify the DMX channel value according to the value curve that is set up. https://youtu.be/Q0CFuYdZlM8

Versions:

AzGilrock commented 5 years ago

I'm not at home to dig into this yet but I do notice you have it defined as a 12 channel model. I'm pretty sure when you select the Skulltronix option it prompted you to switch to defaults which should have give you a much higher number. Isn't it like 26 channels? You have the Eye L/R servo defined as channel 17 but the model only goes up to 12. I'm not sure what kind of problems that would exhibit. Also it would be easiest if you did a Tools -> Package Log Files and post that zip file so I can get your show folder and not have to try to recreate the model by typing in all the numbers.

AzGilrock commented 5 years ago

I do know that the function to import VSA files creates ramps using value curves on the Servo effect so that was working unless something changed.

ksjoberg commented 5 years ago

Yes, I will come clean and say it's not a real Skulltronix skull connected here. It's a Wemos D1 mini ESP8266 that listens on six 16-bit DMX/E1.31/sACN channels, consuming 12 DMX channels in total, driving a 3d printed thing: https://www.thingiverse.com/thing:3803762 .

You're absolutly spot on when you mention there are more channels on the default setup. I've reordered the channels, left some as they were. However, the effects fundamentally work and update the corresponding DMX channels correctly; it's only the Value Curves that doesn't reflect in the output.

The min/max values scaling was really convenient and allowed to trim the control inside xLights instead of writing corresponding code on the Arduino side.

I've packaged the stuff as requested: xLightsServoValueCurvesProblem.zip xLightsServoValueCurvesSequence.zip

AzGilrock commented 5 years ago

Ok I'll look at this later. Yes it was designed to be able to use that model with any generic servo so as long as you aren't trying to control those higher channels its probably not an issue.

ksjoberg commented 5 years ago

To test that it wasn't some odd behavior caused by accessing channels out of bound for the model, I increased the size of the E1.31 universe, increased the number of channels to default (26), did a "rerender all" and it still behaves the same (but with extra fluff in the form of empty DMX data trailing "my area of interest"...)

Thanks for offering to look into it!

keithsw1111 commented 5 years ago

I dont believe anything here has changed recently ... in fact I generally avoid touching the servo effect because i cant test it.

AzGilrock commented 5 years ago

So far what I've determined is value curves appear to work for the Servo effect in version 2018.37 and are broken in 2018.39 and up. Version 2018.38 appears unavailable for download.

AzGilrock commented 5 years ago

The other thing baffling me is the sequence I was using for testing with the I Like Nightmares song I cannot get to look like it does in the video I have on YouTube. I even went back to the 2017 version of xLights that should have been the one that saved the sequence but the animation inside xLights doesn't look correct. I can't figure out why it doesn't look like it used to but I have video proof of what it used to do. But I don't think that is related to this particular issue its just a red herring.

AzGilrock commented 5 years ago

Ok I found the problem. Keith broke it like a year ago and no one noticed till you. :)