Script Result Question and the DIY Interface is Cool
James Sentman
james at sentman.com
Wed Dec 28 15:26:10 EST 2022
What I infer from this is that there are Serial and IP versions of this device, or that you can connect an IP to Serial adaptor or something. So the plugin needs to have the ability to connect to either.
I also assume that a persistent connection is not needed or wanted, at least in the case of the IP connection. If you send a command it should connect to the device, send the command, and then disconnect so that any other remotes or integration systems that might be in play can connect when needed as well.
Since we don’t know what the responses from the device are, if any, for the moment we would ignore them and just assume our commands were responded to. Since we process no input from the device in order to get our current state we would not know if out Unit state reflected reality. As long as you know this and change the inputs regardless of. It is possible that polling it to find out if things have changed under someone elses control would be possible in the future but not part of this first stab at the plugin.
For the actual control I can imagine that the power on, power off and reboot commands would be less used and so could be scripting only commands without a Unit or other UI assigned to them. Accessible with some commands like:
tell xInterface “Living Room Matrix” to reboot()
tell xInterface “Living Room Matrix” to powerOn()
tell xInterface “Living Room Matrix” to powerOff()
would be fine? Then for the outputs there could be 4 Units for each output that could be set to a value between 1 and 4. That would then open the port, either serial or IP, send the command and then keep the channel open for a few seconds after the command was sent in case there were several to change at once, then disconnect so that other remotes can have a turn.
Does that sound reasonable? Because we can do that fairly easily and then expand to whatever other models or devices do something similar.
> On Dec 28, 2022, at 2:23 PM, Sean Lavigne <sean at houselavigne.us> wrote:
>
> Here’s the website for the particular 4x4 HDMI Matrix I have: http://nohassleav.com/support/matrix_hdmi_4x4_4k_hdr/ <http://nohassleav.com/support/matrix_hdmi_4x4_4k_hdr/>
>
> That page has a link to the Simplified RS-232 and IP Commands which reads as follows:
>
> Baud Rate: 115200
> Data width: 8
> Parity: None
> Stop: 2Bit
>
> Power On: \xA5\x5B\x08\x0B\x0F\x00\x0F\x00\x00\x00\x00\x00\xCF
> Power Off: \xA5\x5B\x08\x0B\xF0\x00\xF0\x00\x00\x00\x00\x00\x0D
> Reboot: \xA5\x5B\x08\x0D\x00\x00\x00\x00\x00\x00\x00\x00\xEB
>
>
> Output1
> Input1: \xA5\x5B\x02\x03\x01\x00\x01\x00\x00\x00\x00\x00\xF9
> Input2: \xA5\x5B\x02\x03\x02\x00\x01\x00\x00\x00\x00\x00\xF8
> Input3: \xA5\x5B\x02\x03\x03\x00\x01\x00\x00\x00\x00\x00\xF7
> Input4: \xA5\x5B\x02\x03\x04\x00\x01\x00\x00\x00\x00\x00\xF6
>
>
> Output2
> Input1: \xA5\x5B\x02\x03\x01\x00\x02\x00\x00\x00\x00\x00\xF8
> Input2: \xA5\x5B\x02\x03\x02\x00\x02\x00\x00\x00\x00\x00\xF7
> Input3: \xA5\x5B\x02\x03\x03\x00\x02\x00\x00\x00\x00\x00\xF6
> Input4: \xA5\x5B\x02\x03\x04\x00\x02\x00\x00\x00\x00\x00\xF5
>
>
> Output3
> Input1: \xA5\x5B\x02\x03\x01\x00\x03\x00\x00\x00\x00\x00\xF7
> Input2: \xA5\x5B\x02\x03\x02\x00\x03\x00\x00\x00\x00\x00\xF6
> Input3: \xA5\x5B\x02\x03\x03\x00\x03\x00\x00\x00\x00\x00\xF5
> Input4: \xA5\x5B\x02\x03\x04\x00\x03\x00\x00\x00\x00\x00\xF4
>
>
> Output4
> Input1: \xA5\x5B\x02\x03\x01\x00\x04\x00\x00\x00\x00\x00\xF6
> Input2: \xA5\x5B\x02\x03\x02\x00\x04\x00\x00\x00\x00\x00\xF5
> Input3: \xA5\x5B\x02\x03\x03\x00\x04\x00\x00\x00\x00\x00\xF4
> Input4: \xA5\x5B\x02\x03\x04\x00\x04\x00\x00\x00\x00\x00\xF3
>
Thanks,
James
James Sentman http://www.PlanetaryGear.org http://MacHomeAutomation.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.machomeautomation.com/pipermail/xtensionlist/attachments/20221228/d4874c5e/attachment.html>
More information about the XTensionList
mailing list