bitfocus / companion

Bitfocus Companion enables the reasonably priced Elgato Stream Deck and other controllers to be a professional shotbox surface for an increasing amount of different presentation switchers, video playback software and broadcast equipment.
http://bitfocus.io/companion
Other
1.61k stars 503 forks source link

[Request] Background Blinking #674

Open cgarwood opened 5 years ago

cgarwood commented 5 years ago

Describe the feature The ability to set the background and/or foreground colors to blink between two sets of colors. Bonus if we can configure the speed at which it changes.

Is this platform dependent (windows, mac, ..)? no

If documentation is required to implement, do you know where to find it? n/a

Usecases If you're recording or streaming and want to draw more attention to that fact, you could have the background of the recording button blink between black and red.

Blinking the button for an input that's currently live on a switcher

Drawing attention to something that's in an error state.

etc.

Fred-DTV commented 4 years ago

Just somer more usecase examples:

plasticpool commented 3 years ago

I agree with all the use cases here – just knowing that a microphone channel is open (or not) with a flashing/blinking button state would be super helpful, and I'd be happy to contribute to a bounty toward implementing this.

mdgnys commented 3 years ago

A great way to accomplish this would be a module that supplies instance feedback that is simply a constantly switching Boolean back and fourth.

shaunar2006 commented 3 years ago

This would be awesome! I need this!

justingiffard commented 2 years ago

This would really be awesome, from a dev point of view it would be cool if there was a way to specify the frequency of the flashes too. I'd like to add feedback to the X32 module for the tap delay that it gives the user a visual idea of what the delay is like the tap delay on the console

actually thinking of coding something in the module which changes the feedback at the specified frequency but that code could get ugly

HaxNobody commented 2 years ago

Here's how I implemented blinking buttons:

  1. Set up a new custom variable, let's call it "Flash" for now. You should be able to use the same variable for multiple different buttons, and you can create more variables for different flash patterns.
  2. Set up a trigger that is also called Flash or something similar, and configure the Condition to be Time Interval
  3. Set the time interval to 1 (seconds)
  4. Tick the "Relative Delays" box
  5. Add an Action for "internal: Set custom variable value", configure the Delay to 500ms, select your custom variable, and set the Value to 0
  6. Add another Action the exact same as step 5, but set the Value to 1
  7. Configure your button to add a Feedback of "internal: Check variable value" and set it to your custom variable, with default '=' Operation and the Value as 1.
  8. Finally, configure the text color and background color that you want to switch to with each flash, different from the initial setting at the top of the button config.

Done - you can adjust all the trigger timings to make your flasher work the way you want it to.

codered11343 commented 2 years ago

Here's how I implemented blinking buttons:

  1. Set up a new custom variable, let's call it "Flash" for now. You should be able to use the same variable for multiple different buttons, and you can create more variables for different flash patterns.
  2. Set up a trigger that is also called Flash or something similar, and configure the Condition to be Time Interval
  3. Set the time interval to 1 (seconds)
  4. Tick the "Relative Delays" box
  5. Add an Action for "internal: Set custom variable value", configure the Delay to 500ms, select your custom variable, and set the Value to 0
  6. Add another Action the exact same as step 5, but set the Value to 1
  7. Configure your button to add a Feedback of "internal: Check variable value" and set it to your custom variable, with default '=' Operation and the Value as 1.
  8. Finally, configure the text color and background color that you want to switch to with each flash, different from the initial setting at the top of the button config.

Done - you can adjust all the trigger timings to make your flasher work the way you want it to.

Thank you. This was exactly the guidance I was looking for. But to go a step further, would it be possible to make it so that button paused its flashing after the button was pressed, then resumed flashing after it hadn't been pressed after a certain amount of time? Like 5 minutes? If this is currently possible, how would you program that?

bob454522 commented 1 year ago

Here's how I implemented blinking buttons:

...

8. Finally, configure the text color and background color that you want to switch to with each flash, different from the initial setting at the top of the button config.

Done - you can adjust all the trigger timings to make your flasher work the way you want it to.

Thanks for posting this, i dont understand how Companion has added so many features in the past 12 months, but is silent on this one (blinking buttons) - seems like a pretty critical feature in terms of production surfaces.

