protected void startUp() { plugin_interface = PluginInitializer.getDefaultInterface(); if (COConfigurationManager.getStringParameter("ui").equals("az2")) { is_enabled = false; } else { is_enabled = COConfigurationManager.getBooleanParameter("devices.tivo.enabled", true); } uid = COConfigurationManager.getStringParameter("devices.tivo.uid", null); if (uid == null) { byte[] bytes = new byte[8]; RandomUtils.nextBytes(bytes); uid = Base32.encode(bytes); COConfigurationManager.setParameter("devices.tivo.uid", uid); } boolean found_tivo = false; for (Device device : device_manager.getDevices()) { if (device instanceof DeviceTivo) { found_tivo = true; break; } } if (found_tivo || device_manager.getAutoSearch()) { search(found_tivo, false); } }