Network Technologies SPLITMUX-HD-4RT, SPLITMUX-4K-4RT-2R, SPLITMUX-USBHD-4RT-R, SPLITMUX-4K-4RT, SPLITMUX-USBHD-4RT-2R User guide

...
Page 1
Configure SPLITMUX-HD-4RT Using HTTP-Based Text Commands
To use the HTTP API's for manipulating custom config mode in SPLITMUX, there are 3 API's to use:
1. Login API to login and get the session ID required by other API's
2. Get Config API to Get Current Settings including output resolution
3. Save Config API used to save the channel settings for a layout.
Login API
Request Type: POST Request Endpoint:/goform/login
curl '<IP_ADDRESS>/goform/login' -X POST --data 'username=root&password=nti'
Note: the single quote marks used in the above command (‘ ‘ ) work with Linux and Mac PCs, but when using a Windows PC, substitute double quotation marks (“ “ ) instead.
Response: { "success":"true", "cookie":"sessionId=cm9vdDpudGk6MTE=" }
Get Config API
Get Config API requires session ID to be sent in header as below along with a callback function value. The JSON response will be wrapped in this callback function. Developers can remove this callback function wrapper to get the JSON object in the format shown below.
Request Type: GET Request Endpoint: /goform/login
curl '<IP_ADDRESS>/goform/getCustomConfig?callback=callbackfunc' -X GET -H 'Cookie: sessionId=cm9vdDpudGk6MTE=;'
Response Format:
callbackfunc({ "lout":{ Layout Object 1:{ ID of layout generated by Device. Range from 1 to 10 "nm":"Layout 1", Name of layout given by user or a default layout name in case of new addition "ch1": { Reference for Channel 1 Object, 4 such objects will be there in each layout "t":0, Top : position of top left corner of uncropped unzoomed Channel from top of screen in
pixels of output resolution "l":0, Left: position of top left corner of uncropped unzoomed Channel from left of screen in
pixels of output resolution "w":90, width: width of the uncropped unzoomed channel in pixels of output resolution "h": 90, height: height of the uncropped unzoomed channel in pixels of output resolution "ar": "0", Aspect Ratio: can be ignored by API. "vl": 1, Volume Left: indicates if Left volume indicator is enabled(1) or disabled(0) "vr": 1, Volume Right: indicates if right volume indicator is enabled or disabled "umd": 1, UMD : indicates if UMD display is enabled (1) or disabled (0) "nm":"Channel 1", Name: Name of channel given by user or a default name. Same name is shown as UMD "en": 1, Enabled : indicates if channel is enabled or not "bc": 1, Border Color: indicates the position of border color selected. values can be 0 to 23. Color
values and names are described below "bw": 1, Border Width: indicates the width of border for this channel. values can be 0 to 50
Page 2
"au": 1, Audio Enabled: inidicates whether audio is enabled for this channel "tr": 64, Transparency: value from 0 to 64. 64 corresponds to 0% transparency and 0 corresponds
to 100% transparency "it": 0, Image Top: vertical distance in pixels of input resolution FROM top left corner of Zoomed
but uncropped image TO top left corner of Crop Window (which is the actual area of the output used by this channel). "il": 0, Image Left: Horizontal distance in pixels of input resolution FROM top left corner of Zoomed but uncropped image TO top left corner of Crop Window (which is the actual area of the output used by this channel). "iw": 1920, Input resolution of the connected channel( Provided by device, can be set same value in save API
"ih": 1080, Input resolution of the connected channel ( Provided by device, can be set same value in save API)
"iz": 100, Zoom percentage. Values should be from 100 to 500 "ct": 0, Crop Window Top: Vertical position of top left corner of output to be used by this channel
in pixels of output resolution "cl": 0, Crop Window Left: Horizontal position of top left corner of output to be used by this
channel in pixels of output resolution "cw": 200, Crop Window Width: Width of output to be used by this channel in pixels of output
resolution "ch": 200, Crop Window Height: Width of output to be used by this channel in pixels of output
resolution }, (End bracket for the command) . .
"ch4":{ …}, 4 channels are provided for each layout (all of the above can be applied to channels 2-4)
"cord": [1, 2, 3, 4, 5] Channel Order: represents which channels are on top. 1 is at top here and 5 ( logo which is deprecated) at bottom
"logo":{ . } This block is deprecated and should be ignored "sn": 1, Can be ignored by API
"r": 10, Can be ignored by API "c": 10, Can be ignored by API "en": 0, Enabled: indicates if this layout is the active layout or not. Only one layout will be active at
a time. "res": { resolution: resolution of screen when this layout was saved. If user selects this layout after
changing resolution, GUI should prompt to reorder layout or Change resolution "w":1080, width of screen in pixels of output resolution "h": 700 height of screen in pixels of output resolution } },
2:{ Further layouts may continue here }
. . }, End of layout object
"loutord": [1, 15, 2, 4] Layout Order: represents the order in which layouts are listed "cres": { Current Output Resolution: "w":1080, width of output screen in pixels of output resolution "h": 700 height of output screen in pixes of output resolution } });
Page 3
Border Color Values with position number:
{0: '#101010', 1: '#EBEBEB', 2: '#BEBEBE', 3: '#E6E6EB', 4: '#101080', 5: '#1010EB', 6: '#87CEEB', 7: '#40E0D0', 8: '#10EBEB', 9: '#7FEBD4', 10: '#106410', 11: '#10EB10', 12: '#EBE68C', 13: '#EBEB10', 14: '#EBD710', 15: '#EBEBDC', 16: '#A52A2A', 17: '#EBA510', 18: '#EB1010', 19: '#EBC0CB', 20: '#B03060', 21: '#EB10EB', 22: '#EB82EB', 23: '#A020EB'};
Border Color Names:
["BLACK","WHITE","GRAY","LAVENDER","NAVYBLUE","BLUE","SKYBLUE","TURQUOISE","CYAN","AQUAMARIN E","DARKGREEN","GREEN","KHAKI","YELLOW","GOLD","BEIGE","BROWN","ORANGE","RED","PINK","MAROON ","MAGENTA","VIOLET","PURPLE"];
Save Layout API:
To save the settings for a layout, the parameters need to be sent in xml format as shown in below API along with the current output resolution. Device automatically enables this layout as the active layout. Parameter descriptions are same as in Get Config API. If save is successful, it responds with code 0 in JSON format Request Type: POST Request Endpoint: /goform/saveLayout
. If not it responds with an error message and an error code. curl 'http://98.17.207.211/goform/saveLayout
' -X POST -H 'Cookie: sessionId=cm9vdDpudGk6MTE=;' --data '<conf><lout><id>1</id><nm>layout 1</nm><ch1><t>258</t><l>132</l><w>1082</w><h>549</h><ar>0</ar><vl>0</vl><vr>0</vr><tr>64</tr><umd>0</ umd><nm>Channel 1</nm><en>1</en><bc>0</bc><bw>1</bw><au>1</au><it>0</it><il>0</il><iw>0</iw><ih>0</ih><iz>100</iz><ct>2 58</ct><cl>132</cl><cw>1082</cw><ch>549</ch></ch1><ch2><t>0</t><l>964</l><w>1039</w><h>586</h><ar>1 </ar><vl>0</vl><vr>0</vr><tr>64</tr><umd>0</umd><nm>Channel 2</nm><en>1</en><bc>0</bc><bw>1</bw><au>1</au><it>0</it><il>0</il><iw>1920</iw><ih>1080</ih><iz>100</iz ><ct>0</ct><cl>964</cl><cw>951</cw><ch>535</ch></ch2><ch3><t>601</t><l>78</l><w>1426</w><h>802</h><a r>1</ar><vl>0</vl><vr>0</vr><tr>64</tr><umd>0</umd><nm>Channel 3</nm><en>1</en><bc>0</bc><bw>1</bw><au>0</au><it>87</it><il>105</il><iw>1920</iw><ih>1080</ih><iz>100 </iz><ct>537</ct><cl>0</cl><cw>960</cw><ch>543</ch></ch3><ch4><t>539</t><l>964</l><w>971</w><h>539</h ><ar>1</ar><vl>0</vl><vr>0</vr><tr>64</tr><umd>0</umd><nm>Channel 4</nm><en>1</en><bc>0</bc><bw>1</bw><au>0</au><it>0</it><il>0</il><iw>0</iw><ih>0</ih><iz>100</iz><ct>5 39</ct><cl>964</cl><cw>954</cw><ch>530</ch></ch4><cord><p1>1</p1><p2>4</p2><p3>2</p3><p4>3</p4><p5 >5</p5></cord><logo><t>0</t><l>0</l><w>4</w><h>4</h><en>0</en></logo><sn>0</sn><r>10</r><c>10</c><en> 1</en><res><w>1920</w><h>1080</h></res></lout></conf>
Response: {code: 0, msg: "layout saved"} Please note that behavior of output when Invalid parameters are set is undefined. Developers should take care to
confine output within the resolutions set and its designated window.
Page 4
Loading...