Inheritance: SocketInterfaces.AnalogIO
Beispiel #1
0
        public async Task <AnalogIO> CreateAnalogIOAsync(SocketPinNumber pinNumber)
        {
            this.EnsureTypeIsSupported(SocketType.A);

            AnalogIO result;

            if (this.AnalogIOCreator != null)
            {
                result = await this.AnalogIOCreator(this, pinNumber);
            }
            else
            {
                result = new NativeInterfaces.AnalogIO();
            }

            result.DriveMode = WD.Gpio.GpioPinDriveMode.Input;

            return(result);
        }
Beispiel #2
0
		public async Task<AnalogIO> CreateAnalogIOAsync(SocketPinNumber pinNumber) {
			this.EnsureTypeIsSupported(SocketType.A);

			AnalogIO result;

			if (this.AnalogIOCreator != null) {
				result = await this.AnalogIOCreator(this, pinNumber);
			}
			else {
				result = new NativeInterfaces.AnalogIO();
			}

			result.DriveMode = WD.Gpio.GpioPinDriveMode.Input;

			return result;
		}