iot: Release 1.1 does not support InputPullUp/InputPullDown mode for RaspberryPi2B
I don’t know if this is really bug but with release 1.1 I’am no longer able to set pin driver mode to InputPullUp value on my Pi Model 2B v1.1 rev. a01041.
Steps to reproduce
GpioController controller = new GpioController();
controller.OpenPin(17, PinMode.InputPullUp);
Expected behavior
When I run this code in release 1.0 everything works fine.
Actual behavior
When I run this code in release 1.1 I get exception “Pin 17 does not support mode InputPullUp”.
I debugged the source code of 1.1 and my RPi2 gets LibGpioDriver. When setting DriveMode.InputPullUp there is a condition for gpiod v1.5. But RPi2 has up-to-date version only 1.2 so I get mentioned exception. Will there be RPi2 PullUp/PullDown support added in future or do I have to switch to newer RPi? Or should I stick with release 1.0 for my antique board?
Thanks guys. Keep up good job.
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Reactions: 1
- Comments: 20 (14 by maintainers)
And this bug has already been addresses but right after the 1.1 realease. See here: https://github.com/dotnet/iot/blob/c8130309c99a35ce68a10c40ca9003b0261cc2ef/src/System.Device.Gpio/System/Device/Gpio/RaspberryBoardInfo.cs#L182 And here: https://github.com/dotnet/iot/blob/17d497e71147431e12784fcd15e6aaea37a409a3/src/System.Device.Gpio/System/Device/Gpio/RaspberryBoardInfo.cs#L181
On my RPI4 model B rev 1.2, same issue with
GpioController controller = new GpioController();Got exception:with GpioController controller = new GpioController(PinNumberingScheme.Logical, new RaspberryPi3Driver());`` Got different exception:
Now the info: