say(String text, String voice, String device): Text-to-speech with a given voice to the given output device (only supported on Mac OS).say(String text, String voice): Text-to-speech with a given voice (depends on the TTS engine or voices installed in the OS).say(String text): Says the given text through Text-to-speech.playStream(String url): Plays the audio stream from the given url.playSound(String filename): Plays the given file (must be mp3 or wav and be located in $/sounds).float getMasterVolume(): Returns the volume with the range 0-1.decreaseMasterVolume(float percent): Decreases the volume by x percent.increaseMasterVolume(float percent): Increases the volume by x percent.setMasterVolume(float volume): Sets the volume of the host machine (volume in range 0-1).If it is no valid command, the item state is directly updated to the saved value. If the saved state can be interpreted as a command, a command is sent for the item (and the physical device can send a status update if occurred). restoreStates(Map statesMap): Restores item states from a map.Group items are not themselves put into the map, but instead all their members. items): Stores the current state of a list of items in a map which can be assigned to a variable. Your rules can trigger on items receiving commands, items' states updating, or items' states changing to a different value. Commands can also be sent other ways, such as the REST API and CMD servlet. items file if autoupdate="false" is present). Usually this causes the state of the item to update automatically at the same time (using the default autoupdate feature, but there are cases where autoupdate is not performed, depending on the binding or configuration in your. When you click on buttons, sliders or other widgets in the UI, that sends commands to items. If your items' states are not being updated by a binding, the autoupdate feature (see below) or something else external, you will probably want to update the state in a rule, using postUpdate. If you want to tell something to change (turn a light on, change the thermostat to a new temperature, start raising the blinds, etc.), then you want to send a command to an item using sendCommand. nd(Command command_to_send): sends the given Command (ON/OFF/etc.) to every item in the group.postUpdate(String itemName, String stateString): Posts the given status update for the specified item to the event bus.sendCommand(String itemName, String commandString): Sends the given command for the specified item to the event bus.Here is the list of available actions in the core runtime: Event bus related actions Since openHAB 1.3.0, not all actions are part of the core runtime distribution anymore, but it is possible to easily implement add new actions to your runtime (see the developer section for details). Items, Rules and more Examples of a SmartHomeĪctions are predefined Java methods that are automatically statically imported and can be used within Scripts and Rules to execute openHAB specific operations.Item definition examples Sitemap definition examples Please update the wiki if you do come across any out of date information. Be aware that things may have changed since they were written and some examples might not work correctly. Feature overview Installation Setup intro Linux and OS XĪ good source of inspiration and tips from users gathered over the years.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |