I have a FEZ Cobra and attempted to deploy (via Visual Studio) the ‘HelloWorldServer_MF project from the ‘Microsoft .NET Micro Framework 4.1\Samples folder. I received the following error:
An unhandled exception of type ‘System.Net.Sockets.SocketException’ occurred in Microsoft.SPOT.Net.dll
I have not set the mac address (I accepted the default). Is this a requirement? I accepted the default ip which worked on my network and I was able to ping.
I can ping the device. Doesnt this tell me that the settings are ok?
Additionally, the error message above is all the feedback I get. Maybe I should set a breakpoint at the entry point of the application. Perhaps this might tell me more.
Well, if you know your routers IP you can confirm your settings. Gateway/DNS are both going to be the routers IP. The device IP is whatever you want it to be.
I have checked the example on my cobra and the exception didn’t occur
[quote]The thread ‘’ (0x2) has exited with code 0 (0x0).
Start DPWS device service with endpoint address: 'urn:uuid:18571766-87df-06e2-bb68-5136c48f483f’
The thread ‘’ (0x1) has exited with code 0 (0x0).
[/quote]
Have you changed something in the code? Or have you only compiled and deployed?
I have the same problem. When I try to execute that example I get the same error at the same line:
[quote]Start DPWS device service with endpoint address: ‘urn:uuid:18571766-87df-06e2-bb68-5136c48f483f’
#### Exception System.Net.Sockets.SocketException - CLR_E_FAIL (1) ####
#### Message:
#### Microsoft.SPOT.Net.SocketNative::sendto [IP: 0000] ####
#### System.Net.Sockets.Socket::SendTo [IP: 0022] ####
#### System.Net.Sockets.Socket::SendTo [IP: 000a] ####
#### Dpws.Device.Discovery.DpwsDiscoGreeting::SendGreetingMessage [IP: 0087] ####
#### Dpws.Device.Device::Start [IP: 0020] ####
#### Dpws.Device.Program::Start [IP: 008a] ####
#### Dpws.Device.Program::Main [IP: 0033] ####
#### SocketException ErrorCode = 10049
#### SocketException ErrorCode = 10049
A first chance exception of type ‘System.Net.Sockets.SocketException’ occurred in Microsoft.SPOT.Net.dll
#### SocketException ErrorCode = 10049
An unhandled exception of type ‘System.Net.Sockets.SocketException’ occurred in Microsoft.SPOT.Net.dll[/quote]
In my case, I am not able to ping the device using MFDeploy tool, but I can ping it from a command shell. I have just installed the 4.1 firmware to the device and configured the network properties the same way I had before (it used to work perfectly with 4.0). I am using an Embedded Master Development Board with EMX firmware.
I think that means it can’t get out to the internet. You do have MFDeploy setup correctly, right? Gateway/DNS are your router’s IP, Subnet mask is 255.255.255.0.