Wiki source code of TCP Interface
                  Version 5.1 by Mark Kohlmann on 2024/02/27 21:58
              
      Show last authors
| author | version | line-number | content | 
|---|---|---|---|
| 1 | Coeus can accept commands via TCP. Feedback is provided if subscribed. | ||
| 2 | |||
| 3 | ==== Command Format ==== | ||
| 4 | |||
| 5 | Commands are sent to objects by GlobalId followed by the Action and then any relevant Properties (Properties are interpreted in the order shown). They are dot delimited and terminated with a carriage return. | ||
| 6 | Format: ##GlobalId.ActionName[.ActionPropertyValue]\x0D## | ||
| 7 | |||
| 8 | The Global ID may be found on the UI using the “i” button. Global Actions use a GlobalId of 0. | ||
| 9 | |||
| 10 | [[image:image.jpeg]] | ||
| 11 | |||
| 12 | Example Recall Scene 1 on Area 51: | ||
| 13 | |||
| 14 | ##+~-~-~-~--+~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~--+~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-+ | ||
| 15 | ~| ID | Type | Name | | ||
| 16 | +~-~-~-~--+~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~--+~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-+ | ||
| 17 | ~| 51 | Area | Boardroom A | | ||
| 18 | +~-~-~-~--+~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~--+~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-+## | ||
| 19 | |||
| 20 | Actions: | ||
| 21 | |||
| 22 | ##+~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~--+~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~--+~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-+~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-+~-~-~-~-~-~-~-~--+~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~--+~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-+ | ||
| 23 | ~| Type | Action | Description | Reference Property | Ref Req | Triggers | Supported Properties | | ||
| 24 | +~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~--+~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~--+~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-+~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-+~-~-~-~-~-~-~-~--+~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~--+~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-+ | ||
| 25 | ~| Area | RecallScene | Recalls the specified scene on this load | SceneId | False | Digital, Analog | 'SceneId'[[image:https://wiki.chiefintegrations.com/resources/icons/silk/emoticon_unhappy.png?cache-version=1594193432000||alt="emoticon_unhappy"]]Integer)'Scene Number to recall' | | ||
| 26 | +~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~--+~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~--+~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-+~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-+~-~-~-~-~-~-~-~--+~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~--+~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-+## | ||
| 27 | |||
| 28 | TCP Command to send: | ||
| 29 | |||
| 30 | ##51.RecallScene.1\x0D## | ||
| 31 | |||
| 32 | ==== Subscriptions ==== | ||
| 33 | |||
| 34 | Subscriptions may be enabled for each action. When a subscription is requested the current state will be returned. Any future changes to the actions state will return the value until the subscription is canceled. A subscription request does not require parameters and does not execute the action. "+" is used to subscribe, "-" is used to unsubscribe. Subscriptions are tracked by connection. If a connection is lost a re-subscribe should take place on a new connection. | ||
| 35 | |||
| 36 | Subscribe: | ||
| 37 | ##+[GlobalId].[ActionName]\x0D## | ||
| 38 | +51.RecallScene\x0D | ||
| 39 | |||
| 40 | Unsubscribe: | ||
| 41 | ##-[GlobalId].[ActionName]\x0D## | ||
| 42 | -51.RecallScene\x0D | ||
| 43 | |||
| 44 | Reponse to Subscribe and Change of State Response: | ||
| 45 | ##[GlobalId].[ActionName]=[NewValue]\x0D## | ||
| 46 | ##51.RecallScene=0\x0D## | ||
| 47 | |||
| 48 | All response values are returned as numbers with 0 being false and 1 being true if the state is not a number. | ||
| 49 |