private void NotifyReceived(object sender, ButtplugDeviceDataEventArgs args) { var data = Encoding.ASCII.GetString(args.Bytes); //BpLogger.Trace(data); _lastNotifyReceived = data; }
private void NotifyReceived(object sender, ButtplugDeviceDataEventArgs args) { // Only set the waiter if it's not been set yet. Currently we only // use this when initializing, but in the future this may need // resetting if we need 2 way communication with the device. if (!_notificationWaiter.Task.IsCompleted) { _notificationWaiter.TrySetResult(Encoding.ASCII.GetString(args.Bytes)); } }
private void OnDataReceived(object sender, ButtplugDeviceDataEventArgs aArgs) { // no-op, but required for the Onyx to work }