public BlinkNoteBase() { if (_con == null) { _con = new BlynclightController(); _con.InitBlyncDevices(); } }
private static void SetCallStatus(BlynclightController controller, FlashSpeed flashSpeed) { for (var i = 0; i < controller.aoDevInfo.Length; i++) { controller.TurnOnRedLight(i); controller.ClearLightDim(i); SetFlashspeed(controller, i, flashSpeed); } }
public BlyncPresentationProvider( BlynclightController blynclightController, int selectedBlyncDevice = 0, int numberOfExecutions = 0) { this.blynclightController = blynclightController; this.selectedBlyncDevice = selectedBlyncDevice; this.numberOfExecutions = numberOfExecutions; this.blynclightController.InitBlyncDevices(); }
private static void SetFlashspeed(BlynclightController controller, int deviceIndex, FlashSpeed flashSpeed) { if (flashSpeed == FlashSpeed.None) { controller.StopLightFlash(deviceIndex); } else { controller.SelectLightFlashSpeed(deviceIndex, (byte)(flashSpeed + 1)); controller.StartLightFlash(deviceIndex); } }
public BlyncController() : this(0) { _blynclightController = new BlynclightController(); _blynclightController.InitBlyncDevices(); }
public BlyncWrapper(BlynclightController injected_controller) { this.controller = injected_controller; }
public BlyncWrapper() { this.controller = ActualControllerFactory.Create(); }
private void ConnectLightClick(object sender, RoutedEventArgs e) { const byte DEVICETYPE_NODEVICE_INVALIDDEVICE_TYPE = 0x00; const byte DEVICETYPE_BLYNC_CHIPSET_TENX_10 = 0x01; const byte DEVICETYPE_BLYNC_CHIPSET_TENX_20 = 0x02; const byte DEVICETYPE_BLYNC_CHIPSET_V30 = 0x03; const byte DEVICETYPE_BLYNC_CHIPSET_V30S = 0x04; const byte DEVICETYPE_BLYNC_HEADSET_CHIPSET_V30_LUMENA110 = 0x05; const byte DEVICETYPE_BLYNC_WIRELESS_CHIPSET_V30S = 0x06; const byte DEVICETYPE_BLYNC_MINI_CHIPSET_V30S = 0x07; const byte DEVICETYPE_BLYNC_HEADSET_CHIPSET_V30_LUMENA120 = 0x08; const byte DEVICETYPE_BLYNC_HEADSET_CHIPSET_V30_LUMENA = 0x09; const byte DEVICETYPE_BLYNC_HEADSET_CHIPSET_V30_LUMENA210 = 0x0A; const byte DEVICETYPE_BLYNC_HEADSET_CHIPSET_V30_LUMENA220 = 0x0B; const byte DEVICETYPE_BLYNC_EMBRAVA_EMBEDDED_V30 = 0x0C; const byte DEVICETYPE_BLYNC_MINI_CHIPSET_V40S = 13; const byte DEVICETYPE_BLYNC_WIRELESS_CHIPSET_V40S = 14; const byte DEVICETYPE_BLYNC_CHIPSET_V40 = 15; const byte DEVICETYPE_BLYNC_CHIPSET_V40S = 16; const byte DEVICETYPE_BLYNC_NAMEDISPLAY_DEVICE = 17; const byte DEVICETYPE_BLYNC_PLANTRONICS_STATUS_INDICATOR = 21; const byte DEVICETYPE_BLYNC_MINI_CHIPSET_V40S_VERSION20 = 22; // version 2.0 - BrightTrend devices const byte DEVICETYPE_BLYNC_CHIPSET_V40_VERSION20 = 23; const byte DEVICETYPE_BLYNC_CHIPSET_V40S_VERSION20 = 24; const byte DEVICEFLASHSPEED_SLOW = 0x01; const byte DEVICEFLASHSPEED_MEDIUM = 0x02; const byte DEVICEFLASHSPEED_FAST = 0x03; BlynclightController oBlynclightController = new BlynclightController(); this.EmbravaDeviceList.Items.Clear(); var nNumberOfBlyncDevices = oBlynclightController.InitBlyncDevices(); for (int i = 0; i < nNumberOfBlyncDevices; i++) { EmbravaDeviceList.Items.Insert(i, oBlynclightController.aoDevInfo[i].szDeviceName); if (oBlynclightController.aoDevInfo[i].byDeviceType == DEVICETYPE_BLYNC_CHIPSET_TENX_10 || oBlynclightController.aoDevInfo[i].byDeviceType == DEVICETYPE_BLYNC_CHIPSET_TENX_20) { //comboBoxDeviceList.Items.Insert(nCbIndex, oBlynclightController.aoDevInfo[i].szDeviceName); //nCbIndex++; //EnableUIComponentsForBlyncUsb1020Devices(); //DisableUIComponentsForBlyncUsb30Devices(); } else if (oBlynclightController.aoDevInfo[i].byDeviceType == DEVICETYPE_BLYNC_CHIPSET_V30S || oBlynclightController.aoDevInfo[i].byDeviceType == DEVICETYPE_BLYNC_CHIPSET_V40S || oBlynclightController.aoDevInfo[i].byDeviceType == DEVICETYPE_BLYNC_CHIPSET_V40S_VERSION20 || oBlynclightController.aoDevInfo[i].byDeviceType == DEVICETYPE_BLYNC_PLANTRONICS_STATUS_INDICATOR || oBlynclightController.aoDevInfo[i].byDeviceType == DEVICETYPE_BLYNC_NAMEDISPLAY_DEVICE || oBlynclightController.aoDevInfo[i].byDeviceType == DEVICETYPE_BLYNC_CHIPSET_V30 || oBlynclightController.aoDevInfo[i].byDeviceType == DEVICETYPE_BLYNC_CHIPSET_V40 || oBlynclightController.aoDevInfo[i].byDeviceType == DEVICETYPE_BLYNC_CHIPSET_V40_VERSION20 || oBlynclightController.aoDevInfo[i].byDeviceType == DEVICETYPE_BLYNC_HEADSET_CHIPSET_V30_LUMENA110 || oBlynclightController.aoDevInfo[i].byDeviceType == DEVICETYPE_BLYNC_HEADSET_CHIPSET_V30_LUMENA120 || oBlynclightController.aoDevInfo[i].byDeviceType == DEVICETYPE_BLYNC_HEADSET_CHIPSET_V30_LUMENA || oBlynclightController.aoDevInfo[i].byDeviceType == DEVICETYPE_BLYNC_WIRELESS_CHIPSET_V30S || oBlynclightController.aoDevInfo[i].byDeviceType == DEVICETYPE_BLYNC_WIRELESS_CHIPSET_V40S || oBlynclightController.aoDevInfo[i].byDeviceType == DEVICETYPE_BLYNC_EMBRAVA_EMBEDDED_V30 || oBlynclightController.aoDevInfo[i].byDeviceType == DEVICETYPE_BLYNC_MINI_CHIPSET_V30S || oBlynclightController.aoDevInfo[i].byDeviceType == DEVICETYPE_BLYNC_MINI_CHIPSET_V40S || oBlynclightController.aoDevInfo[i].byDeviceType == DEVICETYPE_BLYNC_MINI_CHIPSET_V40S_VERSION20 || oBlynclightController.aoDevInfo[i].byDeviceType == DEVICETYPE_BLYNC_HEADSET_CHIPSET_V30_LUMENA210 || oBlynclightController.aoDevInfo[i].byDeviceType == DEVICETYPE_BLYNC_HEADSET_CHIPSET_V30_LUMENA220) { nSelectedDeviceIndex = 0; EmbravaDeviceList.SelectedIndex = 0; bool bResult = false; bResult = oBlynclightController.TurnOnBlueLight(nSelectedDeviceIndex); bResult = oBlynclightController.StartLightFlash(nSelectedDeviceIndex); bResult = oBlynclightController.SelectLightFlashSpeed(nSelectedDeviceIndex, DEVICEFLASHSPEED_SLOW); //EnableUIComponentsForBlyncUsb30Devices(); } /*else if (oBlynclightController.aoDevInfo[i].byDeviceType == DEVICETYPE_BLYNC_HEADSET_CHIPSET_V30_LUMENA210_NOTIFICATIONINTERFACE || * oBlynclightController.aoDevInfo[i].byDeviceType == DEVICETYPE_BLYNC_HEADSET_CHIPSET_V30_LUMENA220_NOTIFICATIONINTERFACE) * { * DisableUIComponentsForBlyncUsb1020Devices(); * DisableUIComponentsForBlyncUsb30Devices(); * }*/ } }
public BlyncClient() { _blynclightController = new BlynclightController(); NumberOfDevices = _blynclightController.InitBlyncDevices(); _deviceTypes = IdentifyDeviceTypes(); }