No way to use pin for pwm after calling SetPinMode. #1470
Labels
area-System.Device.Gpio
Contains types for using general-purpose I/O (GPIO) pins
bug
Something isn't working
duplicate
This issue or pull request already exists
Describe the bug
On Raspberry Pi 4
If GpioController.SetPinMode or OpenPin are used to set PinMode.Output at anytime system must be rebooted before PwmChannel can be used.
Steps to reproduce
Add 'dtoverlay=pwm,pin=18,func=2' line to /boot/config.txt and reboot
exec this code:
...
var pwm=PwmChannel.Create(0,0,500,1);
pwm.start();
...
exec this code:
...
controller.OpenPin(18,PinMode.Output);
...
then repeat:
...
var pwm=PwmChannel.Create(0,0,500,1);
pwm.start();
...
Expected behavior
Describe what did you expect to happen
Actual behavior
Describe what actually happened
Versions used
Add following information:
.NET SDK (reflecting any global.json):
Version: 5.0.100
Commit: 5044b93829
Runtime Environment:
OS Name: raspbian
OS Version: 10
OS Platform: Linux
RID: linux-arm
Base Path: /home/pi/dotnet/sdk/5.0.100/
Host (useful for support):
Version: 5.0.0
Commit: cf258a14b7
.NET SDKs installed:
5.0.100 [/home/pi/dotnet/sdk]
.NET runtimes installed:
Microsoft.AspNetCore.App 5.0.0 [/home/pi/dotnet/shared/Microsoft.AspNetCore.App]
Microsoft.NETCore.App 5.0.0 [/home/pi/dotnet/shared/Microsoft.NETCore.App]
The text was updated successfully, but these errors were encountered: