A first chance exception of type 'System.NotImplementedException' occurred in Microsoft.SPOT.Native.dll

Hello All,

Some time ago i made board from book “Beginners Guide to Porting NETMF” ( http://www.ghielectronics.com/downloads/FEZ/Beginners%20Guide%20to%20Porting%20NETMF.pdf ) uploaded NETMF successfully. Now i’ve returned to this board to make some project and when i upload simple blinking led project i’ve got following exception:


The debugging target runtime is loading the application assemblies and starting execution.
'Microsoft.SPOT.Debugger.CorDebug.dll' (Managed): Loaded 'C:\Program Files (x86)\Microsoft .NET Micro Framework\v4.1\Assemblies\le\mscorlib.dll', Symbols loaded.
'Microsoft.SPOT.Debugger.CorDebug.dll' (Managed): Loaded 'C:\Program Files (x86)\Microsoft .NET Micro Framework\v4.1\Assemblies\le\Microsoft.SPOT.Native.dll', Symbols loaded.
'Microsoft.SPOT.Debugger.CorDebug.dll' (Managed): Loaded 'C:\Program Files (x86)\Microsoft .NET Micro Framework\v4.1\Assemblies\le\Microsoft.SPOT.Hardware.dll', Symbols loaded.
'Microsoft.SPOT.Debugger.CorDebug.dll' (Managed): Loaded 'C:\Program Files (x86)\Microsoft .NET Micro Framework\v4.1\Assemblies\le\Microsoft.SPOT.Net.dll', Symbols loaded.
'Microsoft.SPOT.Debugger.CorDebug.dll' (Managed): Loaded 'C:\Program Files (x86)\Microsoft .NET Micro Framework\v4.1\Assemblies\le\System.dll', Symbols loaded.
'Microsoft.SPOT.Debugger.CorDebug.dll' (Managed): Loaded 'C:\Program Files (x86)\Microsoft .NET Micro Framework\v4.1\Assemblies\le\Microsoft.SPOT.Hardware.SerialPort.dll', Symbols loaded.
'Microsoft.SPOT.Debugger.CorDebug.dll' (Managed): Loaded 'C:\Program Files (x86)\Microsoft .NET Micro Framework\v4.1\Assemblies\le\Microsoft.SPOT.Graphics.dll', Symbols loaded.
'Microsoft.SPOT.Debugger.CorDebug.dll' (Managed): Loaded 'C:\Users\...\FezHacker\MFConsoleA\MFConsoleA\bin\Debug\le\MFConsoleA.exe', Symbols loaded.
A first chance exception of type 'System.NotImplementedException' occurred in Microsoft.SPOT.Native.dll
The thread '<No Name>' (0x2) has exited with code 0 (0x0).

Could someone point me what can cause this exception please ?

Thank you,
pater

If you have updated SDK on your machine, then it is most likely you need to recompile your firmware and update your board.

yes you are right - i installed netmf 4.2 sdk while on the board was netmf 4.1. But even when i uninstalled netmf sdk 4.2 and installed 4.1 the problem is still present.

The problem is that the version of the SDK you have installed is not consistent with the firmware. You need to re-compile your firmware based on the same version of the porting kit code that matches the SDK version (it’s critical that ll those are matching)

@ Brett i’ve done as you wrote - installed skd 4.1 and pk 4.1 and re-complied all and uploaded to the board. But still the same problem.

@ pater - Did you create a new 4.1 project?

yes project was created from scratch with 4.1.

Can you post up the full code

here you are


using System;
using System.Threading;
using Microsoft.SPOT;
using Microsoft.SPOT.Hardware;

namespace Test
{
    public class Program
    {
        public static void Main()
        {
            OutputPort LED = new OutputPort(Cpu.Pin.GPIO_Pin8, false);

            while (true)
            {
                Thread.Sleep(500);
                LED.Write(true);
                Thread.Sleep(500);
                LED.Write(false);
                Debug.Print("Test");
            }
        }

    }
}

and even Debug.Print is not performing

Still looks like something 4.2 is lurking around - sorry running out of ideas here :frowning:

Maybe it is time to reinstall everything.

i reinstalled everything and the result was the same :frowning: But after some effort i uploaded netduino firmware and it seems to work - at least there is no first chance exception. When i back home i will check with led if it works.

@ pater - erm, whats the processor on your board?

the same as on netduino and on FEZ Hacker SAM7X512.

@ pater - ahh righto - that makes sense now

@ Justin so could you write me what caused this exception when board had custom netmf compiled from SAM7X_EK solution ?

@ pater - i’m still scratching my head to be honest

@ pater - The problem is in your custom firmware. Double check everything. See what is stubbed out.

This is pretty much the extent of what we can help with. Only few of us have/built FEZ Hacker.