-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
pinMode PWM: Unable to do this when using /dev/gpiomem. Try sudo? #211
Comments
What Wiring Pi Version do you use? Comment in Source: Looks like it's not possible without root access. If I find the time I can test if it's really crashing (need to bypass the check). |
I am using version 3.0 |
i have also changed the rights of /dev/mem still no fix |
If it is not doable it is fine I have found a solution to go sudo with ros2. I saw this question pop up on other forums so I think it would be a good idea if it is not doable to just put it down. I would investigate myself but I don't really have the know how yet. |
Thanks for the issue. Analysis so far: If this is not possible WiringPi use /dev/gpiomem (kernel module). However, the addresses for PWM are not available on that memory (only GPIO)! That's why PWM doesn't work. Actions: Solution: Please keep me updated if you were able to solve the problem. |
report for analysis finished #221 |
I have been scouring the web for a few hours now and I cannot seem to fix the problem. I am using rpi 4b 8GB ram with ubuntu 22.04 server
pinMode PWM: Unable to do this when using /dev/gpiomem. Try sudo?
I am running my executable through ROS2 and hence cannot give it root privileges. I have already tried
sudo adduser pi gpio
,sudo usermod -a -G gpio $USER
,sudo chown root.gpio /dev/gpiomem
andsudo chmod g+rw /dev/gpiomem
and none will do. Thanking you for your answer if there is one.The text was updated successfully, but these errors were encountered: