Hi there,
I started a few weeks ago trying to build a system that includes Cellular Radio trying to reach a Web Service (WCF) on a Azure Cloud Server.
As part of my project I started to use the default sample program that comes within this site:
using Gadgeteer.Modules.GHIElectronics;
using GHI.Networking;
using Microsoft.SPOT;
using Microsoft.SPOT.Net.NetworkInformation;
using System.Net;
using System.Text;
using System.Threading;
using Gadgeteer.Modules.GHIElectronics;
namespace SampleCellRadio
{
public partial class Program
{
void ProgramStarted()
{
NetworkChange.NetworkAvailabilityChanged += (a, b) => Debug.Print("Network availability changed: " + b.IsAvailable.ToString());
NetworkChange.NetworkAddressChanged += (a, b) => Debug.Print("Network address changed");
this.cellularRadio.ModuleInitialized += this.cellularRadio_ModuleInitialized;
this.cellularRadio.PowerOn(30);
}
void cellularRadio_ModuleInitialized(CellularRadio sender)
{
new Thread(() =>
{
Thread.Sleep(15000);
this.cellularRadio.UseThisNetworkInterface("internet.movistar.com.co", "movistar", "movistar", PPPSerialModem.AuthenticationType.Pap);
while (this.cellularRadio.NetworkInterface.IPAddress == "0.0.0.0")
{
Debug.Print("Waiting on DHCP");
Thread.Sleep(250);
}
Debug.Print(cellularRadio.NetworkInterface.IPAddress);
// What shoul i do??
}).Start();
}
}
}
and I partially achieved until the lease of the IP but after that I donĀ“t know what to do.
Does some body of you could help me with this?.