We were having an issue with one of our EMX Module devices out on site were it was experiencing networking issues and not responding to pings. Swapped it out with a spare and brought it back to diagnose, and here’s the weird bit:
When I debug the device through visual studio the device responds to pings no problem. But when it is running just standalone no response to pings.
To reduce any chance of a coding problem, I removed out the onsite application and deployed a very simple application that basically just starts up and configures the Ethernet.
So, does anybody have any ideas what is so special about debugging in visual studiok?
I want to test the Watchdog practically. Is there is any possibilities to Hang the micro controller through programming, something like run lot of threads, use maximum memory, doing big calculations.
Am using the register class and manage the watchdog, it resets when the counter not reloaded,
Am try hang the controller through the above steps without success.
System.Exception when dividing by 0 is normal. The idea now is to exit the Main() when this error occur :
...
Main(...)
{
try
{
Debug.Print("Starting....");
int a = 20;
int b = 0:
int c = a/b;
}
catch ()
{
Debug.Print("Crashing...."); <= Catch but do nothing, then it will exit main...
}
}
Hello Louis Do you know on average how many attempts are needed to have it working?
I am also experiencing some issues using the EthernetBuiltIn of the EMX. IsCable Conneected returns true avec even if it is disconnected. I see on wireshark that IP is given to the EMX but can’t ping in some cases without knowing why. Restarting the computer sometimes work, sometimes not…
Been awhile since I updated on this problem. I have spent a lot of time investigating and some things have moved on from the original post.
The original connection with debugging in visual studio was slightly misleading. The device in question uses POE and it seems the first time it is powered on, with the cable being inserted, that the original problem with no apparent network or ability to ping appears. If the device initiates a soft reset (which debugging in Visual Studio effectively also does) then the network and pinging is fine - so it was not in fact debugging that fixed the device, but a soft reset.
This leads me to think that the issue is related to the plugging in of the cable, which provides both power and the network, and that something isn’t being activated/initialized properly during that powering-on stage. This points towards more of a hardware issue, or at the very least a software level below that of the NETMF Framework that I work at. I work mainly on the software side, so don’t really know how much control or influence the EMX module has over our Ethernet Module.
One thing to note is that the status information coming from the EthernetBuiltIn object is all good i.e. cable is connected, it is activated, and it is open.
Hello Chris
In fact after verification, the cable connected information is also good… I still do not know why yesterday i observed some troubles about this.
I 'll try to check if I had the same behavior than you on my design