Filter
-
Content Type
-
Category
Mobile/Wearable
Visual Display
Digital Appliance
Platform
Mobile/Wearable
Visual Display
Digital Appliance
Platform
Filter
Develop Smart Hospitality Display
apiconsole log "version value = " + value ; } catch error { console log "error code = " + error code ; } 2 4 serviceconnectorobject defines a webapi object instance [nointerfaceobject] interface serviceconnectorobject { attribute serviceconnector serviceconnector; }; allshare implements serviceconnectorobject; attributes serviceconnector serviceconnector provides interfaces for connecting to the asf service 2 5 serviceprovidercreatesuccesscallback defines the callback invoked when a serviceprovider object is created successfully [callback=functiononly, nointerfaceobject] interface serviceprovidercreatesuccesscallback { void onsuccess serviceprovider serviceprovider ; }; methods onsuccess callback method invoked when a serviceprovider object is successfully created void onsuccess serviceprovider serviceprovider ; privilege level public privilege http //developer samsung com/privilege/allshare parameters serviceprovider created serviceprovider object code example // onsuccess sprovidercallback function sprovidercallback provider { console log "the service provider was obtained" ; } // define the serviceprovider creation error callback function eprovidercallback error, state { console log error name ; console log "current asf service state " + state ; } // try to create the serviceprovider object try { webapis allshare serviceconnector createserviceprovider sprovidercallback, eprovidercallback ; } catch e { console log e message ; } 2 6 serviceprovidererrorcallback defines the callback invoked if a serviceprovider object operation fails [callback=functiononly, nointerfaceobject] interface serviceprovidererrorcallback { void onerror webapierror error, servicestate state ; }; methods onerror callback method invoked if a serviceprovider operation fails void onerror webapierror error, servicestate state ; privilege level public privilege http //developer samsung com/privilege/allshare parameters error object indicating the error type and message state current service state exceptions webapiexception with error type unknownerror, for any other error code example // onerror eprovidercallback function sprovidercallback provider { console log "the service provider was obtained" ; } // define the serviceprovider creation error callback function eprovidercallback error, state { console log error name ; console log "current asf service state " + state ; } // try to create the serviceprovider object try { webapis allshare serviceconnector createserviceprovider sprovidercallback, eprovidercallback ; } catch e { console log e message ; } 2 7 serviceconnector provides the connection to the allshare framework asf service [nointerfaceobject] interface serviceconnector { void createserviceprovider optional serviceprovidercreatesuccesscallback? successcallback, optional serviceprovidererrorcallback? errorcallback ; void deleteserviceprovider optional successcallback? successcallback, optional serviceprovidererrorcallback? errorcallback ; serviceprovider getserviceprovider ; }; methods createserviceprovider creates a serviceprovider object void createserviceprovider optional serviceprovidercreatesuccesscallback? successcallback, optional serviceprovidererrorcallback? errorcallback ; product tv, av, b2b privilege level public privilege http //developer samsung com/privilege/allshare parameters successcallback [optional][nullable] callback method to invoke if the request is successful errorcallback [optional][nullable] callback method to invoke if the request fails exceptions webapiexception with error type typemismatcherror, if an input parameter is not compatible with its expected type with error type unknownerror, for any other error with error type securityerror, if the application does not have the privilege to call this method since 2 3 code example // define the serviceprovider creation success callback function sprovidercallback provider { console log "the service provider was obtained" ; } // define the serviceprovider creation error callback function eprovidercallback error, state { console log error name ; console log "current asf service state " + state ; } // try to create the serviceprovider object try { webapis allshare serviceconnector createserviceprovider sprovidercallback, eprovidercallback ; } catch e { console log e message ; } deleteserviceprovider deletes a serviceprovider object void deleteserviceprovider optional successcallback? successcallback, optional serviceprovidererrorcallback? errorcallback ; product tv, av, b2b privilege level public privilege http //developer samsung com/privilege/allshare parameters successcallback [optional][nullable] callback method to invoke if the request is successful errorcallback [optional][nullable] callback method to invoke if the request fails exceptions webapiexception with error type typemismatcherror, if an input parameter is not compatible with its expected type with error type unknownerror, for any other error with error type securityerror, if the application does not have the privilege to call this method since 2 3 code example // you must already have a serviceprovider object var serviceprovider; // define the serviceprovider deletion success callback function sproviderdeletecallback { console log "the asf service provider has been deleted properly " ; } // define the serviceprovider deletion error callback function eproviderdeletecallback error, state { console log error name ; console log "the current asf service state " + state ; } // try to delete the serviceprovider object try { webapis allshare serviceconnector deleteserviceprovider sproviderdeletecallback, eproviderdeletecallback ; } catch e { console log e message ; } getserviceprovider returns a serviceprovider object that is connected to the allshare framework serviceprovider getserviceprovider ; product tv, av, b2b privilege level public privilege http //developer samsung com/privilege/allshare return value serviceprovider serviceprovider serviceprovider object connected to the allshare framework exceptions webapiexception with error type unknownerror, for any other error with error type securityerror, if the application does not have the privilege to call this method since 2 3 code example try { // you must already have a serviceprovider object var serviceprovider = webapis allshare serviceconnector getserviceprovider ; if serviceprovider == null { console log "service provider was not created properly" ; } } catch e { console log e message ; } 2 8 serviceprovider provides methods for obtaining a devicefinder object [nointerfaceobject] interface serviceprovider { devicefinder getdevicefinder ; servicestate getservicestate ; }; methods getdevicefinder returns the devicefinder object used to find allshare devices devicefinder getdevicefinder ; product tv, av, b2b privilege level public privilege http //developer samsung com/privilege/allshare return value devicefinder devicefinder devicefinder object exceptions webapiexception with error type unknownerror, for any other error with error type securityerror, if the application does not have the privilege to call this method since 2 3 code example var serviceprovider = webapis allshare serviceconnector getserviceprovider ; try { devicefinder = serviceprovider getdevicefinder ; } catch e { console log e name ; } getservicestate retrieves the current asf service state servicestate getservicestate ; product tv, av, b2b privilege level public privilege http //developer samsung com/privilege/allshare return value servicestate servicestate servicestate value exceptions webapiexception with error type unknownerror, for any other error with error type securityerror, if the application does not have the privilege to call this method since 2 3 code example // you must already have a serviceprovider object var serviceprovider; try { servicestate = serviceprovider getservicestate ; } catch e { console log e name ; } 2 9 devicediscoverycallback defines a generic callback for device discovery event notifications [callback, nointerfaceobject] interface devicediscoverycallback { void ondeviceadded device device ; void ondeviceremoved device device ; }; methods ondeviceadded callback method invoked when a new device appears on the network void ondeviceadded device device ; privilege level public privilege http //developer samsung com/privilege/allshare parameters device newly-discovered device code example var serviceprovider = webapis allshare serviceconnector getserviceprovider ; var monitoringcb = { ondeviceadded function device { console log "new device has appeared " + device name ; }, ondeviceremoved function device { console log "a device has disappeared " + device name ; } } try { var listenerid = serviceprovider getdevicefinder adddevicediscoverylistener monitoringcb ; } catch e { console log e name ; } ondeviceremoved callback method invoked when a device disappears from the network void ondeviceremoved device device ; privilege level public privilege http //developer samsung com/privilege/allshare parameters device device that has disappeared code example var serviceprovider = webapis allshare serviceconnector getserviceprovider ; var monitoringcb = { ondeviceadded function device { console log "new device has appeared " + device name ; }, ondeviceremoved function device { console log "a device has disappeared " + device name ; } } try { var listenerid = serviceprovider getdevicefinder adddevicediscoverylistener monitoringcb ; } catch e { console log e name ; } 2 10 icon defines icon information [nointerfaceobject] interface icon { readonly attribute long depth; readonly attribute long height; readonly attribute long width; readonly attribute domstring mimetype; readonly attribute domstring iconuri; }; attributes readonly long depth icon color depth, in bits per pixel readonly long height icon height readonly long width icon width readonly domstring mimetype icon mime type readonly domstring iconuri icon uri 2 11 devicefinder provides methods for finding allshare devices [nointerfaceobject] interface devicefinder { device getdevice devicetype devicetype, deviceid id ; device[] getdevicelist devicetype devicetype ; void refresh ; long adddevicediscoverylistener devicediscoverycallback devicediscoverycallback ; void removedevicediscoverylistener long devicediscoverylistener ; object getproperty string propertyname, device deviceinfo ; }; methods getdevice returns a device object with a specific device id and type device getdevice devicetype devicetype, deviceid id ; product tv, av, b2b privilege level public privilege http //developer samsung com/privilege/allshare parameters devicetype device type i e mediaprovider id the unique id of the device return value device device device object exceptions webapiexception with error type typemismatcherror, if an input parameter is not compatible with its expected type with error type unknownerror, for any other error with error type securityerror, if the application does not have the privilege to call this method since 2 3 code example var serviceprovider = webapis allshare serviceconnector getserviceprovider ; var mediaproviderid; // the mediaprovider's device id is assumed to be known try { var devicefinder = serviceprovider getdevicefinder ; // get the mediaprovider device object var device = devicefinder getdevice "mediaprovider", mediaproviderid ; // print the device id console log device id ; } catch e { console log e name ; } getdevicelist lists the discovered devices with a specific device type device[] getdevicelist devicetype devicetype ; product tv, av, b2b privilege level public privilege http //developer samsung com/privilege/allshare parameters devicetype device type i e mediaprovider return value device[] device[] device array exceptions webapiexception with error type typemismatcherror, if an input parameter is not compatible with its expected type with error type unknownerror, for any other error with error type securityerror, if the application does not have the privilege to call this method since 2 3 code example var serviceprovider = webapis allshare serviceconnector getserviceprovider try { var devicefinder = serviceprovider getdevicefinder ; var devices = devicefinder getdevicelist "mediaprovider" ; // print the number of available mediaprovider devices console log devices length ; } catch e { console log e name ; } refresh refreshes the list of devices on the network void refresh ; product tv, av, b2b privilege level public privilege http //developer samsung com/privilege/allshare exceptions webapiexception with error type securityerror, if the application does not have the privilege to call this method with error type unknownerror, for any other error since 2 3 code example var serviceprovider = webapis allshare serviceconnector getserviceprovider ; try { var devicefinder = serviceprovider getdevicefinder ; var providers = devicefinder getdevicelist "mediaprovider" ; if providers length == 0 { // refresh the device list and retrieve the provider list again devicefinder refresh ; providers = devicefinder getdevicelist "mediaprovider" ; } } catch e { console log e name ; } adddevicediscoverylistener registers a device discovery event listener long adddevicediscoverylistener devicediscoverycallback devicediscoverycallback ; product tv, av, b2b privilege level public privilege http //developer samsung com/privilege/allshare parameters devicediscoverycallback callback method invoked when a device discovery event occurs return value long long event listener id exceptions webapiexception with error type typemismatcherror, if an input parameter is not compatible with its expected type with error type unknownerror, for any other error with error type securityerror, if the application does not have the privilege to call this method since 2 3 code example var serviceprovider = webapis allshare serviceconnector getserviceprovider ; var monitoringcb = { ondeviceadded function device { console log "new device has appeared " + device name ; }, ondeviceremoved function device { console log "a device has disappeared " + device name ; } } try { var listenerid = serviceprovider getdevicefinder adddevicediscoverylistener monitoringcb ; } catch e { console log e name ; } removedevicediscoverylistener unregisters a device discovery event listener void removedevicediscoverylistener long devicediscoverylistener ; product tv, av, b2b privilege level public privilege http //developer samsung com/privilege/allshare parameters devicediscoverylistener event listener id exceptions webapiexception with error type typemismatcherror, if an input parameter is not compatible with its expected type with error type unknownerror, for any other error with error type securityerror, if the application does not have the privilege to call this method since 2 3 code example var serviceprovider = webapis allshare serviceconnector getserviceprovider ; var listenerid; // listener id returned from adddevicediscoverylistener var monitoringcb = { ondeviceadded function device { console log "new device has appeared " + device name ; }, ondeviceremoved function device { console log "a device has disappeared " + device name ; } } try { var listenerid = serviceprovider getdevicefinder adddevicediscoverylistener monitoringcb ; serviceprovider getdevicefinder removedevicediscoverylistener listenerid ; } catch e { console log e name ; } getproperty get properties of a device object getproperty string propertyname, device deviceinfo ; product tv, av, b2b privilege level public privilege http //developer samsung com/privilege/allshare parameters propertyname string deviceinfo deviceobject return value object object exceptions webapiexception with error type typemismatcherror, if an input parameter is not compatible with its expected type with error type securityerror, if the application does not have the privilege to call this method with error type unknownerror, for any other error since 2 3 code example var serviceprovider = webapis allshare serviceconnector getserviceprovider ; var mediaproviderid; // the mediaprovider's device id is assumed to be known var propertyname; // the mediaprovider's propertyname is assumed to be known try { var devicefinder = serviceprovider getdevicefinder ; // get the mediaprovider device object var device = devicefinder getdevice "mediaprovider", mediaproviderid ; var propertydata = devicefinder getproperty propertyname , device ; console log propertydata } catch e { console log e name ; } 2 12 device retrieves information about a device [nointerfaceobject] interface device { readonly attribute deviceid id; readonly attribute devicedomain devicedomain; readonly attribute devicetype devicetype; readonly attribute domstring ipaddress; readonly attribute domstring? modelname; readonly attribute domstring name; readonly attribute domstring nic; }; attributes readonly deviceid id unique device id readonly devicedomain devicedomain device domain readonly devicetype devicetype device type readonly domstring ipaddress device ipv4 address readonly domstring modelname [nullable] device model name readonly domstring name device name readonly domstring nic device nic network interface controller name 2 13 mediaprovidersuccesscallback defines the callback invoked when a provider object completes a retrieval operation successfully [callback=functiononly, nointerfaceobject] interface mediaprovidersuccesscallback { void onsuccess item[] itemlist, boolean endofitems, deviceid providerid ; }; methods onsuccess callback method for a successful retrieval request void onsuccess item[] itemlist, boolean endofitems, deviceid providerid ; privilege level public privilege http //developer samsung com/privilege/allshare parameters itemlist item list if there are no items, an empty list is returned endofitems end of items flag providerid provider device identifier code example //onsuccess searchcb var serviceprovider = webapis allshare serviceconnector getserviceprovider ; var keyword = "foo"; // define a browse callback function searchcb list, endofitem, providerid { // retrieve the item list } function errorcb error, device { console log device + " raises " + error ; } // define a filter to browse videos only var filter = new webapis attributefilter "itemtype", null, {"video"} ; try { var providers = serviceprovider getdevicefinder getdevicelist "mediaprovider" ; if providers length > 0 { // search for the keyword in the first dms providers[0] search keyword, 0, 40, searchcb, errorcb, filter ; } } catch e { console log e message ; } 2 14 mediaprovidererrorcallback defines a generic error callback for provider-related operations [callback=functiononly, nointerfaceobject] interface mediaprovidererrorcallback { void onerror webapierror error, deviceid providerid ; }; methods onerror callback method invoked if an error occurs void onerror webapierror error, deviceid providerid ; privilege level public privilege http //developer samsung com/privilege/allshare parameters error object indicating the error type and message providerid provider device identifier exceptions webapiexception with error type securityerror, if the application does not have the privilege to call this method code example //onerror errorcb var serviceprovider = webapis allshare serviceconnector getserviceprovider ; var keyword = "foo"; // define a browse callback function searchcb list, endofitem, providerid { // retrieve the item list } function errorcb error, device { console log device + " raises " + error ; } // define a filter to browse videos only var filter = new webapis attributefilter "itemtype", null, {"video"} ; try { var providers = serviceprovider getdevicefinder getdevicelist "mediaprovider" ; if providers length > 0 { // search for the keyword in the first dms providers[0] search keyword, 0, 40, searchcb, errorcb, filter ; } } catch e { console log e message ; } 2 15 mediaprovider enables sharing media content between devices [nointerfaceobject] interface mediaprovider { readonly attribute boolean issearchable; readonly attribute item rootfolder; void browse item folderitem, unsigned long startindex, unsigned long requestcount, mediaprovidersuccesscallback browsecallback, optional mediaprovidererrorcallback? errorcallback, optional abstractfilter? browsefilter, optional sortmode? sortmode ; void search domstring keyword, unsigned long startindex, unsigned long requestcount, mediaprovidersuccesscallback successcallback, optional mediaprovidererrorcallback? errorcallback, optional abstractfilter? searchfilter ; }; attributes readonly boolean issearchable whether the provider supports the search capability readonly item rootfolder root folder object methods browse gets the item list in a folder at the specified starting index and count void browse item folderitem, unsigned long startindex, unsigned long requestcount, mediaprovidersuccesscallback browsecallback, optional mediaprovidererrorcallback? errorcallback, optional abstractfilter? browsefilter, optional sortmode? sortmode ; product tv, av, b2b privilege level public privilege http //developer samsung com/privilege/allshare parameters folderitem folder startindex starting zero-based offset requestcount requested number of entries browsecallback callback invoked when the browse operation is successful it returns a set of items matching the filter errorcallback [optional][nullable] generic error callback for provider-related operations browsefilter [optional][nullable] browse filter to be applied parameters can include attributefilter objects constructed with "itemtype", null , itemtype[] sortmode [optional][nullable] sorting to use on the content list sorting by title, date, artist, or albumtitle attribute is only supported on the tizen web platform other web platforms ignore this parameter exceptions webapiexception with error type typemismatcherror, if an input parameter is not compatible with its expected type with error type unknownerror, for any other error with error type securityerror, if the application does not have the privilege to call this method since 2 3 code example var serviceprovider = webapis allshare serviceconnector getserviceprovider ; // define a browse callback function browsecb list, endofitem, providerid { // retrieve the item list } function errorcb error, deviceid { console log error message ; } // define a filter to browse videos only var filter = new webapis attributefilter "itemtype", null, {"video"} ; // define a sort mode var mode = new webapis sortmode "title", "asc" ; try { var providers = serviceprovider getdevicefinder getdevicelist "mediaprovider" ; if providers length > 0 { // retrieves the first dms from the root folder providers[0] browse providers[0] rootfolder, 0, 10, browsecb, errorcb, filter, mode ; } } catch e { console log e message ; } search searches content for a specific keyword void search domstring keyword, unsigned long startindex, unsigned long requestcount, mediaprovidersuccesscallback successcallback, optional mediaprovidererrorcallback? errorcallback, optional abstractfilter? searchfilter ; product tv, av, b2b privilege level public privilege http //developer samsung com/privilege/allshare parameters keyword search keyword startindex starting zero-based offset requestcount requested number of entries successcallback callback to invoke when the search operation is successful it returns a set of items matching the filter errorcallback [optional][nullable] generic error callback for provider-related operations searchfilter [optional][nullable] filter applied to the search result parameters can include attributefilter objects constructed with "itemtype", null , itemtype[] exceptions webapiexception with error type typemismatcherror, if an input parameter is not compatible with its expected type with error type unknownerror, for any other error with error type securityerror, if the application does not have the privilege to call this method since 2 3 code example var serviceprovider = webapis allshare serviceconnector getserviceprovider ; var keyword = "foo"; // define a browse callback function searchcb list, endofitem, providerid { // retrieve the item list } function errorcb error, device { console log device + " raises " + error ; } // define a filter to browse videos only var filter = new webapis attributefilter "itemtype", null, {"video"} ; try { var providers = serviceprovider getdevicefinder getdevicelist "mediaprovider" ; if providers length > 0 { // search for the keyword in the first dms providers[0] search keyword, 0, 40, searchcb, errorcb, filter ; } } catch e { console log e message ; } 3 full webidl module asfservice { enum itemtype { "audio", "folder", "image", "unknown", "video" }; enum servicestate { "disabled", "enabled", "unknown" }; enum devicetype { "mediaprovider", "unknown" }; enum devicedomain { "local_network", "unknown" }; typedef domstring deviceid; [constructor domstring uri, optional domstring mimetype, optional domstring title ] interface item { readonly attribute domstring albumtitle; readonly attribute domstring artist; readonly attribute date date; readonly attribute unsigned long long duration; readonly attribute domstring extension; readonly attribute double filesize; readonly attribute domstring genre; readonly attribute domstring mimetype; readonly attribute unsigned long? width; readonly attribute unsigned long? height; attribute domstring? subtitleuri; readonly attribute domstring? thumbnailuri; attribute domstring title; readonly attribute itemtype itemtype; readonly attribute domstring itemuri; readonly attribute boolean isrootfolder; readonly attribute itemcontentbuildtype contentbuildtype; }; [nointerfaceobject] interface webapiallshareobject { readonly attribute allshare allshare; }; webapi implements webapiallshareobject; [nointerfaceobject] interface allsharemanager { domstring getversion ; }; [nointerfaceobject] interface serviceconnectorobject { attribute serviceconnector serviceconnector; }; allshare implements serviceconnectorobject; [callback=functiononly, nointerfaceobject] interface serviceprovidercreatesuccesscallback { void onsuccess serviceprovider serviceprovider ; }; [callback=functiononly, nointerfaceobject] interface serviceprovidererrorcallback { void onerror webapierror error, servicestate state ; }; [nointerfaceobject] interface serviceconnector { void createserviceprovider optional serviceprovidercreatesuccesscallback? successcallback, optional serviceprovidererrorcallback? errorcallback ; void deleteserviceprovider optional successcallback? successcallback, optional serviceprovidererrorcallback? errorcallback ; serviceprovider getserviceprovider ; }; [nointerfaceobject] interface serviceprovider { devicefinder getdevicefinder ; servicestate getservicestate ; }; [callback, nointerfaceobject] interface devicediscoverycallback { void ondeviceadded device device ; void ondeviceremoved device device ; }; [nointerfaceobject] interface icon { readonly attribute long depth; readonly attribute long height; readonly attribute long width; readonly attribute domstring mimetype; readonly attribute domstring iconuri; }; [nointerfaceobject] interface devicefinder { device getdevice devicetype devicetype, deviceid id ; device[] getdevicelist devicetype devicetype ; void refresh ; long adddevicediscoverylistener devicediscoverycallback devicediscoverycallback ; void removedevicediscoverylistener long devicediscoverylistener ; object getproperty string propertyname, device deviceinfo ; }; [nointerfaceobject] interface device { readonly attribute deviceid id; readonly attribute devicedomain devicedomain; readonly attribute devicetype devicetype; readonly attribute domstring ipaddress; readonly attribute domstring? modelname; readonly attribute domstring name; readonly attribute domstring nic; }; [callback=functiononly, nointerfaceobject] interface mediaprovidersuccesscallback { void onsuccess item[] itemlist, boolean endofitems, deviceid providerid ; }; [callback=functiononly, nointerfaceobject] interface mediaprovidererrorcallback { void onerror webapierror error, deviceid providerid ; }; [nointerfaceobject] interface mediaprovider { readonly attribute boolean issearchable; readonly attribute item rootfolder; void browse item folderitem, unsigned long startindex, unsigned long requestcount, mediaprovidersuccesscallback browsecallback, optional mediaprovidererrorcallback? errorcallback, optional abstractfilter? browsefilter, optional sortmode? sortmode ; void search domstring keyword, unsigned long startindex, unsigned long requestcount, mediaprovidersuccesscallback successcallback, optional mediaprovidererrorcallback? errorcallback, optional abstractfilter? searchfilter ; }; };
Develop Smart Hospitality Display
apiconsole log "[getversion] call syncfunction exception [" + e code + "] name " + e name + " message " + e message ; } if null !== version { console log "[getversion] call syncfunction type " + version ; } enabledataservice enable broadcast data service broadcast data service provides support for subtitles/captions and other broadcast functionalities this method should be called at the beginning of the web application void enabledataservice broadcastsuccesscallback onsuccess, optional broadcasterrorcallback? onerror ; product b2b htv privilege level partner privilege http //developer samsung com/privilege/broadcast parameters onsuccess callback method to be invoked when this api is successful onerror [optional][nullable] callback method to be invoked when an error has occurred securityerror, if the application does not have the privilege to call this method exceptions webapiexception with error type typemismatcherror, if any input parameter is not compatible with the expected type for that parameter since 6 5 code example var onsuccess = function val { console log "[enabledataservice] success " + val result ; }; var onerror = function error { console log "[enabledataservice] code " + error code + " error name " + error name + " message " + error message ; }; console log "[enabledataservice]" ; webapis broadcast enabledataservice onsuccess, onerror ; disabledataservice disable broadcast data service this method should be called before the web application finishes void disabledataservice broadcastsuccesscallback onsuccess, optional broadcasterrorcallback? onerror ; product b2b htv privilege level partner privilege http //developer samsung com/privilege/broadcast parameters onsuccess callback method to be invoked when this api is successful onerror [optional][nullable] callback method to be invoked when an error has occurred securityerror, if the application does not have the privilege to call this method exceptions webapiexception with error type typemismatcherror, if any input parameter is not compatible with the expected type for that parameter since 6 5 code example var onsuccess = function val { console log "[disabledataservice] success " + val result ; }; var onerror = function error { console log "[disabledataservice] code " + error code + " error name " + error name + " message " + error message ; }; console log "[disabledataservice]" ; webapis broadcast disabledataservice onsuccess, onerror ; gettotalaudioinfo this interface provides methods to get the total audio information audioinfo [] gettotalaudioinfo ; product b2b htv privilege level partner privilege http //developer samsung com/privilege/broadcast return value audioinfo [] multi information of audio exceptions webapiexception with error type securityerror, if the application does not have the privilege to call this method with error type unknownerror in any other error case since 6 5 code example var i, audioinformation; audioinformation = webapis broadcast gettotalaudioinfo ; for i =0; i < audioinformation length; i++ { console log "[gettotalaudioinfo] language " + audioinformation[i] language ; console log "[gettotalaudioinfo] index " + audioinformation[i] index ; console log "[gettotalaudioinfo] type " + audioinformation[i] type ; } getcurrentaudioinfo this interface provides methods to get the current audio information audioinfo getcurrentaudioinfo ; product b2b htv privilege level partner privilege http //developer samsung com/privilege/broadcast return value audioinfo current information of audio exceptions webapiexception with error type securityerror, if the application does not have the privilege to call this method with error type unknownerror in any other error case since 6 5 code example var audioinformation; audioinformation = webapis broadcast getcurrentaudioinfo ; console log "[getcurrentaudioinfo] language " + audioinformation language ; console log "[getcurrentaudioinfo] index " + audioinformation index ; console log "[getcurrentaudioinfo] type " + audioinformation type ; setcurrentaudio this interface provides methods to set the current audio information void setcurrentaudio long index, broadcastsuccesscallback onsuccess, optional broadcasterrorcallback? onerror ; product b2b htv constraint n/a privilege level partner privilege http //developer samsung com/privilege/broadcast parameters index current audio index, with a range from 0 to length-1 of gettotalaudioinfo onsuccess callback method to be invoked when this api is successful onerror [optional][nullable] callback method to be invoked when an error has occurred securityerror, if the application does not have the privilege to call this method exceptions webapiexception with the error type typemismatcherror if invalid values are passed for an input parameter code example var onsuccess = function val { console log "[setcurrentaudio] success " + val result ; }; var onerror = function error { console log "[setcurrentaudio] code " + error code + " error name " + error name + " message " + error message ; }; console log "[setcurrentaudio]" ; webapis broadcast setcurrentaudio 0, onsuccess, onerror ; gettotalsubtitleinfo this interface provides methods to get the total subtitle information subtitleinfo [] gettotalsubtitleinfo ; product b2b htv privilege level partner privilege http //developer samsung com/privilege/broadcast return value subtitleinfo [] multi information of subtitle exceptions webapiexception with error type securityerror, if the application does not have the privilege to call this method with error type unknownerror in any other error case since 6 5 code example var i, subtitleinformation; subtitleinformation = webapis broadcast gettotalsubtitleinfo ; for i =0; i < subtitleinformation length; i++ { console log "[gettotalsubtitleinfo] language " + subtitleinformation[i] language ; console log "[gettotalsubtitleinfo] index " + subtitleinformation[i] index ; console log "[gettotalsubtitleinfo] mode " + subtitleinformation[i] mode ; } getcurrentsubtitle this interface provides methods to get the current subtitle information subtitleinfo getcurrentsubtitle ; product b2b htv privilege level partner privilege http //developer samsung com/privilege/broadcast return value subtitleinfo current information of subtitle exceptions webapiexception with error type securityerror, if the application does not have the privilege to call this method with error type unknownerror in any other error case since 6 5 code example var subtitleinformation; subtitleinformation = webapis broadcast getcurrentsubtitle ; console log "[getcurrentsubtitle] language " + subtitleinformation language ; console log "[getcurrentsubtitle] index " + subtitleinformation index ; console log "[getcurrentsubtitle] mode " + subtitleinformation mode ; setcurrentsubtitleindex this interface provides methods to change the current displayed subtitle language with the index value of subtitle void setcurrentsubtitleindex long index, broadcastsuccesscallback onsuccess, optional broadcasterrorcallback? onerror ; product b2b htv privilege level partner privilege http //developer samsung com/privilege/broadcast parameters index long, index starts from 0 to length-1 of gettotalsubtitleinfo onsuccess callback method to be invoked when this api is successful onerror [optional][nullable] callback method to be invoked when an error has occurred securityerror, if the application does not have the privilege to call this method exceptions webapiexception with the error type typemismatcherror if invalid values are passed for an input parameter since 6 5 code example var onsuccess = function val { console log "[setcurrentsubtitleindex] success " + val result ; }; var onerror = function error { console log "[setcurrentsubtitleindex] code " + error code + " error name " + error name + " message " + error message ; }; console log "[setcurrentsubtitleindex]" ; webapis broadcast setcurrentsubtitleindex 0, onsuccess, onerror ; sethoteldrmforensicdata this interface provides methods to set the forensic data for security by watermark void sethoteldrmforensicdata domstring forensicdata, broadcastsuccesscallback onsuccess, optional broadcasterrorcallback? onerror ; product b2b htv privilege level partner privilege http //developer samsung com/privilege/broadcast parameters forensicdata string data of the forensic info onsuccess callback method to be invoked when this api is successful onerror [optional][nullable] callback method to be invoked when an error has occurred securityerror, if the application does not have the privilege to call this method exceptions webapiexception with the error type typemismatcherror if invalid values are passed for an input parameter since 6 5 code example var onsuccess = function val { console log "[sethoteldrmforensicdata] success " + val result ; }; var onerror = function error { console log "[sethoteldrmforensicdata] code " + error code + " error name " + error name + " message " + error message ; }; console log "[hoteldrmforensicdata]" ; webapis broadcast sethoteldrmforensicdata "abcdefghij", onsuccess, onerror ; tunedirect direct tuning an rf channel whether stored in the channel map or not void tunedirect directtuneoption tuneoption, broadcastsuccesscallback onsuccess, optional broadcasterrorcallback? onerror ; product b2b htv privilege level partner privilege http //developer samsung com/privilege/broadcast parameters tuneoption tuning option mandatory for all cases broadcaststandard, channeltype mandatory for atsc, isdb analog channel ptc or frequency mandatory for atsc, isdb digital channel ptc frequency + major + minor or ptc frequency + program mandatory for dvb analog channel frequency mandatory for dvb air digital channel frequency, programnumber, modulationtype, bandwidth mandatory for dvb cable digital channel frequency, programnumber, modulationtype, bandwidth, symbolrate mandatory for dvb satellite channel frequency, programnumber, satelliteid onsuccess callback method to be invoked when this api is successful onerror [optional][nullable] callback method to be invoked when an error has occurred securityerror, if the application does not have the privilege to call this method exceptions webapiexception with the error type typemismatcherror if invalid values are passed for an input parameter since 6 5 code example var onsuccess = function val { console log "[tunedirect] success " + val result ; }; var onerror = function error { console log "[tunedirect] code " + error code + " error name " + error name + " message " + error message ; }; console log "[tunedirect] example 1" ; var tuneoptionatsc = {}; tuneoptionatsc broadcaststandard = "atsc"; tuneoptionatsc channeltype = "cdtv"; tuneoptionatsc ptc = 18; tuneoptionatsc major = 28; tuneoptionatsc minor = 1; tuneoptionatsc modulationtype = "qam256"; webapis broadcast tunedirect tuneoptionatsc,onsuccess, onerror ; console log "[tunedirect] example 2" ; var tuneoptiondvbanalog = {}; tuneoptiondvbanalog broadcaststandard = "dvb"; tuneoptiondvbanalog channeltype = "atv"; tuneoptiondvbanalog frequency = 63752; tuneoptiondvbanalog modulationtype = "pal"; tuneoptiondvbanalog soundsystem = "auto"; tuneoptiondvbanalog colorsystem = "auto"; webapis broadcast tunedirect tuneoptiondvbanalog,onsuccess, onerror ; console log "[tunedirect] example 3" ; var tuneoptiondvbdigitalair = {}; tuneoptiondvbdigitalair broadcaststandard = "dvb"; tuneoptiondvbdigitalair channeltype = "dtv"; tuneoptiondvbdigitalair frequency = 474000; tuneoptiondvbdigitalair modulationtype = "8psk"; tuneoptiondvbdigitalair bandwidth = "8mhz"; tuneoptiondvbdigitalair major = 4; tuneoptiondvbdigitalair programnumber = 5; webapis broadcast tunedirect tuneoptiondvbdigitalair,onsuccess, onerror ; console log "[tunedirect] example 4" ; var tuneoptiondvbdigitalcable = {}; tuneoptiondvbdigitalcable broadcaststandard = "dvb"; tuneoptiondvbdigitalcable channeltype = "cdtv"; tuneoptiondvbdigitalcable frequency = 314000; tuneoptiondvbdigitalcable modulationtype = "qam256"; tuneoptiondvbdigitalcable bandwidth = "8mhz"; tuneoptiondvbdigitalcable symbolrate = 6900; tuneoptiondvbdigitalair programnumber = 2501; webapis broadcast tunedirect tuneoptiondvbdigitalcable,onsuccess, onerror ; console log "[tunedirect] example 5" ; var tuneoptiondvbsatellite = {}; tuneoptiondvbsatellite broadcaststandard = "dvb"; tuneoptiondvbsatellite channeltype = "sdtv"; tuneoptiondvbsatellite frequency = 10758000; tuneoptiondvbsatellite bandwidth = "8mhz"; tuneoptiondvbsatellite satelliteid = "astra_19_2e"; tuneoptiondvbsatellite programnumber = 7296; webapis broadcast tunedirect tuneoptiondvbsatellite,onsuccess, onerror ; console log "[tunedirect] example 6-1, ptc+program number case for atsc, ptc 18 = frequency 497mhz" ; var tuneoptionatscmulti1 = {}; tuneoptionatscmulti1 broadcaststandard = "atsc"; tuneoptionatscmulti1 channeltype = "dtv"; tuneoptionatscmulti1 ptc = 18; tuneoptionatscmulti1 programnumber = 2; tuneoptionatscmulti1 modulationtype = "vsb8"; webapis broadcast tunedirect tuneoptionatscmulti1,onsuccess, onerror ; console log "[tunedirect] example 6-2, ptc+major+minor case for atsc, ptc 18 = frequency 497mhz" ; var tuneoptionatscmulti2 = {}; tuneoptionatscmulti2 broadcaststandard = "atsc"; tuneoptionatscmulti2 channeltype = "dtv"; tuneoptionatscmulti2 frequency = 497000; tuneoptionatscmulti2 major = 28; tuneoptionatscmulti2 minor = 2; tuneoptionatscmulti2 modulationtype = "vsb8"; webapis broadcast tunedirect tuneoptionatscmulti2,onsuccess, onerror ; clearrating password initialization and setting off processing are performed in the rating menu setting of the hotel product void clearrating broadcastsuccesscallback onsuccess, optional broadcasterrorcallback? onerror ; product b2b htv privilege level partner privilege http //developer samsung com/privilege/broadcast parameters onsuccess callback method to be invoked when this api is successful onerror [optional][nullable] callback method to be invoked when an error has occurred securityerror, if the application does not have the privilege to call this method exceptions webapiexception with error type typemismatcherror, if any input parameter is not compatible with the expected type for that parameter since 6 5 code example var onsuccess = function val { console log "[clearrating] success " + val result ; }; var onerror = function error { console log "[clearrating] code " + error code + " error name " + error name + " message " + error message ; }; console log "[clearrating]" ; webapis broadcast clearrating onsuccess, onerror ; 2 6 broadcastsuccesscallback this callback interface defines the b2b set information success callback [callback = functiononly, nointerfaceobject] interface broadcastsuccesscallback { void onsuccess broadcastresult data ; }; methods onsuccess callback parameter void onsuccess broadcastresult data ; privilege level partner privilege http //developer samsung com/privilege/broadcast parameters data status of the operation since 6 5 code example var onsuccess = function val { console log "[setcurrentaudio] success " + val result ; }; var onerror = function error { console log "[setcurrentaudio] code " + error code + " error name " + error name + " message " + error message ; }; console log "[setcurrentaudio]" ; webapis broadcast setcurrentaudio 0, onsuccess, onerror ; 2 7 broadcasterrorcallback this callback interface defines the b2b set information error callback [callback = functiononly, nointerfaceobject] interface broadcasterrorcallback { void onerror broadcasterror data ; }; methods onerror this method is the callback parameter void onerror broadcasterror data ; privilege level partner privilege http //developer samsung com/privilege/broadcast parameters data provide status since 6 5 code example var onsuccess = function val { console log "[setcurrentaudio] success " + val result ; }; var onerror = function error { console log "[setcurrentaudio] code " + error code + " error name " + error name + " message " + error message ; }; console log "[setcurrentaudio]" ; webapis broadcast setcurrentaudio 0, onsuccess, onerror ; 3 full webidl module broadcast { enum eaudiotype { "invalid", "undefined", "clean_effect", "hearing_impaired", "visual_impaired" }; enum echanneltype { "atv", "dtv", "catv", "cdtv", "sdtv" }; enum ebroadcaststandard { "atsc", "dvb", "isdb" }; enum epolarisationtype { "unknown", "pol_hl", "pol_vr" }; enum ehotelprogramtype { "normal", "protected", "info", "radio", "delete" }; enum esubtitlemode { "normal", "hearing_impaired" }; enum ecolorsystem { "auto", "pal", "secam", "ntsc4_43", "ntsc3_58", "pal_m", "pal_n" }; enum esatelliteid { "astra_19_2e", "astra_23_5e", "astra_28_2e", "astra_31_5e", "astra_4_8e", "eutelsat_10e", "eutelsat_16e", "eutelsat_21_5e", "eutelsat_25_5e", "eutelsat_28_5e", "eutelsat_33e", "eutelsat_36e", "eutelsat_3e", "eutelsat_70_5e", "eutelsat_70e", "eutelsat_7e", "eutelsat_8_west_c", "eutelsat_9e", "eutelsat12_westa", "eutelsat5_westa", "eutelsat7_westa", "eutelsat8_westa", "eutelsatw1_10e", "eutelsatw2_16e", "eutelsatw3a_7e", "eutelsatw4_w7_36e", "eutelsatw5_70_5e", "eutelsatw6_21_5e", "abs_2_75e", "abs_7", "afghansat_1", "amazonas_61w", "amos_4w", "apstar", "arabsat_30_5e", "arabsat_5c_20e", "asiasat_5", "asiasat_7", "atlanticbird_5w", "atlanticbird1_12_5w", "atlanticbird2_8w", "azerspace_1_africasat_1a", "badr_26e", "bonum1_56e", "eurobird_25_5e", "eurobird_28_5e", "eurobird_33e", "eurobird_4e", "eurobird_9e", "express_am22", "express_am44", "express_am5_140e", "express_at1_56e", "expressa4_14w", "expressam1_40e", "hellas_39e", "hispasat_30w", "hotbird_13e", "insat_4b_93_3e", "intelsat_10", "intelsat_45e", "intelsat_902", "intelsat_904_60e", "intelsat15_85_2e", "intelsat1r_45w", "intelsat3r_43w", "intelsat7_10_68_5e", "intelsat705_50w", "intelsat707_53w", "intelsat801_31_5w", "intelsat805_55_5w", "intelsat9_58w", "intelsat901_18w", "intelsat903_34_5w", "intelsat905_24_5w", "intelsat907_27_5w", "measat_3b_91_5e", "nilesat_102_7w", "nilesat_201_7w", "nilesat_7w", "nss_6_ses_8_95e", "nss12_57e", "nss7_22w", "nss806_40_5w", "optus_d1_160e", "paksat_38e", "ses_5", "ses_7_108_2e", "sesat_53e", "st_2", "telstar_11n_37_5w", "telstar12_15w", "thaicom", "thor_intelsat_0_8w", "turksat_31_3e", "turksat_42e", "yahsat_1a", "yamal_202", "yamal201_90e", "user1", "user2", "user3", "user4" }; dictionary broadcastresult { domstring result; domstring data; }; dictionary broadcasterror { long code; domstring name; domstring message; }; [nointerfaceobject] interface broadcastmanagerobject { readonly attribute broadcastmanager broadcast; }; webapis implements broadcastmanagerobject; [nointerfaceobject] interface audioinfo { readonly attribute domstring language; readonly attribute long index; readonly attribute eaudiotype type; }; [nointerfaceobject] interface directtuneoption { readonly attribute ebroadcaststandard broadcaststandard; readonly attribute echanneltype channeltype; readonly attribute long major; readonly attribute long minor; readonly attribute long frequency; readonly attribute emodulationtype modulationtype; readonly attribute long ptc; readonly attribute long symbolrate; readonly attribute ebandwidth bandwidth; readonly attribute long programnumber; readonly attribute ecolorsystem? colorsystem; readonly attribute esatelliteid? satelliteid; readonly attribute epolarisationtype? polarization; readonly attribute domstring? channelname; readonly attribute ehotelprogramtype? hotelprogramtype; }; [nointerfaceobject] interface subtitleinfo { readonly attribute domstring language; readonly attribute long index; readonly attribute esubtitlemode mode; }; [nointerfaceobject] interface broadcastmanager { domstring getversion ; void enabledataservice broadcastsuccesscallback onsuccess, optional broadcasterrorcallback? onerror ; void disabledataservice broadcastsuccesscallback onsuccess, optional broadcasterrorcallback? onerror ; audioinfo [] gettotalaudioinfo ; audioinfo getcurrentaudioinfo ; void setcurrentaudio long index, broadcastsuccesscallback onsuccess, optional broadcasterrorcallback? onerror ; subtitleinfo [] gettotalsubtitleinfo ; subtitleinfo getcurrentsubtitle ; void setcurrentsubtitleindex long index, broadcastsuccesscallback onsuccess, optional broadcasterrorcallback? onerror ; void sethoteldrmforensicdata domstring forensicdata, broadcastsuccesscallback onsuccess, optional broadcasterrorcallback? onerror ; void tunedirect directtuneoption tuneoption, broadcastsuccesscallback onsuccess, optional broadcasterrorcallback? onerror ; void clearrating broadcastsuccesscallback onsuccess, optional broadcasterrorcallback? onerror ; }; [callback = functiononly, nointerfaceobject] interface broadcastsuccesscallback { void onsuccess broadcastresult data ; }; [callback = functiononly, nointerfaceobject] interface broadcasterrorcallback { void onerror broadcasterror data ; }; };
Develop Smart TV
apiconsole log "version value = " + value ; } catch error { console log "error code = " + error code ; } getdolbydigitalcompmode this method get dolby digital component mode avinfodigitalcompmode getdolbydigitalcompmode ; product tv, av, b2b return value avinfodigitalcompmode dolby digital component mode exceptions webapiexception with error type notsupportederror, this feature doesn't be supported since 2016 with error type unknownerror, if the information is not passed to avinfo successfully due to some unexpected internal error since 2 3 deprecated 4 0 code example try { var mode = webapis avinfo getdolbydigitalcompmode ; console log "mode = " + mode ; } catch error { console log "error code = " + error code ; } ishdrtvsupport this method is to check whether the hdr is supported or not boolean ishdrtvsupport ; product tv, av, b2b return value boolean return value of boolean true is support false is not support exceptions webapiexception with error type notsupportederror, if this api is called for non "samsung" products since 2 3 code example try { var nresult = webapis avinfo ishdrtvsupport ; console log "nresult = " + nresult ; } catch error { console log "error code = " + error code ; } setsubampmode this method sets the sub amp mode void setsubampmode avinfosubampmode mode ; product b2b htv parameters mode the sub amp mode that want to set up exceptions webapiexception with error type typemismatcherror, if any input parameter is not compatible with the expected type for that parameter with error type invalidvalueserror, if any of the input parameter contains an invalid value since plugin version 3 0 with error type notsupportederror, if this api is called in any product other than hotel tv since 6 0 code example try { webapis avinfo setsubampmode "ext_audio_tv" ; } catch error { console log "error code = " + error code ; } getenergysaving this method is to get energy saving values valid only for "samsung" product energysavingtype getenergysaving ; product tv, b2b return value energysavingtype return value of energy saving off, low, medium, high exceptions webapiexception with error type notsupportederror, if this api is called for non samsung products or called in an emulator and av with error type unknownerror, if the information is not passed to avinfo successfully due to some unexpected internal error since 6 5 code example try { var nresult = webapis avinfo getenergysaving ; console log "nresult = " + nresult ; } catch error { console log "error code = " + error code ; } setenergysaving this method is to set the energy saving values valid only for "samsung" product void setenergysaving energysavingtype value ; product tv, b2b parameters value energy saving value to set off, low, medium, high exceptions webapiexception with error type typemismatcherror, if any input parameter is not compatible with the expected type for that parameter with error type invalidvalueserror, if any of the input parameter contains an invalid value since plugin version 3 0 with error type notsupportederror, if this api is called for non samsung products or called in an emulator and av since 6 5 code example try { webapis avinfo setenergysaving "low" ; } catch error { console log "error code = " + error code ; } getecosensor this method is to get eco sensor values valid only for "samsung" product ecosensortype getecosensor ; product tv, b2b return value ecosensortype return value of eco sensor off, on exceptions webapiexception with error type notsupportederror, if this api is called for non samsung products or called in an emulator and av with error type unknownerror, if the information is not passed to avinfo successfully due to some unexpected internal error since 6 5 code example try { var nresult = webapis avinfo getecosensor ; console log "nresult = " + nresult ; } catch error { console log "error code = " + error code ; } setecosensor this method is to set the eco sensor values valid only for "samsung" product void setecosensor ecosensortype value ; product tv, b2b parameters value eco sensor value to set off, on exceptions webapiexception with error type typemismatcherror, if any input parameter is not compatible with the expected type for that parameter with error type invalidvalueserror, if any of the input parameter contains an invalid value since plugin version 3 0 with error type notsupportederror, if this api is called for non samsung products or called in an emulator and av since 6 5 code example try { webapis avinfo setecosensor "on" ; } catch error { console log "error code = " + error code ; } 2 3 avinfodigitalcompmode this interface defines the digital mode [nointerfaceobject] interface avinfodigitalcompmode { const unsigned long dolby_digital_comp_mode_line = 0; const unsigned long dolby_digital_comp_mode_rf = 1; }; constants dolby_digital_comp_mode_line line mode dolby_digital_comp_mode_rf rf mode 3 full webidl module avinfo { enum avinfosubampmode { "no_ext_audio", "ext_audio_tv", "ext_audio_switch", "ext_healthcare" }; enum energysavingtype { "off", "low", "medium", "high" }; enum ecosensortype { "off", "on" }; [nointerfaceobject] interface avinfomanagerobject { readonly attribute avinfomanager avinfo; }; webapi implements avinfomanagerobject; [nointerfaceobject] interface avinfomanager { readonly attribute avinfodigitalcompmode avinfodigitalcompmode; domstring getversion ; avinfodigitalcompmode getdolbydigitalcompmode ; boolean ishdrtvsupport ; void setsubampmode avinfosubampmode mode ; energysavingtype getenergysaving ; void setenergysaving energysavingtype value ; ecosensortype getecosensor ; void setecosensor ecosensortype value ; }; [nointerfaceobject] interface avinfodigitalcompmode { const unsigned long dolby_digital_comp_mode_line = 0; const unsigned long dolby_digital_comp_mode_rf = 1; }; };
Develop Smart Signage
apiconsole log "version value = " + value ; } catch error { console log "error code = " + error code ; } getdolbydigitalcompmode this method get dolby digital component mode avinfodigitalcompmode getdolbydigitalcompmode ; product tv, av, b2b return value avinfodigitalcompmode dolby digital component mode exceptions webapiexception with error type notsupportederror, this feature doesn't be supported since 2016 with error type unknownerror, if the information is not passed to avinfo successfully due to some unexpected internal error since 2 3 deprecated 4 0 code example try { var mode = webapis avinfo getdolbydigitalcompmode ; console log "mode = " + mode ; } catch error { console log "error code = " + error code ; } ishdrtvsupport this method is to check whether the hdr is supported or not boolean ishdrtvsupport ; product tv, av, b2b return value boolean return value of boolean true is support false is not support exceptions webapiexception with error type notsupportederror, if this api is called for non "samsung" products since 2 3 code example try { var nresult = webapis avinfo ishdrtvsupport ; console log "nresult = " + nresult ; } catch error { console log "error code = " + error code ; } setsubampmode this method sets the sub amp mode void setsubampmode avinfosubampmode mode ; product b2b htv parameters mode the sub amp mode that want to set up exceptions webapiexception with error type typemismatcherror, if any input parameter is not compatible with the expected type for that parameter with error type invalidvalueserror, if any of the input parameter contains an invalid value since plugin version 3 0 with error type notsupportederror, if this api is called in any product other than hotel tv since 6 0 code example try { webapis avinfo setsubampmode "ext_audio_tv" ; } catch error { console log "error code = " + error code ; } getenergysaving this method is to get energy saving values valid only for "samsung" product energysavingtype getenergysaving ; product tv, b2b return value energysavingtype return value of energy saving off, low, medium, high exceptions webapiexception with error type notsupportederror, if this api is called for non samsung products or called in an emulator and av with error type unknownerror, if the information is not passed to avinfo successfully due to some unexpected internal error since 6 5 code example try { var nresult = webapis avinfo getenergysaving ; console log "nresult = " + nresult ; } catch error { console log "error code = " + error code ; } setenergysaving this method is to set the energy saving values valid only for "samsung" product void setenergysaving energysavingtype value ; product tv, b2b parameters value energy saving value to set off, low, medium, high exceptions webapiexception with error type typemismatcherror, if any input parameter is not compatible with the expected type for that parameter with error type invalidvalueserror, if any of the input parameter contains an invalid value since plugin version 3 0 with error type notsupportederror, if this api is called for non samsung products or called in an emulator and av since 6 5 code example try { webapis avinfo setenergysaving "low" ; } catch error { console log "error code = " + error code ; } getecosensor this method is to get eco sensor values valid only for "samsung" product ecosensortype getecosensor ; product tv, b2b return value ecosensortype return value of eco sensor off, on exceptions webapiexception with error type notsupportederror, if this api is called for non samsung products or called in an emulator and av with error type unknownerror, if the information is not passed to avinfo successfully due to some unexpected internal error since 6 5 code example try { var nresult = webapis avinfo getecosensor ; console log "nresult = " + nresult ; } catch error { console log "error code = " + error code ; } setecosensor this method is to set the eco sensor values valid only for "samsung" product void setecosensor ecosensortype value ; product tv, b2b parameters value eco sensor value to set off, on exceptions webapiexception with error type typemismatcherror, if any input parameter is not compatible with the expected type for that parameter with error type invalidvalueserror, if any of the input parameter contains an invalid value since plugin version 3 0 with error type notsupportederror, if this api is called for non samsung products or called in an emulator and av since 6 5 code example try { webapis avinfo setecosensor "on" ; } catch error { console log "error code = " + error code ; } 2 3 avinfodigitalcompmode this interface defines the digital mode [nointerfaceobject] interface avinfodigitalcompmode { const unsigned long dolby_digital_comp_mode_line = 0; const unsigned long dolby_digital_comp_mode_rf = 1; }; constants dolby_digital_comp_mode_line line mode dolby_digital_comp_mode_rf rf mode 3 full webidl module avinfo { enum avinfosubampmode { "no_ext_audio", "ext_audio_tv", "ext_audio_switch", "ext_healthcare" }; enum energysavingtype { "off", "low", "medium", "high" }; enum ecosensortype { "off", "on" }; [nointerfaceobject] interface avinfomanagerobject { readonly attribute avinfomanager avinfo; }; webapi implements avinfomanagerobject; [nointerfaceobject] interface avinfomanager { readonly attribute avinfodigitalcompmode avinfodigitalcompmode; domstring getversion ; avinfodigitalcompmode getdolbydigitalcompmode ; boolean ishdrtvsupport ; void setsubampmode avinfosubampmode mode ; energysavingtype getenergysaving ; void setenergysaving energysavingtype value ; ecosensortype getecosensor ; void setecosensor ecosensortype value ; }; [nointerfaceobject] interface avinfodigitalcompmode { const unsigned long dolby_digital_comp_mode_line = 0; const unsigned long dolby_digital_comp_mode_rf = 1; }; };
Develop Smart Hospitality Display
apiconsole log "version value = " + value ; } catch error { console log "error code = " + error code ; } getdolbydigitalcompmode this method get dolby digital component mode avinfodigitalcompmode getdolbydigitalcompmode ; product tv, av, b2b return value avinfodigitalcompmode dolby digital component mode exceptions webapiexception with error type notsupportederror, this feature doesn't be supported since 2016 with error type unknownerror, if the information is not passed to avinfo successfully due to some unexpected internal error since 2 3 deprecated 4 0 code example try { var mode = webapis avinfo getdolbydigitalcompmode ; console log "mode = " + mode ; } catch error { console log "error code = " + error code ; } ishdrtvsupport this method is to check whether the hdr is supported or not boolean ishdrtvsupport ; product tv, av, b2b return value boolean return value of boolean true is support false is not support exceptions webapiexception with error type notsupportederror, if this api is called for non "samsung" products since 2 3 code example try { var nresult = webapis avinfo ishdrtvsupport ; console log "nresult = " + nresult ; } catch error { console log "error code = " + error code ; } setsubampmode this method sets the sub amp mode void setsubampmode avinfosubampmode mode ; product b2b htv parameters mode the sub amp mode that want to set up exceptions webapiexception with error type typemismatcherror, if any input parameter is not compatible with the expected type for that parameter with error type invalidvalueserror, if any of the input parameter contains an invalid value since plugin version 3 0 with error type notsupportederror, if this api is called in any product other than hotel tv since 6 0 code example try { webapis avinfo setsubampmode "ext_audio_tv" ; } catch error { console log "error code = " + error code ; } getenergysaving this method is to get energy saving values valid only for "samsung" product energysavingtype getenergysaving ; product tv, b2b return value energysavingtype return value of energy saving off, low, medium, high exceptions webapiexception with error type notsupportederror, if this api is called for non samsung products or called in an emulator and av with error type unknownerror, if the information is not passed to avinfo successfully due to some unexpected internal error since 6 5 code example try { var nresult = webapis avinfo getenergysaving ; console log "nresult = " + nresult ; } catch error { console log "error code = " + error code ; } setenergysaving this method is to set the energy saving values valid only for "samsung" product void setenergysaving energysavingtype value ; product tv, b2b parameters value energy saving value to set off, low, medium, high exceptions webapiexception with error type typemismatcherror, if any input parameter is not compatible with the expected type for that parameter with error type invalidvalueserror, if any of the input parameter contains an invalid value since plugin version 3 0 with error type notsupportederror, if this api is called for non samsung products or called in an emulator and av since 6 5 code example try { webapis avinfo setenergysaving "low" ; } catch error { console log "error code = " + error code ; } getecosensor this method is to get eco sensor values valid only for "samsung" product ecosensortype getecosensor ; product tv, b2b return value ecosensortype return value of eco sensor off, on exceptions webapiexception with error type notsupportederror, if this api is called for non samsung products or called in an emulator and av with error type unknownerror, if the information is not passed to avinfo successfully due to some unexpected internal error since 6 5 code example try { var nresult = webapis avinfo getecosensor ; console log "nresult = " + nresult ; } catch error { console log "error code = " + error code ; } setecosensor this method is to set the eco sensor values valid only for "samsung" product void setecosensor ecosensortype value ; product tv, b2b parameters value eco sensor value to set off, on exceptions webapiexception with error type typemismatcherror, if any input parameter is not compatible with the expected type for that parameter with error type invalidvalueserror, if any of the input parameter contains an invalid value since plugin version 3 0 with error type notsupportederror, if this api is called for non samsung products or called in an emulator and av since 6 5 code example try { webapis avinfo setecosensor "on" ; } catch error { console log "error code = " + error code ; } 2 3 avinfodigitalcompmode this interface defines the digital mode [nointerfaceobject] interface avinfodigitalcompmode { const unsigned long dolby_digital_comp_mode_line = 0; const unsigned long dolby_digital_comp_mode_rf = 1; }; constants dolby_digital_comp_mode_line line mode dolby_digital_comp_mode_rf rf mode 3 full webidl module avinfo { enum avinfosubampmode { "no_ext_audio", "ext_audio_tv", "ext_audio_switch", "ext_healthcare" }; enum energysavingtype { "off", "low", "medium", "high" }; enum ecosensortype { "off", "on" }; [nointerfaceobject] interface avinfomanagerobject { readonly attribute avinfomanager avinfo; }; webapi implements avinfomanagerobject; [nointerfaceobject] interface avinfomanager { readonly attribute avinfodigitalcompmode avinfodigitalcompmode; domstring getversion ; avinfodigitalcompmode getdolbydigitalcompmode ; boolean ishdrtvsupport ; void setsubampmode avinfosubampmode mode ; energysavingtype getenergysaving ; void setenergysaving energysavingtype value ; ecosensortype getecosensor ; void setecosensor ecosensortype value ; }; [nointerfaceobject] interface avinfodigitalcompmode { const unsigned long dolby_digital_comp_mode_line = 0; const unsigned long dolby_digital_comp_mode_rf = 1; }; };
Develop Smart Hospitality Display
apiconsole 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 set the device's ir lock status 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 ; iscustomappdownloaded check if customapp has been downloaded boolean iscustomappdownloaded ; product b2b htv privilege level partner privilege http //developer samsung com/privilege/systemcontrol return value boolean bool true or false if customapp has been downloaded 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 isdownloaded = false; try { isdownloaded = webapis systemcontrol iscustomappdownloaded ; } catch e { console log "iscustomappdownloaded exception [" + e code + "] name " + e name + " message " + e message ; } if isdownloaded { console log "customapp is downloaded" ; } setcustomappdownloadlistener registers an asynchronous customapp's ondownloaded callback void setcustomappdownloadlistener customappdownloadlistener ondownloaded ; product b2b htv privilege level partner privilege http //developer samsung com/privilege/systemcontrol parameters ondownloaded 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 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 unknownerror for any other error since 6 5 code example var ondownloaded = function data { console log wasappid + " is downloaded" ; } try { webapis systemcontrol setcustomappdownloadlistener ondownloaded ; } catch e { console log "setcustomappdownloadlistener exception [" + e code + "] name " + e name + " message " + e message ; } unsetcustomappdownloadlistener unregisters the asynchronous customapp's ondownloaded callback void unsetcustomappdownloadlistener ; product b2b 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 try { webapis systemcontrol unsetcustomappdownloadlistener ; } catch e { console log "unsetcustomappdownloadlistener exception [" + e code + "] name " + e name + " message " + e message ; } 2 6 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 7 customappdownloadlistener defines the customapp download listener [callback = functiononly, nointerfaceobject] interface customappdownloadlistener { void ondownloaded ; }; methods ondownloaded method that is invoked when the customapp download is done void ondownloaded ; privilege level partner privilege http //developer samsung com/privilege/systemcontrol since 6 5 code example var ondownloaded = function { console log "customapp is downloaded" ; }; try { webapis systemcontrol setcustomappdownloadlistener ondownloaded ; } catch e { console log "setcustomappdownloadlistener exception [" + e code + "] name " + e name + " message " + e message ; } 2 8 forwardmessagecallback this callback interface defines the forward message listener of the third party server [callback = functiononly, nointerfaceobject] interface forwardmessagecallback { void onchange forwardmessagedata data ; }; methods onchange method that is invoked when the forward message changes void onchange forwardmessagedata data ; privilege level partner privilege http //developer samsung com/privilege/systemcontrol parameters data object data of forward message from third party server 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 "[setforwardmessagelistener] message data " + data message + data timeout ; } try { webapis systemcontrol setforwardmessagelistener onchange ; } catch e { console log "setforwardmessagelistener exception [" + e code + "] name " + e name + " message " + e message ; } 2 9 privateappcompletelistener defines the delete private info complete listener [callback = functiononly, nointerfaceobject] interface privateappcompletelistener { void ondeleted domstring data ; }; methods ondeleted method that is invoked when the customapp download is done void ondeleted domstring data ; privilege level partner privilege http //developer samsung com/privilege/systemcontrol parameters data done meesage after check private info deletion since 9 0 code example var ondeleted = function data { //data == done console log "delete private app info complete"+ data ; }; try { webapis systemcontrol deleteappprivateinfonow ondeleted ; } catch e { console log "deleteappprivateinfonow exception [" + e code + "] name " + e name + " message " + e message ; } 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 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; [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 ; boolean iscustomappdownloaded ; void setcustomappdownloadlistener customappdownloadlistener ondownloaded ; void unsetcustomappdownloadlistener ; }; [callback = functiononly, nointerfaceobject] interface updatefirmwareprogresschangedcallback { void onchange long progress ; }; [callback = functiononly, nointerfaceobject] interface customappdownloadlistener { void ondownloaded ; }; [callback = functiononly, nointerfaceobject] interface forwardmessagecallback { void onchange forwardmessagedata data ; }; [callback = functiononly, nointerfaceobject] interface privateappcompletelistener { void ondeleted domstring data ; }; };
Develop Smart Signage
apiconsole 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 set the device's ir lock status 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 ; iscustomappdownloaded check if customapp has been downloaded boolean iscustomappdownloaded ; product b2b htv privilege level partner privilege http //developer samsung com/privilege/systemcontrol return value boolean bool true or false if customapp has been downloaded 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 isdownloaded = false; try { isdownloaded = webapis systemcontrol iscustomappdownloaded ; } catch e { console log "iscustomappdownloaded exception [" + e code + "] name " + e name + " message " + e message ; } if isdownloaded { console log "customapp is downloaded" ; } setcustomappdownloadlistener registers an asynchronous customapp's ondownloaded callback void setcustomappdownloadlistener customappdownloadlistener ondownloaded ; product b2b htv privilege level partner privilege http //developer samsung com/privilege/systemcontrol parameters ondownloaded 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 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 unknownerror for any other error since 6 5 code example var ondownloaded = function data { console log wasappid + " is downloaded" ; } try { webapis systemcontrol setcustomappdownloadlistener ondownloaded ; } catch e { console log "setcustomappdownloadlistener exception [" + e code + "] name " + e name + " message " + e message ; } unsetcustomappdownloadlistener unregisters the asynchronous customapp's ondownloaded callback void unsetcustomappdownloadlistener ; product b2b 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 try { webapis systemcontrol unsetcustomappdownloadlistener ; } catch e { console log "unsetcustomappdownloadlistener exception [" + e code + "] name " + e name + " message " + e message ; } 2 6 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 7 customappdownloadlistener defines the customapp download listener [callback = functiononly, nointerfaceobject] interface customappdownloadlistener { void ondownloaded ; }; methods ondownloaded method that is invoked when the customapp download is done void ondownloaded ; privilege level partner privilege http //developer samsung com/privilege/systemcontrol since 6 5 code example var ondownloaded = function { console log "customapp is downloaded" ; }; try { webapis systemcontrol setcustomappdownloadlistener ondownloaded ; } catch e { console log "setcustomappdownloadlistener exception [" + e code + "] name " + e name + " message " + e message ; } 2 8 forwardmessagecallback this callback interface defines the forward message listener of the third party server [callback = functiononly, nointerfaceobject] interface forwardmessagecallback { void onchange forwardmessagedata data ; }; methods onchange method that is invoked when the forward message changes void onchange forwardmessagedata data ; privilege level partner privilege http //developer samsung com/privilege/systemcontrol parameters data object data of forward message from third party server 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 "[setforwardmessagelistener] message data " + data message + data timeout ; } try { webapis systemcontrol setforwardmessagelistener onchange ; } catch e { console log "setforwardmessagelistener exception [" + e code + "] name " + e name + " message " + e message ; } 2 9 privateappcompletelistener defines the delete private info complete listener [callback = functiononly, nointerfaceobject] interface privateappcompletelistener { void ondeleted domstring data ; }; methods ondeleted method that is invoked when the customapp download is done void ondeleted domstring data ; privilege level partner privilege http //developer samsung com/privilege/systemcontrol parameters data done meesage after check private info deletion since 9 0 code example var ondeleted = function data { //data == done console log "delete private app info complete"+ data ; }; try { webapis systemcontrol deleteappprivateinfonow ondeleted ; } catch e { console log "deleteappprivateinfonow exception [" + e code + "] name " + e name + " message " + e message ; } 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 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; [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 ; boolean iscustomappdownloaded ; void setcustomappdownloadlistener customappdownloadlistener ondownloaded ; void unsetcustomappdownloadlistener ; }; [callback = functiononly, nointerfaceobject] interface updatefirmwareprogresschangedcallback { void onchange long progress ; }; [callback = functiononly, nointerfaceobject] interface customappdownloadlistener { void ondownloaded ; }; [callback = functiononly, nointerfaceobject] interface forwardmessagecallback { void onchange forwardmessagedata data ; }; [callback = functiononly, nointerfaceobject] interface privateappcompletelistener { void ondeleted domstring data ; }; };
Develop Smart Signage
docconsole" tab if the build console is not visible, open it by clicking the button as shown in the figure below and selecting either "cdt build console" or "cdt global build console " if there are errors or warnings during the build, they are visible in the build console and in the "problems" tab double-clicking on a compilation error or warning moves you to the source code where the error occurred when the build is finished, its artifacts can be found under the "currentbin" folder within the project's tree building for all available build configurations to build a webassembly module for all the available build configurations, right click the module project and select "build configurations > build all" the webassembly module is built with each of the available build configurations by default, there are two available "debug" and "release" build artifacts are to be found under folders named after the build configurations by default, "debug" and "release" the "currentbin" folder contains the build artifacts for the currently active build configuration the content is the same as in the respective "debug" or "release" folder cleaning with the active build configuration to clean a webassembly project for the active build configuration, right-click the module project and select "clean project" cleaning for all available build configurations to clean a webassembly project for all available build configurations, right-click the module project and select "build configurations > clean all"
Develop Smart TV
docconsole" tab if the build console is not visible, open it by clicking the button as shown in the figure below and selecting either "cdt build console" or "cdt global build console " if there are errors or warnings during the build, they are visible in the build console and in the "problems" tab double-clicking on a compilation error or warning moves you to the source code where the error occurred when the build is finished, its artifacts can be found under the "currentbin" folder within the project's tree building for all available build configurations to build a webassembly module for all the available build configurations, right click the module project and select "build configurations > build all" the webassembly module is built with each of the available build configurations by default, there are two available "debug" and "release" build artifacts are to be found under folders named after the build configurations by default, "debug" and "release" the "currentbin" folder contains the build artifacts for the currently active build configuration the content is the same as in the respective "debug" or "release" folder cleaning with the active build configuration to clean a webassembly project for the active build configuration, right-click the module project and select "clean project" cleaning for all available build configurations to clean a webassembly project for all available build configurations, right-click the module project and select "build configurations > clean all"
Develop Smart Hospitality Display
docconsole" tab if the build console is not visible, open it by clicking the button as shown in the figure below and selecting either "cdt build console" or "cdt global build console " if there are errors or warnings during the build, they are visible in the build console and in the "problems" tab double-clicking on a compilation error or warning moves you to the source code where the error occurred when the build is finished, its artifacts can be found under the "currentbin" folder within the project's tree building for all available build configurations to build a webassembly module for all the available build configurations, right click the module project and select "build configurations > build all" the webassembly module is built with each of the available build configurations by default, there are two available "debug" and "release" build artifacts are to be found under folders named after the build configurations by default, "debug" and "release" the "currentbin" folder contains the build artifacts for the currently active build configuration the content is the same as in the respective "debug" or "release" folder cleaning with the active build configuration to clean a webassembly project for the active build configuration, right-click the module project and select "clean project" cleaning for all available build configurations to clean a webassembly project for all available build configurations, right-click the module project and select "build configurations > clean all"
We use cookies to improve your experience on our website and to show you relevant advertising. Manage you settings for our cookies below.
These cookies are essential as they enable you to move around the website. This category cannot be disabled.
These cookies collect information about how you use our website. for example which pages you visit most often. All information these cookies collect is used to improve how the website works.
These cookies allow our website to remember choices you make (such as your user name, language or the region your are in) and tailor the website to provide enhanced features and content for you.
You have successfully updated your cookie preferences.