enableScanner static method

void enableScanner(
  1. bool enable
)

Implementation

static void enableScanner(bool enable){
  /**
    DISABLE_PLUGIN: disables the plug-in; scanner becomes inactive.
                    SCANNER_STATUS notification broadcasts DISABLED state.

    ENABLE_PLUGIN: enables the plug-in; scanner becomes active. SCANNER_STATUS
                   notification broadcasts WAITING and SCANNING states,
                   rotating between each depending on whether scanning is
                   taking place.
  */
  String command = enable ? 'ENABLE_PLUGIN' : 'DISABLE_PLUGIN';
  _sendDataWedgeCommand(_scannerPlugin, command);
}