public void Dispose() { for (int i = 0; i < _pins.Length; ++i) { Pin pin = _pins[i]; if (pin != null) { pin.Dispose(); _pins[i] = null; } } Driver.Dispose(); }
public void Dispose() { Pin?.Dispose(); Pin = null; PinEventsToDetect = PinEvent.Any; }