Jump to content
C4 Forums | Control4

Recommended Posts

Posted

Hello, im trying to do my first bit of programming and could do with some help. I have an outbuilding that my wife is going to start using to do some therapy treatments. I have wrote a macro named “treatment” and mapped it to the custom button on the sr260 when activated this shows a pop up on the tv, activates sonos playlist, turns the touchscreen brightness to 10% and ramps a few different lights to low levels.

  I want to be able to activate this from the custom button on the remote, the tv and touchscreen UI. Also when the scene is invoked is there any way to stop it and return everything back to previous state (as i have to manually turn screen brightness back up) or would i be best writing a treatment finished macro? Also am i better just adding the light functions to the macro or doing a lighting scene and adding that to the macro?  Many Thanks 

 


Posted

For the onscreen navigator and touchscreen you could use an experience button to engage/disengage a boolean variable called 'treatment mode' This experience button would just toggle the boolean state between true and false states. For the SR260 you could use the custom buttons agent to create two custom buttons ,one to enable treatment mode and the other to disable, alternatively you could just use the custom button you are already using just to toggle the treatment mode on or off.

You would also then use the Snapshot driver at the start of the 'treatment' macro you have written to record the current state of lights etc in the room.

Then in programming, program against the 'treatment mode' variable changing. When it is true, it runs your 'treatment' macro, when it is false you would run another macro using the snapshot driver to restore the previous state of lights, setting the screen brightness back up etc.

Personally, I would create a lighting scene to set all the lights to the desired level, much more efficient programming wise.

This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.