Пример #1
0
        protected virtual void Dispose(bool disposing)
        {
            _rawDevice?.Close();
            _rawDevice?.Dispose();
            _rawDevice = null;

            if (disposing)
            {
                _peripheralManagerService?.Dispose();
                _peripheralManagerService = null;
            }
        }
 public void Close()
 {
     if (_device != null)
     {
         try
         {
             _device.Close();
         }
         finally
         {
             _device = null;
         }
     }
 }
Пример #3
0
 public void DataUpdateStop()
 {
     myTimer.Dispose();
     i2cDevice.Close();
 }