Instead of a fixed time for a HTML element or HTML slide,
is it possible to trigger an event from javascript or html (link)?
e.g. go to next element or next step.
13 comments
-
Lyndon Not yet, but we're working on javascript that will provide access to brightsign events.
-
GD In the newer firmwares (tested on 4.7.112) i am able to send a UDP command from HTML.
jQuery post to localhost:8080/SendUDP key:"SendUDP", value:"myValue" will trigger an UDP event.Can you clarify a bit what happens here? I'm guessing the device fires it on the local network (255.255.255.255) and then also itself catches the event (and acts accordingly if an interactive event was listening to that value). Or is the event local, only on the device where the HTML posts the command?
Second. I'm open to suggestions on how this can be secured a bit.
I would rather not have third-party website fire streams of UDP commands.Some security options:
- Maybe a checkbox in the Presentation properties HTML-Sites to allow access to localhost
- Maybe a plugin (and user variables) to filter remote-hosts that can access localhost -
Lyndon THere isn't a whitelist, but you can password protect your unit so that someone can't access the unit remotely without entering a username and password.
-
Shawn Makinson Couple related questions.
Where is the documentation for this and the javascript extensions found?
How can I listen for a UDP event in javascript/html?
-
Shawn Makinson I believe I found it in the JavaScriptObjects pdf.
-
Roni Starc I am also having some problems with this.
I have a html presentation running on the BS (an XD1032 FW 5.1.65) from which I would like to send an UDP command, so the player will go in another state.
I tried with the
$.post('localhost:8080/SendUDP', { key: 'SendUDP', value: 'StartWelcome' } );
but nothing happens and in the console of the webinspector I get the messages:
POST localhost:8080/SendUDP URL cannot be shown
Then I tried to visit xd1032_IP:8080/SendUDP but I get a 404 missing handler response.
Am I missing something?
IS there any other way with which I could go automatically from a fullscreen HTML to a fullscreen video in the same zone?
-
Roni Starc Fixed it with the help of support. Leaving this here for future references.
If one want's to send an UDP event (to the same device) from JavaScript (HTML) to trigger UDP events in a presentation the correct code is (using jQuery):
$.post('http://localhost:8080/SendUDP', { key: 'SendUDP', value: 'udp_message' } );
Note, the udp_message must be in quotes as one needs to send the message as a text string (SendUDP command also).
-
Laurent de Goede Has this been deprecated? Tried and tried, but it will not work for me...
-
Lyndon No, this is still supported.
-
Laurent de Goede Ok and is there some hidden flag i need to set for this?
I am trying to send udp commands using this from an a local website (vue) running in an html zone, but nothing seems to respond.
Can you help me debug this?
-
Lyndon If you post a link to your html or an example with your udp code that we can publish and test, that would be helpful.
-
Laurent de Goede Sure, where do I send it (by email or pm)?
-
Laurent de Goede Nevermind, just tried it in a new project using jquery (i used axios before). Thanks for lending me your ear!