AMX IS-SPX-1000/1300 Universal Remote User Manual


 
Shared Variables
88
Inspired XPress - Programming Guide
Enabling the Network API
The network API must be enabled on the IS-SPX Player before it can be utilized. This setting is controlled from the IS-
SPX Player Browser-Based Configuration Pages (FIG. 113):
Sample Code
Updating a variable
using PHP
function send_update( $host, $port, $name, $value ) {
$s=fsockopen( $host, $port );
fwrite( $s, “UPDATE \”$name\" \"$value\"\r\n" );
fclose( $s );
}
Note: this simplified example does not handle the escaping of control characters.
Sending an event
using PHP
Sending a keydown event for the key 'V' with control modifier pressed.
function send_copy_key( $host, $port ) {
$s=fsockopen( $host, $port );
fwrite( $s, “EVENT \”keydown\” \”Ctrl+V\”\r\n” );
fclose( $s );
}
Updating a variable
using telnet
telnet 192.168.1.10 1234
Trying 192.168.1.10...
Connected to 192.168.1.10
Escape character is '^]'.
UPDATE “menu” “P1”
^]
telnet> quit
Connection closed.
Updating a variable
using HTTP
http://192.168.1.10:1234/update?menu=P1
FIG. 113 Enabling the Network API
Click the box and
then click “Apply”
For more information on the Browser-Based Configuration Pages, please refer to the
IS-SPX-1000 & IS-SPX-1300 Operation Reference Guide, available at
www.amx.com.