public void Dispose() { _gpioController?.Dispose(); _gpioController = null; _spiDevice?.Dispose(); _spiDevice = null; }
public void Dispose() { if (_controller != null) { _controller.Dispose(); _controller = null; } }
/// <summary> /// Releases the resources used by the <see cref="DCMotor"/> instance. /// </summary> /// <param name="disposing">true to release both managed and unmanaged resources; false to release only unmanaged resources.</param> protected virtual void Dispose(bool disposing) { if (disposing) { Controller?.Dispose(); Controller = null; } }
public virtual void Dispose() { _masterGpioController?.Dispose(); _masterGpioController = null; _bus?.Dispose(); }
public void Dispose() { _gpio.Dispose(); }
public void Dispose() { Stop(); _controller?.Dispose(); _controller = null; }
protected override void Dispose(bool disposing) { _controller?.Dispose(); base.Dispose(disposing); }