Page 44 6. post commands – Muxlab 8 x 8 Cat 5e/6 Line Level Audio Matrix Switch User Manual

Page 44

Advertising
background image

© MuxLab Inc.

Audio 8x8 Matrix Switch Installation Guide

Page 44

6. POST Commands

POST commands will always return 1 of 5 HTTP headers:

HTTP 201Created

Command was successful

HTTP 400 Bad Request

Received argument was malformed

HTTP 403 Forbidden

User does not have sufficient privileges

HTTP 404 Not Found

URL is incorrect

HTTP 501 Not Implemented

URL does not support receiving POST data

URL

Argument

/var/conn.json

Array of connections.
(Same as GET above)

Example: [0,1,2,3]

/var/pre1.json
/var/pre2.json
/var/pre3.json
/var/pre4.json
/var/pre5.json
/var/pre6.json
/var/pre7.json
/var/pre8.json

Array of connections for a preset
(Same as GET above)

Example: [0,1,2,3]

/var/boxname.json

Array of a single string.
Contains the name of the box, limited to 20 characters
Example: [“Classroom B Matrix”]

/var/sources.json

Array of 4 strings.
Contains the names of all 4 input ports.
Example: [“Cable Box”, “Satellite Receiver”, “Demo Reel”, …]

/var/displays.json

Array of 4 strings.
Contains the names of all 4 output ports.
Example: [“Conference Room”, “Cafeteria”, …]

/var/presetnames.json

Array of 8 strings.
Contains the names of all 8 presets to be set
Example: [“Preset 1”, “Preset 2”, “week end”, …]

/var/auth.json

Array of 2 strings.
Contains a single digit string representing the user level requested, and a second string representing the password.
Example: [“2”, “myAdminPassword”]

/var/serial.json

Array of 4 integers.
Set the following serial port settings: baud rate, data bits(7 or 8), parity (0=>Even; 1=>Odd; 4=>None) ,stop bits
(0=>1 stop bit; 2=>2 stop bits)
Example: [9600,8,4,0]

/var/ip.json

Array of 4 integers.
Set the IP address
Example: [10,0,101,96]
WARNING! This request will actually take effect after the DHCP request will be sent

/var/netmask.json

Array of 4 integers.
Set the mask address
Example: [255,255,0,0]
WARNING! This request will actually take effect after the DHCP request will be sent

/var/router.json

Array of 4 integers.
Set the gateway address
Example: [10,0,1,1]
WARNING! This request will actually take effect after the DHCP request will be sent

/var/dhcp.json

Array of a single integer.
Set the DHCP state ON ([1]) or OFF ([0])
Example: [1]

/var/tempalarms.json

Array of 2 integers.
Set the Min. and Max. temperature of the unit before an alarm is raised
Example: [5,70]

/var/alarmflags.json

Array of 8 integers.
Set the alarm configuration: beep, email, serial feedback, (the last 5 integer are not used)
Example: [1,0,1,0,0,0,0,0]

var/pass_admin.json

Array of 2 strings.
Set the web administrator password
Example: [“old admin password”, “new admin password”]

var/senddata

Hexadecimal data string to send in the request formatted as follow:
Example: [“03060A010203040506070809A0”]
03 is the port number (here it is port # 3)
06 is the baud rate code:

For 9600 the code is 06

For 19200 the code is 08

For 38400 the code is 09

For 57600 the code is 0B

For 115200 the code is 0C

0A is the data length that follows (max value 0x28 bytes.)
01A203040506070809A0 is the data in hexadecimal (0x01, 0xA2, 0x03,…)

Advertising