adafruit / adafruit/AdafruitClassLibrary
null value on ScopePin
- Dominant language
- C#
- Stars
- 24
- Forks
- 10
- PR merge metrics
- No merged PRs in 30d
Description
Once the code moves to the Show() method, it never gets past the "ScopePin.Write(GpioPinValue.High)" line in the TriggerScopePin(bool triggerOn) method. When I step through the code the error message that comes up is "System.AccessViolationException: 'Attempted to read or write protected memory. This is often an indication that other memory is corrupt.' "
When I just run the code I get the error: "System.NullReferenceException: 'Object reference not set to an instance of an object.' "
I noticed the code never actually reaches the ScopeTriggerInit(6) so I tried forcing it to reach it, and when it was successful the code would then get stuck on the line: ScopePin = gpio.OpenPin(scopePin) in the ScopeTriggerInit(int scopePin) method with the error code: System.IO.FileLoadException: 'The process cannot access the file because it is being used by another process.
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by inspecting TriggerScopePin(bool triggerOn), ScopeTriggerInit(int scopePin), and the ScopePin.Write and gpio.OpenPin calls described in the report. Reproduce the failure on the Windows IoT Core Raspberry Pi setup and determine why initialization is skipped or the pin is already in use. Done means the scope pin initializes and triggers without the reported access, null-reference, or file-load errors.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp, raspberry-pi
- Domain
- embedded-iot
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100