User Tools

Site Tools


xtension_manual:controllingunits

This is an old revision of the document!


Controlling Units From Lists

The List is the main interface element in XTension for controlling of units. It offers many options and keystroke shortcuts for sending the command or setting the value that you wish.

For a simple toggle of the Unit you can use the default toggle control which will display in the Control column, If the unit has it’s Ignore Clicks In List setting turned on then the toggle will not display a paddle for you to click on, but just the current value or value label of the unit. This stops you from accidentally clicking on a unit that should not be directly controlled.

For some units a toggle might not make sense. You can change the control type displayed for a unit by changing the list control type in the Edit Unit dialog, or just control click on the Unit in any list and select a different a different List Control Type. The “buttons” control type lets you send an On or an Off regardless of the current state of the unit, The Text Field displays the current value of the unit and clicking on the table cell lets you enter a new value for the number. Pressing return, clicking away or tabbing away from the field sends the new value to the unit, pressing escape closes the edit field without sending the new value. The Popup Menu type lets you select from a list of possible values. You can define the list in the Edit Unit dialog. This is useful for devices for which text names for the different values make more sense than just a numerical value. For example a thermostat mode unit might be able to be set to Off, Heat or AC. The values you have to set that to might be 0, 1 and 2, but that doesn’t make for easy control. By creating a list of 3 entries in an HVAC Mode unit you can select from a popup of the valid values. Lastly you can also select “none” and then that unit will not display any control in this column. You can hide or show the entire control column by control clicking on the headers of the list and using the contextual menu entries for managing columns.

All of these features work the same way on the Web Interface with the exception currently of editing the layout of the list. Setup your lists the way you wish them in the App and they will be presented in the same way when you’re accessing remotely via the web remote.


You can bring up a more detailed control window for a unit in several ways. Clicking on the background of the Toggle control, on the Value column or on the unit jewel in the Name column will open the detailed controls dialog for that window. The controls displayed will depend on the capabilities of the unit and if you’ve fully expanded the window to show all controls via the disclosure triangle on the upper left hand side.



From this window you can immediately send an ON or OFF for the Unit. You can also Block or UNBlock a unit. A blocked unit will refuse to send any commands from XTension unless you use the Force On or Force Off scripting commands. It can’t stop the unit from receiving and responding to commands generated from other devices or NON-XTension interfaces to your system however, so if commands are received the state in the database is updated but no Unit Scripts will be executed for a blocked unit. By clicking the Edit button or by clicking on the Name of the Unit XTension will switch you to the Edit Unit Window for this Unit. After clicking the ON or OFF button the command is sent immediately and the window is closed.

Opening the popup control window for a Unit that is dimmable opens a similar window but with additional controls for setting the value. A vertical slider is added to the window for quickly sending a new dim value. The new value is sent as soon as you let go of the slider but no attempt is made to send continual commands as you drag it up and down. For most dimmable units the slider limits are 0 and 100%. If the Unit is a “Register” type with a min/max value set or other Unit type that supports the min/max settings then those will be reflected in the sliders top and bottom values. For more precise value entry, perhaps for a thermostat setpoint, or one that requires a decimal point you can type directly into the Value field and click the Set button or press Return.

If you have set the list control type to a popup, then instead of the standard value field you’ll get a popup of the value choices you entered on the edit unit dialog page.







If you click the disclosure triangle in the upper left hand corner of the popup control window it will show even more controls for the Unit. First you’ll notice a more detailed status display at the top with the last activity of the unit, it’s current value and it’s description, if any is set. Below that there are more buttons for quickly controlling to a specific level in just a single click or increasing and decreasing the values by specific amounts. The expanded or hidden value for these controls is remembered on a Unit by Unit value for each List so if you always control a unit with the expanded popup display it will remember that but you won’t have to see all the extra controls for units for which you rarely use them. The next time you open the Popup Control window for a unit it will be in the same state you last used it.

The next set of controls is for creating events that will set the Units value at some point in the future or for some period of time. These are basically the same as the optional “in” and “for” parameters of the Set Value, Turn On and Turn Off verbs. Each value has a time field where you can enter some number and a time descriptor popup that tells XTension what the number in the first field corresponds to. The values are seconds, minutes, hours and days for each. If you set either or both of these controls and then click the ON/OFF or SET buttons above one or more Scheduled Events will be created for the Unit that will perform the requested action in the requested amount of time. If you also specify a “For” parameter then a second event is created that returns the Unit to the state it is right now in the requested interval. If the unit is already on and you use this to turn on in 10 seconds for 10 seconds the return event will return this this state, which is already on, so nothing will actually happen as far as the light is concerned.

Lastly this also adds the “Remove Events” button. This will remove any events that were added to the unit via the “in” and “for” interface elements or via the “in” or “for” parameters of the unit control verbs. It will not remove scheduled events created specifically for the unit, only those created automatically via this mechanism.

If the Unit you’re controlling has other supported features the controls for those will also be displayed in the popup control window. In this example we’re controlling a Phillips Hue Color Bulb through our connection to a Hue Hub. All the color controls are available. You’ll see a best approximation of the current color of the bulb in the upper right of the window. There will also be an indication if the bulb is in Color Temperature mode as in the case of the example a small “w” is displayed to show this is a white color temperature. If a color is being displayed then a small “c” will be drawn in the same place. Clicking on this color will bring up the system color picked for you to choose a new color for the lamp. By hovering your mouse over the color a tool tip will display that shows either the RGB color information or the approximate color temperature that the bulb is displaying.

Below the “in” and “for” section a color control section will be displayed for color capable devices. Changes to the RGB sliders will be sent immediately to the lamp when you let go of the slider. To the right of those are the color presets for the Unit. They will also indicate if they are storing a color by showing a small “c” in the corner or a white color temperature by displaying a “w”. If the device is not capable of both kinds of color no indicator will be displayed. Clicking the color preset sends that color to the device. If you have changed the color of the bulb via the RGB sliders or the color temperature slider you can program the new value into a preset by control or right clicking on the preset you wish to change and selecting “set this preset from the current color” from the contextual menu. Most color capable devices process color separate from value and so the color as displayed in the preset may not accurately reflect what is actually coming from the device. An RGB color value includes the brightness level, but only the color is actually sent to the device and the brightness will remain as it’s currently set so the color may be different. While this may not immediately be the obvious way it should work on further reflection I agree with it. If you have a light level set dim and you select a color you really don’t want the bulb to go to full brightness, you want it to change the color and remain at approximately the same brightness level. You can always dim or brighten the bulb to a new level after sending the color, of if you’re setting the state from a script you can include the brightness and color at the same time via the Dim command.

If the device supports changing color temperature then the color temperature slider will be displayed next. Changes to the bulb color are sent immediately as soon as you let go of the slider.

xtension_manual/controllingunits.1523328233.txt.gz · Last modified: 2023/02/13 14:51 (external edit)