SystemControl API
To use Samsung Product API,
<script type="text/javascript" src="$WEBAPIS/webapis/webapis.js"></script>
Should be loaded in index.html
This module defines functionalities for retrieving device information provided by the Samsung Product API.
The SystemControl module provides additional functionalities for Samsung B2B devices as a WebAPI.
You can use this WebAPI to retrieve and manage the system information for B2B devices.
Since : 6.5
Product : B2B
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Summary of Interfaces and Methods
1. Type Definitions
1.1 Activation
Whether the feature is enabled.
enum Activation {
"ON",
"OFF"
};
The following values are supported
- ON : Enabled
- OFF : Disabled
Since : 6.5
1.2 ScreenOrientation
Screen orientation of the device.
enum ScreenOrientation {
"LANDSCAPE",
"PORTRAIT",
"AUTO"
};
The following values are supported
- LANDSCAPE : Horizontal orientation
- PORTRAIT : Vertical orientation
- AUTO : Automatic based on the screen rotation
Since : 6.5
1.3 PCConnection
Computer connection type of the device.
enum PCConnection {
"RJ45",
"RS232",
"INVALID"
};
The following values are supported
- RJ45 : RJ45 connection
- RS232 : RS-232 connection
- INVALID : Invalid connection type
Since : 6.5
1.4 CustomAppTimeout
Timeout values for waiting connection of Custom URL.
enum CustomAppTimeout {
"30SEC",
"60SEC",
"90SEC",
"120SEC",
"150SEC",
"180SEC",
"240SEC",
"300SEC"
};
The following values are supported
- 30SEC : Timeout set to 30 seconds
- 60SEC : Timeout set to 60 seconds
- 90SEC : Timeout set to 90 seconds
- 120SEC : Timeout set to 120 seconds
- 150SEC : Timeout set to 150 seconds
- 180SEC : Timeout set to 180 seconds
- 240SEC : Timeout set to 240 seconds
- 300SEC : Timeout set to 300 seconds
Since : 6.5
1.5 SourceType
Available Source types on b2b Set
enum SourceType {
"TV",
"PC",
"HDMI1",
"HDMI2",
"HDMI3",
"DP",
"DVI",
"MAGICINFO",
"OPS",
"HDBT",
"AV",
"COMP",
"MAGICINFOS",
"INTERNAL_USB",
"URL_LAUNCHER",
"SCREEN_MIRRORING"
};
The following values are supported
- TV : TV Source
- PC : PC Source
- HDMI1 : First HDMI
- HDMI2 : Second HDMI
- HDMI3 : Third HDMI
- DP : Display Port
- DVI : DVI
- MAGICINFO : LFD APPLICATION
- OPS : OPS
- HDBT : HDBT
- AV : AV
- COMP : COMP
- MAGICINFOS : MAGICINFOS
- INTERNAL_USB : USBMODE
- URL_LAUNCHER : LFD APPLICATION
- SCREEN_MIRRORING : Screen Mirroring
Since : 6.5
1.6 CapturePath
The following virtual roots must be supported for capture file.
enum CapturePath {
"wgt-private-data",
"wgt-private-tmp"
};
The following values are supported
- wgt-private-data : - the location for a widget's private data storage
- wgt-private-tmp : - the location for a widget's private volatile storage
Since : 6.5
2. Interfaces
2.1 LampScheduleInfo
Object containing lamp schedule settings.
[NoInterfaceObject] interface LampScheduleInfo {
attribute Activation use;
attribute DOMString firstTime;
attribute long level1;
attribute DOMString secondTime;
attribute long level2;
};
Attributes
- Activation use
Lamp schedule status. - DOMString firstTime
First scheduled time of day, in the format "hours:minutes". - long level1
Lamp level for the first scheduled time. The value is a number between 0 and 100. - DOMString secondTime
Second scheduled time of day, in the format "hours:minutes". - long level2
Lamp level for the second scheduled time. The value is a number between 0 and 100.
2.2 CustomAppInfo
Object containing CustomApp URL and Timeout
[NoInterfaceObject] interface CustomAppInfo {
attribute DOMString downloadServerAddress;
attribute CustomAppTimeout connectionTimeout;
};
Attributes
- DOMString downloadServerAddress
URL of customapp server - CustomAppTimeout connectionTimeout
Timeout for network connecttion
2.3 MagicinfoServerInfo
Object containing ssl option, address, port
[NoInterfaceObject] interface MagicinfoServerInfo {
attribute DOMString ssl;
attribute DOMString address;
attribute DOMString port;
};
Attributes
- DOMString ssl
ssl of magicinfo server - DOMString address
address of magicinfo server - DOMString port
port of magicinfo server
2.4 SystemControlManagerObject
Defines a WebApi object instance of the Samsung Product API.
The webapis.systemcontrol object enables access to SystemControl API functionality.
[NoInterfaceObject] interface SystemControlManagerObject {
readonly attribute SystemControlManager systemcontrol;
};
WebApi implements SystemControlManagerObject;
Attributes
- readonly SystemControlManager systemcontrol
SystemControl API namespace.
Since : 6.5
2.5 UpdateFirmwareProgressChangedCallback
Defines the firmware update progress callback.
[Callback = FunctionOnly, NoInterfaceObject] interface UpdateFirmwareProgressChangedCallback {
void onchange(long progress);
};
Methods
onchange
Method that is invoked when the firmware update progress changes.
void onchange(long progress);
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Parameters :
- progress : Operation status
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
Since : 6.5
Code Example :
var onchange = function(data) {
console.log("[UpdateCallback] progress :" + data + " changed");
};
try {
webapis.systemcontrol.setUpdateFirmwareListener(onchange);
} catch (e) {
console.log("setUpdateFirmwareListener exception [" + e.code + "] name: " + e.name + " message: " + e.message););
}
2.6 SystemControlManager
Provides methods for SystemControl functionalities.
[NoInterfaceObject] interface SystemControlManager {
DOMString getVersion();
void captureScreen(optional CapturePath? path);
void rebootDevice();
DOMString getSerialNumber();
void updateFirmware(DOMString SoftwareID, DOMString SWUFileName, DOMString SWVersion, DOMString SWURL, long SWTotalBytes);
void setUpdateFirmwareListener(UpdateFirmwareProgressChangedCallback onchange);
void unsetUpdateFirmwareListener();
void setScreenLampSchedule(LampScheduleInfo info);
LampScheduleInfo getScreenLampSchedule();
void setPanelMute(Activation enable);
Activation getPanelMute();
void setSafetyLock(Activation enable);
Activation getSafetyLock();
ScreenOrientation getOnScreenMenuOrientation();
ScreenOrientation getSourceOrientation(SourceType source);
void setPCConnection(PCConnection type);
PCConnection getPCConnection();
void setMessageDisplay(Activation enable);
Activation getMessageDisplay();
void setCustomAppInfo(CustomAppInfo info);
CustomAppInfo getCustomAppInfo();
void setIRLock(Activation option);
Activation getIRLock();
void setButtonLock(Activation option);
Activation getButtonLock();
void setAutoPowerOn(Activation option);
Activation getAutoPowerOn();
void setMagicinfoServerInfo(MagicinfoServerInfo info);
MagicinfoServerInfo getMagicinfoServerInfo();
};
Since : 6.5
Methods
getVersion
Retrieves the SystemControl module version on the device.
DOMString getVersion();
Product : B2B
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Return Value :
- DOMString : DOMString SystemControl plug-in version
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type NotSupportedError if this feature is not supported
- with the error type UnknownError for any other error
Since : 6.5
Code Example :
var Version = null;
try {
Version = webapis.systemcontrol.getVersion();
} catch (e) {
console.log("[getVersion] call syncFunction exception [" + e.code + "] name: " + e.name + " message: " + e.message);
}
if(Version){
console.log("[getVersion] call syncFunction type: " + Version);
}
captureScreen
Creates a screen capture of the device. it is saved in the form of ScreenCapture.jpg file under the path entered by the user.
If there is no input path, it is saved in the form of /tmp/ScreenCapture.jpg, which is the default path.
If the api is called on the same path, the file will be overwritten.
It can be controlled using Filesystem webapi.
void captureScreen(optional CapturePath? path);
Product : B2B (LFD, IWB)
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Parameters :
- path [optional][nullable] : user input screencapture saved path,default path is /tmp/ScreenCapture.jpg
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type NotSupportedError if this feature is not supported
- with the error type UnknownError for any other error
- with the error type TypeMismatchError if an input parameter is not compatible with its expected type
Since : 6.5
Code Example :
try {
webapis.systemcontrol.captureScreen("wgt-private-tmp");
} catch (e) {
console.log("[captureScreen] call syncFunction exception [" + e.code + "] name: " + e.name + " message: " + e.message);
}
rebootDevice
Reboots (switches off and on again) the device.
void rebootDevice();
Product : B2B
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type NotSupportedError if this feature is not supported
- with the error type UnknownError for any other error
Since : 6.5
Code Example :
try {
webapis.systemcontrol.rebootDevice();
} catch (e) {
console.log("[rebootDevice] call syncFunction exception [" + e.code + "] name: " + e.name + " message: " + e.message);
}
getSerialNumber
Retrieves the device serial number.
DOMString getSerialNumber();
Product : B2B
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Return Value :
- DOMString : Device serial number
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type NotSupportedError if this feature is not supported
- with the error type UnknownError for any other error
Since : 6.5
Code Example :
var SerialNumber = null;
try {
SerialNumber = webapis.systemcontrol.getSerialNumber();
} catch (e) {
console.log("[getSerialNumber] call syncFunction exception [" + e.code + "] name: " + e.name + " message: " + e.message);
}
if (SerialNumber) {
console.log("[getSerialNumber] call syncFunction type: " + SerialNumber);
}
updateFirmware
Updates the device firmware.
void updateFirmware(DOMString SoftwareID, DOMString SWUFileName, DOMString SWVersion, DOMString SWURL, long SWTotalBytes);
Product : B2B (LFD, HTV)
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Parameters :
- SoftwareID : Unique firmware ID
- SWUFileName : BEM file name
- SWVersion : Firmware version
- SWURL : Full path to the BEM file
- SWTotalBytes : BEM file size
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type InvalidValuesError if any input parameter contains an invalid value
- with the error type NotSupportedError if this feature is not supported
- with the error type TypeMismatchError if an input parameter is not compatible with its expected type
Since : 6.5
Code Example :
var SoftwareID = "0";
var SWUFileName = "upgrade.bem";
var SWVersion = "T-HKMLAKUC 0227.20";
var SWURL = "http://10.88.43.36:8080/New2016/Saurabh/swupdate/T-HKMLAKUC_0227_20/image/upgrade.bem";
var SWTotalBytes = 1007396825;
webapis.systemcontrol.updateFirmware(SoftwareID, SWUFileName, SWVersion, SWURL, SWTotalBytes);
setUpdateFirmwareListener
Registers an asynchronous onchange firmware update progress callback.
void setUpdateFirmwareListener(UpdateFirmwareProgressChangedCallback onchange);
Product : B2B (LFD, HTV)
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Parameters :
- onchange : Callback method to invoke
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type NotSupportedError if this feature is not supported
- with the error type TypeMismatchError if an input parameter is not compatible with its expected type
Since : 6.5
Code Example :
var onchange = function(data) {
console.log("[UpdateFirmwareProgressChangedCallback] progress :" + data + " changed");
}
try {
webapis.systemcontrol.setUpdateFirmwareListener(onchange);
} catch (e) {
console.log("setUpdateFirmwareListener exception [" + e.code + "] name: " + e.name + " message: " + e.message););
}
unsetUpdateFirmwareListener
Unregisters the asynchronous onChange firmware update progress callback.
void unsetUpdateFirmwareListener();
Product : B2B (LFD, HTV)
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type NotSupportedError if this feature is not supported
Since : 6.5
Code Example :
function unsetUpdateFirmwareListener() {
try {
console.log("begin unsetUpdateFirmwareListener");
webapis.systemcontrol.unsetUpdateFirmwareListener();
} catch (e) {
console.log("unsetUpdateFirmwareListener exception [" + e.code + "] name: " + e.name + " message: " + e.message);
return;
}
}
setScreenLampSchedule
Defines the screen lamp schedule for the device, consisting of time of day and lamp brightness level.
void setScreenLampSchedule(LampScheduleInfo info);
Product : B2B (LFD)
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Parameters :
- info : Object containing the times and levels to be set
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type TypeMismatchError if an input parameter is not compatible with its expected type
- with the error type NotSupportedError if this feature is not supported
- with the error type InvalidValuesError if any input parameter contains an invalid value
Since : 6.5
Code Example :
var info = {
"use" : "ON",
"firstTime" : "08:55",
"level1" : 30,
"secondTime" : "16:50",
"level2" : 80
};
try {
webapis.systemcontrol.setScreenLampSchedule(info);
} catch (e) {
console.log("[setScreenLampSchedule] call syncFunction exception [" + e.code + "] name: " + e.name + " message: " + e.message);
}
getScreenLampSchedule
Retrieves screen lamp schedule information for the device.
LampScheduleInfo getScreenLampSchedule();
Product : B2B (LFD)
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Return Value :
- LampScheduleInfo : LampScheduleInfo object containing time and level information
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type NotSupportedError if this feature is not supported
Since : 6.5
Code Example :
var ScreenLampSchedule = null;
try {
ScreenLampSchedule = webapis.systemcontrol.getScreenLampSchedule();
} catch (e) {
console.log("[getScreenLampSchedule] call syncFunction exception [" + e.code + "] name: " + e.name + " message: " + e.message);
}
if (ScreenLampSchedule) {
console.log("[getScreenLampSchedule] call syncFunction type: " + ScreenLampSchedule);
}
setPanelMute
Enables or disables panel mute on the device.
void setPanelMute(Activation enable);
Product : B2B (LFD)
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Parameters :
- enable : Whether panel mute is enabled: ON to enable, OFF to disable
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type TypeMismatchError if an input parameter is not compatible with its expected type
- with the error type NotSupportedError if this feature is not supported
- with the error type InvalidValuesError if any input parameter contains an invalid value
Since : 6.5
Code Example :
try {
webapis.systemcontrol.setPanelMute("ON");
} catch (e) {
console.log("[setPanelMute] call syncFunction exception [" + e.code + "] name: " + e.name + " message: " + e.message);
}
getPanelMute
Retrieves the panel mute status of the device.
Activation getPanelMute();
Product : B2B (LFD)
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Return Value :
- Activation : Panel mute status
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type NotSupportedError if this feature is not supported
- with the error type UnknownError for any other error
Since : 6.5
Code Example :
var PanelMuteOnOff = null;
try {
PanelMuteOnOff = webapis.systemcontrol.getPanelMute();
} catch (e) {
console.log("[getPanelMute] call syncFunction exception [" + e.code + "] name: " + e.name + " message: " + e.message);
}
if (PanelMuteOnOff) {
console.log("[getPanelMute] call syncFunction type: " + PanelMuteOnOff);
}
setSafetyLock
Enables or disables the safety lock on the device. When the safety lock is enabled, PIN entry
is required when an input signal is received.
void setSafetyLock(Activation enable);
Product : B2B (LFD)
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Parameters :
- enable : Whether the safety lock is enabled: ON to enable, OFF to disable
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type TypeMismatchError if an input parameter is not compatible with its expected type
- with the error type NotSupportedError if this feature is not supported
- with the error type InvalidValuesError if any input parameter contains an invalid value
Since : 6.5
Code Example :
try {
webapis.systemcontrol.setSafetyLock("ON");
} catch (e) {
console.log("[setSafetyLock] call syncFunction exception [" + e.code + "] name: " + e.name + " message: " + e.message);
}
getSafetyLock
Retrieves the safety lock status of the device.
Activation getSafetyLock();
Product : B2B (LFD)
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Return Value :
- Activation : Safety lock status
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type NotSupportedError if this feature is not supported
- with the error type UnknownError for any other error
Since : 6.5
Code Example :
var SafetyLock = null;
try {
SafetyLock = webapis.systemcontrol.getSafetyLock();
} catch (e) {
console.log("[getSafetyLock] call syncFunction exception [" + e.code + "] name: " + e.name + " message: " + e.message);
}
if (SafetyLock) {
console.log("[getSafetyLock] call syncFunction type: " + SafetyLock);
}
getOnScreenMenuOrientation
Retrieves the menu orientation of the device.
ScreenOrientation getOnScreenMenuOrientation();
Product : B2B (LFD)
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Return Value :
- ScreenOrientation : Menu orientation
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type NotSupportedError if this feature is not supported
- with the error type UnknownError for any other error
Since : 6.5
Code Example :
var ScreenMenuOrientation = null;
try {
ScreenMenuOrientation = webapis.systemcontrol.getOnScreenMenuOrientation();
} catch (e) {
console.log("[getOnScreenMenuOrientation] call syncFunction exception [" + e.code + "] name: " + e.name + " message: " + e.message);
}
if (ScreenMenuOrientation) {
console.log("[getOnScreenMenuOrientation] call syncFunction type: " + ScreenMenuOrientation);
}
getSourceOrientation
Retrieves the source orientation of the device.
ScreenOrientation getSourceOrientation(SourceType source);
Product : B2B (LFD)
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Parameters :
- source : value want to know the orientation of the source.
Return Value :
- ScreenOrientation : Source orientation
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type NotSupportedError if this feature is not supported
- with the error type UnknownError for any other error
Since : 6.5
Code Example :
var Result = null;
try {
Result = webapis.systemcontrol.getSourceOrientation("HDMI1");
console.log("[getSourceOrientation] call syncFunction type: " + Result);
} catch (e) {
console.log("[getSourceOrientation] call syncFunction exception [" + e.code + "] name: " + e.name + " message: " + e.message);
}
setPCConnection
Sets the computer connection type for the device.
void setPCConnection(PCConnection type);
Product : B2B (LFD)
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Parameters :
- type : Computer connection type
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type TypeMismatchError if an input parameter is not compatible with its expected type
- with the error type NotSupportedError if this feature is not supported
- with the error type InvalidValuesError if any input parameter contains an invalid value
Since : 6.5
Code Example :
try {
webapis.systemcontrol.setPCConnection("RJ45");
} catch (e) {
console.log("[setPCConnection] call syncFunction exception [" + e.code + "] name: " + e.name + " message: " + e.message);
}
getPCConnection
Retrieves the computer connection type for the device.
PCConnection getPCConnection();
Product : B2B (LFD)
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Return Value :
- PCConnection : Computer connection type
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type NotSupportedError if this feature is not supported
- with the error type UnknownError for any other error
Since : 6.5
Code Example :
var PCConnection = null;
try {
PCConnection = webapis.systemcontrol.getPCConnection();
} catch (e) {
console.log("[getPCConnection] call syncFunction exception [" + e.code + "] name: " + e.name + " message: " + e.message);
}
if(PCConnection){
console.log("[getPCConnection] call syncFunction type: " + PCConnection);
}
setMessageDisplay
Enables or disables On Screen Display (OSD) for system messages on the device.
The following messages are affected by this setting:
Source Info, No Signal message, MDC message.
void setMessageDisplay(Activation enable);
Product : B2B (LFD)
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Parameters :
- enable : OSD message display status: ON to enable, OFF to disable
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type TypeMismatchError if an input parameter is not compatible with its expected type
- with the error type NotSupportedError if this feature is not supported
- with the error type InvalidValuesError if any input parameter contains an invalid value
Since : 6.5
Code Example :
try {
webapis.systemcontrol.setMessageDisplay("ON");
} catch (e) {
console.log("[setMessageDisplay] call syncFunction exception [" + e.code + "] name: " + e.name + " message: " + e.message);
}
getMessageDisplay
Retrieves the OSD message display status of the device. The following messages are affected by this setting:
Source Info, No Signal message, MDC message.
If any of these message types is set to ON, this method returns ON.
Activation getMessageDisplay();
Product : B2B (LFD)
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Return Value :
- Activation : OSD message display status
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type NotSupportedError if this feature is not supported
- with the error type UnknownError for any other error
Since : 6.5
Code Example :
var MessageDisplay = null;
try {
MessageDisplay = webapis.systemcontrol.getMessageDisplay();
} catch (e) {
console.log("[getMessageDisplay] call syncFunction exception [" + e.code + "] name: " + e.name + " message: " + e.message);
}
if(MessageDisplay){
console.log("[getMessageDisplay] call syncFunction type: " + MessageDisplay);
}
setCustomAppInfo
Defines the set customapp url and timeout.
void setCustomAppInfo(CustomAppInfo info);
Product : B2B (HTV)
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Parameters :
- info : Object containing the times and url to be set
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type TypeMismatchError if an input parameter is not compatible with its expected type
- with the error type NotSupportedError if this feature is not supported
- with the error type InvalidValuesError if any input parameter contains an invalid value
Since : 6.5
Code Example :
var info = {
"downloadServerAddress" : "http://testserver/testwebapp/check",
"connectionTimeout" : "30SEC"
};
try {
webapis.systemcontrol.setCustomAppInfo(info);
} catch (e) {
console.log("[setCustomAppInfo] call syncFunction exception [" + e.code + "] name: " + e.name + " message: " + e.message);
}
getCustomAppInfo
Retrieves information of customapp url and timeout.
CustomAppInfo getCustomAppInfo();
Product : B2B (HTV)
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Return Value :
- CustomAppInfo : CustomAppInfo object containing time and url information
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type NotSupportedError if this feature is not supported
Since : 6.5
Code Example :
var CustomAppInfo = null;
try {
CustomAppInfo = webapis.systemcontrol.getCustomAppInfo();
} catch (e) {
console.log("[getCustomAppInfo] call syncFunction exception [" + e.code + "] name: " + e.name + " message: " + e.message);
}
if(CustomAppInfo) {
console.log("[getCustomAppInfo] call syncFunction type: " + CustomAppInfo);
}
setIRLock
Defines the set IR Lock
void setIRLock(Activation option);
Product : B2B (LFD)
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Parameters :
- option : Whether the IR Lock option is to be enable or disable
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type NotSupportedError if this feature is not supported
- with the error type UnknownError for any other error
- with the error type TypeMismatchError if an input parameter is not compatible with its expected type
Since : 6.5
Code Example :
var option = "ON";
try {
webapis.systemcontrol.setIRLock(option);
} catch (e) {
console.log("[setIRLock] call syncFunction exception [" + e.code + "] name: " + e.name + " message: " + e.message);
}
getIRLock
Retrieves information of IR Lock.
Activation getIRLock();
Product : B2B (LFD)
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Return Value :
- Activation : IRLock enable option
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type NotSupportedError if this feature is not supported
- with the error type UnknownError for any other error
Since : 6.5
Code Example :
var option = null;
try {
option = webapis.systemcontrol.getIRLock();
} catch (e) {
console.log("[getIRLock] call syncFunction exception [" + e.code + "] name: " + e.name + " message: " + e.message);
}
console.log("[getIRLock] call syncFunction type: " + option);
setButtonLock
Defines the set Button Lock
void setButtonLock(Activation option);
Product : B2B (LFD)
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Parameters :
- option : Whether the Button Lock option is to be enable or disable
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type NotSupportedError if this feature is not supported
- with the error type UnknownError for any other error
- with the error type TypeMismatchError if an input parameter is not compatible with its expected type
Since : 6.5
Code Example :
var option = "ON";
try {
webapis.systemcontrol.setButtonLock(option);
} catch (e) {
console.log("[setButtonLock] call syncFunction exception [" + e.code + "] name: " + e.name + " message: " + e.message);
}
getButtonLock
Retrieves information of Button Lock.
Activation getButtonLock();
Product : B2B (LFD)
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Return Value :
- Activation : Button Lock enable option
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type NotSupportedError if this feature is not supported
- with the error type UnknownError for any other error
Since : 6.5
Code Example :
var option = null;
try {
option = webapis.systemcontrol.getButtonLock();
} catch (e) {
console.log("[getButtonLock] call syncFunction exception [" + e.code + "] name: " + e.name + " message: " + e.message);
}
console.log("[getButtonLock] call syncFunction type: " + option);
setAutoPowerOn
Defines the set auto poweron
void setAutoPowerOn(Activation option);
Product : B2B (LFD)
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Parameters :
- option : Whether the Auto poweron option is to be enable or disable
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type NotSupportedError if this feature is not supported
- with the error type UnknownError for any other error
- with the error type TypeMismatchError if an input parameter is not compatible with its expected type
Since : 6.5
Code Example :
var option = "ON";
try {
webapis.systemcontrol.setAutoPowerOn(option);
} catch (e) {
console.log("[setAutoPowerOn] call syncFunction exception [" + e.code + "] name: " + e.name + " message: " + e.message);
}
getAutoPowerOn
Retrieves information of auto poweron.
Activation getAutoPowerOn();
Product : B2B (LFD)
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Return Value :
- Activation : auto poweron enable option
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type NotSupportedError if this feature is not supported
- with the error type UnknownError for any other error
Since : 6.5
Code Example :
var option = null;
try {
option = webapis.systemcontrol.getAutoPowerOn();
} catch (e) {
console.log("[getAutoPowerOn] call syncFunction exception [" + e.code + "] name: " + e.name + " message: " + e.message);
}
console.log("[getAutoPowerOn] call syncFunction type: " + option);
setMagicinfoServerInfo
Defines the set MaigcInfo Server.
void setMagicinfoServerInfo(MagicinfoServerInfo info);
Product : B2B (LFD)
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Parameters :
- info : Object containing the ssl, address, port information
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type NotSupportedError if this feature is not supported
- with the error type InvalidValuesError if any input parameter contains an invalid value
- with the error type UnknownError for any other error
- with the error type TypeMismatchError if an input parameter is not compatible with its expected type
Since : 6.5
Code Example :
var info = {
"ssl" : "http",
"address" : "100.43.33.55",
"port" : "8080"
};
try {
webapis.systemcontrol.setMagicinfoServerInfo(info);
} catch (e) {
console.log("[setMagicinfoServerInfo] call syncFunction exception [" + e.code + "] name: " + e.name + " message: " + e.message);
}
getMagicinfoServerInfo
Retrieves information of MagicInfo Server Address.
MagicinfoServerInfo getMagicinfoServerInfo();
Product : B2B (LFD)
Privilege Level : Partner
Privilege : http://developer.samsung.com/privilege/systemcontrol
Return Value :
- MagicinfoServerInfo : MagicinfoServerInfo object containing the ssl, address, port information
Exceptions :
- WebAPIException
- with the error type SecurityError if the application does not have the privilege to call this method
- with the error type NotSupportedError if this feature is not supported
- with the error type UnknownError for any other error
Since : 6.5
Code Example :
var info = null;
try {
info = webapis.systemcontrol.getMagicinfoServerInfo();
} catch (e) {
console.log("[getMagicinfoServerInfo] call syncFunction exception [" + e.code + "] name: " + e.name + " message: " + e.message);
}
console.log("[getMagicinfoServerInfo] call syncFunction type: " + info);
3. Full WebIDL
module SystemControl {
enum Activation {
"ON",
"OFF"
};
enum ScreenOrientation {
"LANDSCAPE",
"PORTRAIT",
"AUTO"
};
enum PCConnection {
"RJ45",
"RS232",
"INVALID"
};
enum CustomAppTimeout {
"30SEC",
"60SEC",
"90SEC",
"120SEC",
"150SEC",
"180SEC",
"240SEC",
"300SEC"
};
enum SourceType {
"TV",
"PC",
"HDMI1",
"HDMI2",
"HDMI3",
"DP",
"DVI",
"MAGICINFO",
"OPS",
"HDBT",
"AV",
"COMP",
"MAGICINFOS",
"INTERNAL_USB",
"URL_LAUNCHER",
"SCREEN_MIRRORING"
};
enum CapturePath {
"wgt-private-data",
"wgt-private-tmp"
};
[NoInterfaceObject] interface LampScheduleInfo {
attribute Activation use;
attribute DOMString firstTime;
attribute long level1;
attribute DOMString secondTime;
attribute long level2;
};
[NoInterfaceObject] interface CustomAppInfo {
attribute DOMString downloadServerAddress;
attribute CustomAppTimeout connectionTimeout;
};
[NoInterfaceObject] interface MagicinfoServerInfo {
attribute DOMString ssl;
attribute DOMString address;
attribute DOMString port;
};
[NoInterfaceObject] interface SystemControlManagerObject {
readonly attribute SystemControlManager systemcontrol;
};
WebApi implements SystemControlManagerObject;
[Callback = FunctionOnly, NoInterfaceObject] interface UpdateFirmwareProgressChangedCallback {
void onchange(long progress);
};
[NoInterfaceObject] interface SystemControlManager {
DOMString getVersion();
void captureScreen(optional CapturePath? path);
void rebootDevice();
DOMString getSerialNumber();
void updateFirmware(DOMString SoftwareID, DOMString SWUFileName, DOMString SWVersion, DOMString SWURL, long SWTotalBytes);
void setUpdateFirmwareListener(UpdateFirmwareProgressChangedCallback onchange);
void unsetUpdateFirmwareListener();
void setScreenLampSchedule(LampScheduleInfo info);
LampScheduleInfo getScreenLampSchedule();
void setPanelMute(Activation enable);
Activation getPanelMute();
void setSafetyLock(Activation enable);
Activation getSafetyLock();
ScreenOrientation getOnScreenMenuOrientation();
ScreenOrientation getSourceOrientation(SourceType source);
void setPCConnection(PCConnection type);
PCConnection getPCConnection();
void setMessageDisplay(Activation enable);
Activation getMessageDisplay();
void setCustomAppInfo(CustomAppInfo info);
CustomAppInfo getCustomAppInfo();
void setIRLock(Activation option);
Activation getIRLock();
void setButtonLock(Activation option);
Activation getButtonLock();
void setAutoPowerOn(Activation option);
Activation getAutoPowerOn();
void setMagicinfoServerInfo(MagicinfoServerInfo info);
MagicinfoServerInfo getMagicinfoServerInfo();
};
};