It looks like there is an issue connecting to a network using some of the wireless routers. If you have Cobra II Wifi and tried it please report what kind of router you have and the outcome of the test.
I will have to check it tonight. Recently I replaced it with an Asus router, so it
is in my computer graveyard.
It might be worth while to post a common test program for connecting to a
DHCP AP. I think everyone has a program that they have tweaked to try
to get it going.
My personal theory is there is something happening with the persistence
of network information on the device. But, I have no real evidence to support
this theory.
@ ransomhall - The Netgear N600 is a wide range model. I am seeing WNDR3400, WNDR3800 and DGND3700. Could you provide a more specific model number please?
@ James - If it will help, I can send you the CiscoE3000 router, the Cobra II and the program I was using to test Wifi DHCP. I was also having problems with a static IP address.
Here is the sample code we used to run the DHCP test, references are included at the top for your convenience, please do not copy this section into your code.
References
#GHI Hardware
#GHI Hardware G120
#GHI Net
#MS Spot Hardware
#MS Spot Native
#MS Spot Net
#System
using System;
using Microsoft.SPOT;
using Microsoft.SPOT.Hardware;
using Microsoft.SPOT.Net;
using GHI.Premium.Net;
using GHI.Premium.Hardware;
using System.Net;
namespace Cobra_II_DHCP_Test
{
public class Program
{
public static WiFiRS9110 wifi;
public static void Main()
{
wifi = new WiFiRS9110(SPI.SPI_module.SPI2, G120.Pin.P1_10, G120.Pin.P2_11, G120.Pin.P1_9);
if (!wifi.IsOpen)
wifi.Open();
if (!wifi.NetworkInterface.IsDhcpEnabled)
wifi.NetworkInterface.EnableDhcp();
wifi.NetworkAddressChanged += new NetworkInterfaceExtension.NetworkAddressChangedEventHandler(wifi_NetworkAddressChanged);
wifi.WirelessConnectivityChanged += new WiFiRS9110.WirelessConnectivityChangedEventHandler(wifi_WirelessConnectivityChanged);
GHI.Premium.Net.NetworkInterfaceExtension.AssignNetworkingStackTo(wifi);
WiFiNetworkInfo[] scanResults = wifi.Scan();
int targetAP = 0;
string passPhrase = "";
wifi.Join(scanResults[targetAP], passPhrase);
IPAddress ip = null;
while (true)
{
ip = IPAddress.GetDefaultLocalAddress();
if (ip != IPAddress.Any)
break;
}
Debug.Print(ip.ToString());
System.Threading.Thread.Sleep(-1);
}
static void wifi_WirelessConnectivityChanged(object sender, WiFiRS9110.WirelessConnectivityEventArgs e)
{
Debug.Print("WiFi is: " + (e.IsConnected ? "connected" : "disconnected"));
}
static void wifi_NetworkAddressChanged(object sender, EventArgs e)
{
Debug.Print("Is DhCp enabled: " + wifi.NetworkInterface.IsDhcpEnabled);
Debug.Print("Is DynamicDnsEnabled enabled: " + wifi.NetworkInterface.IsDynamicDnsEnabled);
Debug.Print("NetworkInterfaceType " + wifi.NetworkInterface.NetworkInterfaceType);
Debug.Print("Network settings:");
Debug.Print("IP Address: " + wifi.NetworkInterface.IPAddress);
Debug.Print("Subnet Mask: " + wifi.NetworkInterface.SubnetMask);
Debug.Print("Default Gateway: " + wifi.NetworkInterface.GatewayAddress);
Debug.Print("Number of DNS servers:" + wifi.NetworkInterface.DnsAddresses.Length);
Debug.Print("------------------------------------------------------");
}
}
}
We just finished testing the Netgear N600 WNDR3400v2 with a successful DHCP lease. We are proceeding to the DLink DIR655.
@ James - I just realized that I have given you some bad info on my WiFi network configuration.
I originally told you that I was having problems with a Cisco E3000, Asus N66U and iPad 3rd generation…
Well, I had forgotten that the Cisco and Asus devicse are just being used as access points. I get my
Internet access through Verizon FIOS, and the interface to Verizon is an ActionTec MI424WR router.
This router acts a cable modem, firewall and wireless access point. Because the device that
Verizon provides does not support N class WiFi, I turn off the wireless on the ActionTec and
user another router as a wireless access point. Thus the use of the Cisco and Asus. But,
DHCP service is always provided by the ActionTec.
The Cobra II was able to associated with both the Cisco and Asus access points. The
issue is with the DHCP address. Therefore, any problem most likely resides with
the ActionTec DHCP server, not the Cisco or Asus routers/APs.
The iPad hotspot connects to Verizon via LTE, so this would be another issue.