Azure / connectthedots

Connect tiny devices to Microsoft Azure services to build IoT solutions
http://connectthedots.io
MIT License
399 stars 274 forks source link

Running netmf connectthedots with FEZ Spider doesn´t run alone but run well using VS. #214

Closed ricargutier closed 8 years ago

ricargutier commented 8 years ago

I deployed the .NETMF connectthedots but as soon as I try to run it out of VS(MF Deploy) it shows my a 10060 DNS Timeout problem. I´m using a FEZ Spider.

Here is the debug screen from MF Deploy:

[1:35:45 a. m. 5/09/2015] Network Up Event - Up 186.168.16.65 [1:35:45 a. m. 5/09/2015] IP Address: 186.168.16.65 [1:35:45 a. m. 5/09/2015] Gateway Address: 192.200.1.21 [1:35:45 a. m. 5/09/2015] DNS Address: 208.67.222.222 [1:36:15 a. m. 5/09/2015] #### Exception System.Net.Sockets.SocketException - CLR_E_FAIL (1) #### [1:36:15 a. m. 5/09/2015] #### Message: [1:36:15 a. m. 5/09/2015] #### Microsoft.SPOT.Net.SocketNative::getaddrinfo [IP: 0000] #### [1:36:15 a. m. 5/09/2015] #### System.Net.Dns::GetHostEntry [IP: 0008] #### [1:36:15 a. m. 5/09/2015] #### ConnectTheDotsGadgeteer.Program::NTPTime [IP: 0008] #### [1:36:15 a. m. 5/09/2015] #### ConnectTheDotsGadgeteer.Program::cellularRadio_NetworkUp [IP: 00bc] #### [1:36:15 a. m. 5/09/2015] #### Gadgeteer.Modules.Module+NetworkModule::OnNetworkEvent [IP: 004d] #### [1:36:15 a. m. 5/09/2015] #### System.Reflection.MethodBase::Invoke [IP: 0000] #### [1:36:15 a. m. 5/09/2015] #### Gadgeteer.Program::DoOperation [IP: 001a] #### [1:36:15 a. m. 5/09/2015] #### Microsoft.SPOT.Dispatcher::PushFrameImpl [IP: 0054] #### [1:36:15 a. m. 5/09/2015] #### Microsoft.SPOT.Dispatcher::PushFrame [IP: 001a] #### [1:36:15 a. m. 5/09/2015] #### Microsoft.SPOT.Dispatcher::Run [IP: 0006] #### [1:36:15 a. m. 5/09/2015] #### Gadgeteer.Program::Run [IP: 001d] #### [1:36:15 a. m. 5/09/2015] #### SocketException ErrorCode = 10060 [1:36:15 a. m. 5/09/2015] #### Exception System.NullReferenceException - CLR_E_NULL_REFERENCE (1) #### [1:36:15 a. m. 5/09/2015] #### Message: [1:36:15 a. m. 5/09/2015] #### ConnectTheDotsGadgeteer.Program::NTPTime [IP: 0104] #### [1:36:15 a. m. 5/09/2015] #### ConnectTheDotsGadgeteer.Program::cellularRadio_NetworkUp [IP: 00bc] #### [1:36:15 a. m. 5/09/2015] #### Gadgeteer.Modules.Module+NetworkModule::OnNetworkEvent [IP: 004d] #### [1:36:15 a. m. 5/09/2015] #### System.Reflection.MethodBase::Invoke [IP: 0000] #### [1:36:15 a. m. 5/09/2015] #### Gadgeteer.Program::DoOperation [IP: 001a] #### [1:36:15 a. m. 5/09/2015] #### Microsoft.SPOT.Dispatcher::PushFrameImpl [IP: 0054] #### [1:36:15 a. m. 5/09/2015] #### Microsoft.SPOT.Dispatcher::PushFrame [IP: 001a] #### [1:36:15 a. m. 5/09/2015] #### Microsoft.SPOT.Dispatcher::Run [IP: 0006] #### [1:36:15 a. m. 5/09/2015] #### Gadgeteer.Program::Run [IP: 001d] #### [1:36:15 a. m. 5/09/2015] Time: 06/01/2011 00:03:01 [1:36:16 a. m. 5/09/2015] LWIP Assertion "DNS response for wrong host name" failed at line 1552 in C:\MicroFrameworkPK_v4_3\DeviceCode\pal\lwip\lwip\src\api\api_msg.c [1:36:45 a. m. 5/09/2015] #### Exception System.Net.Sockets.SocketException - CLR_E_FAIL (1) #### [1:36:45 a. m. 5/09/2015] #### Message: [1:36:45 a. m. 5/09/2015] #### Microsoft.SPOT.Net.SocketNative::getaddrinfo [IP: 0000] #### [1:36:45 a. m. 5/09/2015] #### System.Net.Dns::GetHostEntry [IP: 0008] #### [1:36:45 a. m. 5/09/2015] #### Amqp.TcpTransport::Connect [IP: 0007] #### [1:36:45 a. m. 5/09/2015] #### Amqp.Connection::Connect [IP: 0010] #### [1:36:45 a. m. 5/09/2015] #### Amqp.Connection::.ctor [IP: 0016] #### [1:36:45 a. m. 5/09/2015] #### Amqp.Connection::.ctor [IP: 0008] #### [1:36:45 a. m. 5/09/2015] #### ConnectTheDotsGadgeteer.Program::InitAMQPconnection [IP: 0013] #### [1:36:45 a. m. 5/09/2015] #### ConnectTheDotsGadgeteer.Program::cellularRadio_NetworkUp [IP: 00d1] #### [1:36:45 a. m. 5/09/2015] #### Gadgeteer.Modules.Module+NetworkModule::OnNetworkEvent [IP: 004d] #### [1:36:45 a. m. 5/09/2015] #### System.Reflection.MethodBase::Invoke [IP: 0000] #### [1:36:45 a. m. 5/09/2015] #### Gadgeteer.Program::DoOperation [IP: 001a] #### [1:36:45 a. m. 5/09/2015] #### Microsoft.SPOT.Dispatcher::PushFrameImpl [IP: 0054] #### [1:36:45 a. m. 5/09/2015] #### Microsoft.SPOT.Dispatcher::PushFrame [IP: 001a] #### [1:36:45 a. m. 5/09/2015] #### Microsoft.SPOT.Dispatcher::Run [IP: 0006] #### [1:36:45 a. m. 5/09/2015] #### Gadgeteer.Program::Run [IP: 001d] #### [1:36:45 a. m. 5/09/2015] #### SocketException ErrorCode = 10060 [1:36:45 a. m. 5/09/2015] Error invoking method "Gadgeteer.Modules.Module+NetworkModule" (check arguments to Program.Beg

networkfusion commented 8 years ago

Which network type are you using (WiFi, Cellular or Ethernet)? Which Firmware & bootloader version are you using?

You can try to change the SNTP servers to a more local one (or even just pool.ntp.org) and see if that helps.

and/or, try setting a static dns by changing ethernetJ11D.NetworkInterface.EnableDynamicDns(); to string[] dnsEntries = {"8.8.8.8", "8.8.4.4"}; ethernetJ11D.NetworkInterface.EnableStaticDns(dnsEntries);

ricargutier commented 8 years ago

Well, is working now. It seems that the problem was solved updating some firmware to a newest version to make it work.

Thanks.

networkfusion commented 8 years ago

Please close the issue since it is working.