AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |
Back to Blog
Some GPIO pins can perform multiple functions. When a pin is closed, it reverts to its power-on state. To disconnect the pull resistors and get a high-impedance input, set the drive mode to GpioPinDriveMode.Input: pin.SetDriveMode(GpioPinDriveMode.Input) When you open a pin, it will be in its power-on state, which may include a pull resistor. } // Close pin - will revert to its power-on state Pin.SetDriveMode(GpioPinDriveMode.Output) This ensures a default value when the pin is set as output Return // GPIO not available on this system GpioController gpio = GpioController.GetDefault() Get the default GPIO controller on the system GPIO SampleĪs an example, the following code opens GPIO 5 as an output and writes a digital ' 1' out on the pin: using GPIO 35 & 47 are not available on Raspberry Pi 3. The following GPIO pins are accessible through APIs: GPIO# Let's look at the GPIO available on this device. 1x - Serial UARTs (RPi3 only includes mini UART).Hardware interfaces for the Raspberry Pi 2 and Raspberry Pi 3 are exposed through the 40-pin header J8 on the board.
0 Comments
Read More
Leave a Reply. |