Page 1 of 1

Barco UDX via JSON

PostPosted: Tue Sep 19, 2017 11:41 pm
by Sam Kriemelmeyer
does anyone have experience with sending commands via the projector node to the Barco UDX series via JSON? what are the appropriate strings for things like shutter and power on/off ?

gracias,
sam

Re: Barco UDX via JSON

PostPosted: Sun Sep 24, 2017 8:22 pm
by liamohanlon
These are the commands I used to control some HDX 4k PJs which I believe run the same (next gen) firmware.

LampOn:
Code: Select all
{[LF]"jsonrpc": "2.0", "method": "system.poweron", "params": {}, "id": 12[LF]}[LF]


LampOff:
Code: Select all
{[LF]"jsonrpc": "2.0", "method": "system.poweroff", "params": {}, "id": 12[LF]}[LF]


ShutterOpen:
Code: Select all
{[LF]"jsonrpc": "2.0", "method": "property.set", "params": { "property": "optics.shutter.target", "value": "Open" }, "id": 1[LF]} [LF]


ShutterClose:
Code: Select all
{[LF]"jsonrpc": "2.0", "method": "property.set", "params": { "property": "optics.shutter.target", "value": "Closed" }, "id": 1[LF]} [LF]


Lamp Status:
Code: Select all
{[LF]"jsonrpc": "2.0", "method": "property.get", "params": { "property": "system.state"}, "id": 1[LF]}[LF]


Lamp On Response:
Code: Select all
{"jsonrpc":"2.0","id":1,"result":"on"}


Lamp Off Response:
Code: Select all
{"jsonrpc":"2.0","id":1,"result":"ready"}


Shutter Status:
Code: Select all
{[LF]"jsonrpc": "2.0", "method": "property.get", "params": { "property": "optics.shutter.target"}, "id": 1[LF]}[LF]


Shutter Open Response:
Code: Select all
{"jsonrpc":"2.0","id":1,"result":"Open"}


Shutter Closed Response:
Code: Select all
{"jsonrpc":"2.0","id":1,"result":"Closed"}

Re: Barco UDX via JSON

PostPosted: Tue Sep 26, 2017 12:42 am
by Sam Kriemelmeyer
this is great thank you !

i was able to use these commands to control a UDX Barco Projector from Widget Designer:



UDX TCP:PORT 9090


Set Shutter:
{"jsonrpc":"2.0","method":"property.set","params":{"property":"optics.shutter.target","value":"Open"},"id":12}

Value can be: Open or Closed

Read Shutter Status:
{"jsonrpc":"2.0","method":"property.get","params":{"property":"optics.shutter.target"},"id":12}
Example return for shutter status:
{ "jsonrpc":"2.0", "id":12, "result":"Open" }


Power On:
{"jsonrpc":"2.0","method":"system.poweron","params":{},"id":12}

Power Off:
{"jsonrpc":"2.0","method":"system.poweroff","params":{},"id":12}


Read Power State:
{"jsonrpc":"2.0","method":"property.get","params":{"property":"system.state"},"id":12}

Example return for Power State:
{"jsonrpc":"2.0","id":12,"result":"on"}


couldnt get the shutter read working..... stay tuned...

Re: Barco UDX via JSON

PostPosted: Mon Oct 08, 2018 7:45 am
by targets
Hey guys,

Trying to get this working for the UDX at the moment.

In order to do this did you have to create a variable for it? I'm only on the free version at the moment so dont have access to it.

Cheers

Re: Barco UDX via JSON

PostPosted: Mon Oct 08, 2018 3:11 pm
by Benni_M
Hey,
You can create variables with the free version.
Cheers,
Benni

Re: Barco UDX via JSON

PostPosted: Tue Nov 20, 2018 12:03 pm
by Janina Baltaziewicz
Hi targets,

Yes, you can create variables in Free version, but you don't need them to trigger these commands.
If you're not using the Projector Control node, you can use a simple TCPSend command to send the messages.
Responses can of course not be received when you don't have nodes.

Cheers!

Re: Barco UDX via JSON

PostPosted: Sun Aug 29, 2021 9:32 pm
by Djools
Hi everyone,

Thank you for the previous informations about the way to send commands to a Barco UDX Projector threw JSON in WD.
I am actually working on show and using Widget Designer V6.
I try to send commands to an UDX to control the shutter but I did not succed yet...

Can you confirm the right (and complete) synthax to a "TcpSend" command with JSON please ?
Here is the order tried to get the shutter closed (my projector has the ID = 5) :

TcpSend(5,'{[LF]"jsonrpc":"2.0","method":"property.set","params":{"property":"optics.shutter.target","value":"Closed"},"id":5[LF]}')"[CR][LF]"

Any idea ?
Thanks for any help.
Best Regards,

Djools

Re: Barco UDX via JSON

PostPosted: Mon Aug 30, 2021 1:22 pm
by Martina Protze
Hi Djools,

If I execute your command and look in the Debug Logger it says:
* "Parameters must be enclosed in '()'!" for "TcpSend" at 1/1 [Severe/Parsing]

For me, it looks like you added the part with CR wrongly as it is not inside the round brackets. Maybe there is also a missunderstanding about the TCP-connection ID in addition to the first issue. In the Connection Manager, is the ID for the TCP also 5? As I just made one connection, it has ID 1. So if I want to send a text (e.g. just letter x) to the recipient of this connection it would be:
Tcpsend(1,'x')

So if I select x and copy the example from liamohanlon including line feeds and many spaces it is (for Barco ID 5):
Tcpsend(1,'{[LF]"jsonrpc": "2.0", "method": "property.set", "params": { "property": "optics.shutter.target", "value": "Closed" }, "id": 5[LF]} [LF]')

If I take Sam's example without line feeds and spaces, I get:
Tcpsend(1,'{"jsonrpc":"2.0","method":"property.set","params":{"property":"optics.shutter.target","value":"Closed"},"id":5}')

Let me know, whether that worked for you :)

Re: Barco UDX via JSON

PostPosted: Wed Sep 01, 2021 10:55 am
by Djools
Hi Martina,

Thank you very much for your help, it finally worked ! :D
As supposed it was just a little synthax error I made.
For information, in the "Connection Manager" my Barco UDX has the ID "5" and my test confirms that this is the ID number to put at the beginning of the command : TcpSend(5,"command line").

And the correct commands are :
. To close the shutter =
TcpSend(5,'{[LF]"jsonrpc":"2.0","method":"property.set","params":{"property":"optics.shutter.target","value":"Closed"},"id":5[LF]}[LF]')
. To open the shutter =
TcpSend(5,'{[LF]"jsonrpc":"2.0","method":"property.set","params":{"property":"optics.shutter.target","value":"Open"},"id":5[LF]}[LF]')

Thanks again to you Martina and to the previous contributors.
Best Regards,

Djools