The Device Module controls device functions.
|device (Module) <META> Syntax|
<META HTTP-Equiv="Device" content="[method]">
|To set multiple EMML parameters / events on a single line use the following syntax: device.setEMML("[Your EMML Tags]"); e.g. device.setEMML("suspend");|
|Device Ruby Object Syntax:|
|To Invoke Device methods via Ruby use the following syntax: Device.method() e.g. Device.suspend|
Items listed in this section indicate methods or, in some cases, indicate parameters which will be retrieved.
|suspend||puts the device into suspend mode||Not in suspend mode|
|powerOff||puts the device into power off mode. In this mode the device will draw no power. Only supported on SB1.||Not in Power Off mode|
|wake||Wakes the device from suspend mode||wake mode|
|calibrate||Carries out the screen calibration routine||Not calibrating|
When multiple RhoElememts applications are running the following considerations should be made: Only the application with Focus will have the ability to control device functions.
The Suspend functionality is incompatible with the unattended functionality of the push module and they should not be used together.
The wake functionality can be used along with Push module. For eg: in the push detected event the user can call the wake method to wake the device. Please note that the Enterprise Tablet opens in Lock Screen mode if wake method is used and the screen stays active until the user swicthes it off and hence this method consumes more battery power.
|RhoElements Version||1.0.0 or above|
|Supported Devices||All supported devices except Enterprise Tablet. Only the method "wake" is supported on the Enterprise Tablet.|
|Persistence||Immediate - These methods are actioned immediately.|
The following example put the device into suspend mode:
<META HTTP-Equiv="Device" Content="Suspend">
The following example wakes the device from Suspend mode:
<META HTTP-Equiv="Device" Content="wake">