that said, i do have this work around , working, however im not clear on how you control if the button should be blinking or not-blinking. ie- i have the button blinking, but the only way a see to control weather it blinks or not is to add another action to enable or disable the trigger (ie the trigger from step #2) , is this correct?

thanks

dnmeid commented 8 months ago

I think I just had an idea how we could implement this request in a flexible and useful way. At the moment we have the checkbox to invert boolean feedback. We could replace this checkbox by a dropdown with some additional feedback behaviors:

So users have control of what element should blink, eg. background color or an image or text. Users will not have total control over blink frequency, instead all blinks are done in synchronized groups, leading to a less distractive surface. Maybe we make the three frequencies customizable in user preferences.

Current checkbox state can be upgraded to normal and inverted behavior.

Julusian commented 8 months ago

I'm not convinced that this should replace the invert checkbox, but having something in that left panel between that and the change style properties field would make sense. image

My reason being that the invert box is part of the boolean feedbacks, which also gets used in the conditions for triggers, and eventually will be part of #1052 and #372, and having to handle a checkbox in some places and a dropdown in others will make everything more complicated.
And I think if it is combined there would be more dropdown options too, such as blinking slow inverted for when you want it to be blinking when the feedback is false. everything would probably need an 'inverted' version, at which point having a separate checkbox might be simpler to understand.

sackboydad commented 6 months ago

Here's how I implemented blinking buttons:

  1. Set up a new custom variable, let's call it "Flash" for now. You should be able to use the same variable for multiple different buttons, and you can create more variables for different flash patterns.
  2. Set up a trigger that is also called Flash or something similar, and configure the Condition to be Time Interval
  3. Set the time interval to 1 (seconds)
  4. Tick the "Relative Delays" box
  5. Add an Action for "internal: Set custom variable value", configure the Delay to 500ms, select your custom variable, and set the Value to 0
  6. Add another Action the exact same as step 5, but set the Value to 1
  7. Configure your button to add a Feedback of "internal: Check variable value" and set it to your custom variable, with default '=' Operation and the Value as 1.
  8. Finally, configure the text color and background color that you want to switch to with each flash, different from the initial setting at the top of the button config.

Done - you can adjust all the trigger timings to make your flasher work the way you want it to.

Hi! Hope you're still responding to this thread. I implemented your procedure and it's great! But, how can I make a button blinking conditional? For example, I have a button that mutes a channel on my audio mixer. Right now I use a feedback that is designed to just change the background color if muted. Using your procedure how can I turn that into a blinking button? Thanks!

Donaldini commented 6 months ago

@sackboydad You can change the Trigger to add a conditional. Your trigger would then no longer be universal for everything, but it works.

I just created a button that will blink whenever i'm injecting too much solar power into the grid and another for when my electric cars battery falls below a certain percentage encouraging me to connect it to the charger.

@HaxNobody thanks for this tutorial!

sackboydad commented 6 months ago

@sackboydad You can change the Trigger to add a conditional. Your trigger would then no longer be universal for everything, but it works.

I just created a button that will blink whenever i'm injecting too much solar power into the grid and another for when my electric cars battery falls below a certain percentage encouraging me to connect it to the charger.

@HaxNobody thanks for this tutorial!

Thank you. I’m not the best on Companion is there any chance you have the time to show me how to put what you suggested in companion? Thank you very much

Donaldini commented 6 months ago

Sure, here's a screenshot of my Trigger:

image

I used a Check boolean expression because I needed to cast a variable coming from my Home Assistant environment to a Number (it was a string). The rest of the expression is to check whether the surplus value of my home electrical grid is below the value -4. This means that i'm using a negative of 4kW of electricity in my house OR simply put i'm injecting more than 4kW to the grid instead of using it. Time to do some laundry or charge the car ;-)

sackboydad commented 6 months ago

Sure, here's a screenshot of my Trigger:

image

I used a Check boolean expression because I needed to cast a variable coming from my Home Assistant environment to a Number (it was a string). The rest of the expression is to check whether the surplus value of my home electrical grid is below the value -4. This means that i'm using a negative of 4kW of electricity in my house OR simply put i'm injecting more than 4kW to the grid instead of using it. Time to do some laundry or charge the car ;-)

One more question... I PROMISE I'm not going to become a leech bugging you! Once I get pointed in the right direction I'm pretty good...... We use a WING audio mixer, whose Companion module isn't the best. It does have a published exhaustive set of OSC commands. I have successfully used the customer command in a button on Companion to issue a OSC command. Looking at your settings, I see that I would use the trigger condition to decide if something blinks. But when I try to set a condition on our WING mixer, it says there aren't any. I see you used an expression of some kind to see about your charger level. Would there be a way to use an OSC command or inquiry in the trigger condition? Here is an example of an OSC command that would either set or show the fader level of Bus1's Fader. How would you put that (or can you) into a trigger condition? I SWEAR no more questions!

OSC: /bus/1/fdr (the number range is between -144 and +10

Thank you!

Donaldini commented 6 months ago

No problem at all, happy to help.

I don't have a Behringer Wing, but when I look at the documentation inside companion I see that there are some dynamic variabels and feedback variables available that might help you. See here:

image

image

I think you need to use one of these variables:

I'm not entirely sure I understand your question correctly, but here's a go: For example if you want to use that level to determine whether or not to let a button blink you could use my expression and change it to: _+$(INSTANCENAME:{Strip}d) > -10 (for letting it blink when it gets too loud)

sackboydad commented 6 months ago

Thank you so much. Even if this doesn't work I have learned a whole lot! I will try it out. True to my word, I won't bug you any more about this, short of letting you know if it worked.

whopkinscom commented 5 months ago

I use generic-blink module to achieve this. image For example When I change a camera input on ATEM I reset and start a timer. The feedback on my camera buttons will utilise generic-blink if the timer has passed say 2 minutes to remind me I haven't switched cameras in 2 mins so maybe I want to think about that? image

NoSloppy commented 5 months ago

I use generic-blink module to achieve this.

I don't understand how to set this up. Could you explain? Thanks. I don't find generic blink anywhere.

Edit - found it. It's a new Connection.