コード例 #1
0
        public IGPIOPin OpenPin(uint number, GPIOPinSharingMode shareMode)
        {
            bool success = InternalDevice.TryOpenPin((int)number, GpioSharingMode.Exclusive, out GpioPin pin, out GpioOpenStatus status);

            if (success)
            {
                return(new GPIOPin(pin, this));
            }
            else
            {
                return(null);
            }
        }
コード例 #2
0
 private void InternalDevice_ReportUpdated(Windows.Devices.Power.Battery sender, object args)
 {
     _Report = InternalDevice.GetReport();
 }