Class Signage#setFailoverMode

Signage

Class Summary
Constructor Attributes Constructor Name and Description
 
Signage#setFailoverMode(successCallback, errorCallback, options)

Sets Failover mode.

Class Detail

Signage#setFailoverMode(successCallback, errorCallback, options)

Sets Failover mode. When Failover Mode is set, monitor will automatically switch to the input source when the input signal fails, according to the predefined priorities set in the menu.

IMPORTANT NOTE!!!!

When failover is triggered due to lost signal, the signage application will yield to the next priority input source set in the failover mode and run in the background.

If the signage application should always be running in the foreground, failover mode should be set to OFF.


function setFailoverMode() {

   //Available input types and number of input ports for each input types may differ model by model. 
   var options = { 
     failoverMode : {
        mode: Signage.FailoverMode.MANUAL,
        priority : [
           'ext://hdmi:1',
           'ext://hdmi:2',
           'ext://dvi:1',
           'ext://internal_memory',
           'ext://dp:1'
        ]
     }
   }; 
    
   var successCb = function (){
     console.log('Successfully set Failover Mode');
   }; 
        
   var failureCb = function(cbObject){ 
     var errorCode = cbObject.errorCode; 
     var errorText = cbObject.errorText; 
     console.log( " Error Code [" + errorCode + "]: " + errorText); 
   }; 

   var signage = new Signage();
   signage.setFailoverMode(successCallback, errorCallback, options);
}
Parameters:
{Function} successCallback
success callback function.
{Function} errorCallback
failure callback function.
{Object} options
Input Parameters
{Object} options.failoverMode
Failover mode. Only attributes that exist will be set.
PropertyTypeDescriptionRequired
modeSignage.FailoverModeFailover moderequired
priorityArrayInput priority that will be used when mode is MANUAL.
This parameter should be present only when mode is set to MANUAL(error is returned otherwise).
optional
Input source can be one of the following. Some of the input type may not be supported for a specific model.
NameDescription
ext://hdmi:[index]HDMI Input
ext://dvi:[index]DVI Input
ext://rgb:[index]RGB input
ext://dp:[index]Display port Input
ext://ops:[index]OPS input
ext://internal_memoryInternal Storage
ext://usb:[index]External USB storage at usb port [index]
ext://sdCard:[index]External sd card Storage at sd card port [index]
Since:
1.0
Returns:

After the method is successfully executed, successCallback is called without any parameter.

If an error occurs, errorCallback is called with errorCode and errorText.