-
Notifications
You must be signed in to change notification settings - Fork 139
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
Always getting an exception GpioConnection: Object reference not set to an instance of an object #86
Comments
i have a similar problem:
Its since the upgrade from kernel ARCH Linux 4.4 to 4.9 |
So do I It seems that "Driver" is null GeneralPurpose > GpioConnection.cs line 488 : |
OK, il think the problem is from Raspberry.System API, it doesn't reconize the CPU of this version of PI. If I do this : See this request : |
Right, it works for me. Next : In Raspberry.IO.GeneralPurpose, edit the function :
IT is magic ! |
Hi, can anyone please repeat the steps (as simple as possible ^^) to solve this problem? There is a dead link. I found the function above but there are so many build errors... Is there a simpler solution, or can I maybe update to a fixed version with nuget? |
Link not dead anymore |
Thanks, maybe fix the other link too, I still cant reach it. |
A note for others who find this page: it's recommended to use the revision number now, for identifying the processor. See raspberrypi/linux#2008 and raspberrypi/firmware#705 Also, I wonder if even older Pi's report Bcm2835 as the Hardware value in However, if you know you're only running on a RPi 3, then @Bulinlinbu's change looks safe enough. Finally, test on my RPi3 indicates that this quick and dirty workaround also works, if you know you are running on a RPi 3:
I wouldn't advocate using that for any long-term purpose, but as a quick workaround until R#.IO, for users who know they are on RPi3, it seems to work. It amounts to forcing in the value that the library expects to see on an RPi 2 - which results in the correct GPIO memory addresses being selected because the addresses are the same on the Pi 3. |
install Raspberry.IO.GeneralPurpose3 -Version 3.1.1 instead of Raspberry.IO.GeneralPurpose as nuget package. Hope ur problem will be solved. |
Raspberry.IO.GeneralPurpose3 has been disocontinued. |
Please make sure you have enabled all Interfaces in Rasperry Pi Configuration. |
Hey.
I have a Raspberry Pi 3 B. I did some GPIO development using Python, but I would love to use C#.
I set up a small project (Raspberry.IO references are OK):
I keep getting the following error no matter if I compile on Visual Studio (on Windows) or MonoDevelop (on Raspberry Pi):
Thank you for any help.
Kind regards.
Kris.
The text was updated successfully, but these errors were encountered: