I have some problems with the debugger while using some code I’ve written for the Cerberus. The code is ‘pure NETMF’ 4.2 (not Gadgeteer project). I am running Windows 7. The (very repeatable) errors are:
Set a debug breakpoint somewhere in the code. Run the code in Visual Studio C# Express 2010 debugging mode. This causes the code to stop at the desired breakpoint.
Go to the next line in the code using the debugger. The debugger does not go to the next line. The arrow marker disappears and the code is not executed (I tested with some debug print statements). I have to click the ‘stop’ button in the debugger to exit the debugging session. Edit: Note that the code was deployed. I am able to use the code as expected if I do not set the breakpoint. The problem here is that I can not use the debugger.
Debug (and flash) board again using VS. One of two things happens. Either:
The code gets into the “The debugging target is not in an initialized state; rebooting…” mode and stays there for ~20-30 seconds. After that time it aborts and I get the following messages in the output window:
[quote]The debugging target and the debugger engine failed to initialize because of unspecified device errors.
The debugger engine thread has terminated unexpectedly with error ‘Could not reconnect to the debugging target after rebooting it.’.[/quote]
The debugger does not get that far and I get the following two popup windows messages with no error text in the output window:
[quote]TinyCLR Error: An exception occurred while attempting to launch the debugger: Object reference not set to an instance of an object.
Microsoft Visual C# 2010 Express: The operation could not be completed. Unspecified error[/quote]
I can ‘reset’ my device by flashing a fresh project to it. I can use the debugger with these fresh projects. I also tested my board with a (very) old version of my code/solution and it worked as expected as well.
I do not know what caused this issue. Today was the first time that I have seen it. I have not changed the Cerberus code in some time (repo shows January 7th), but I have been changing client-side code that interacts with the Cerberus. I am at a loss as to where to look to start solving this problem. I ran ‘Clean Solution’ and ‘Rebuild Solution’ hoping that it would help, but I see the same results. I feel that it is not NETMF/Drivers/Etc. related because I am able to deploy other projects and use the debugger as expected, but maybe I’m off-base on that one. I would guess that I somehow messed up a reference to some DLL or project while messing with my ‘client-side’ code.
Any help would be appreciated! If you need me, I’ll be over here flailing and banging my head against a wall.