Osbornaldo
Newbie

Posts: 7
|
 |
« on: April 30, 2009, 10:55:01 AM » |
|
Hey Chaps, I've been making some great progress with my efforts to develop for the MF against the GHI Embedded Master board and so far it's a positive experience! However enabling DHCP on my device is preventing me from debugging my application... I have: - Enabled DHCP using the MFDeploy's Target > Configuration > Network menu.
- Manually Set My MAC Address to the 00:21:03:80:00:xx specification
I then reboot my device into debug mode and deploy my application from Visual Studio over serial port as normal - but whilst my application deploys and executes fine - I loose debugging capabilities. What am I missing?
|
|
|
|
|
Logged
|
|
|
|
|
GHI_Support
|
 |
« Reply #1 on: April 30, 2009, 11:25:39 AM » |
|
So it works fine if you did not enable DHCP but used static IP? What Happens if debug in visual studio? It just exists and the application starts? What do you see on the debug output (serial port), if you reboot the device?
|
|
|
|
|
Logged
|
|
|
|
Osbornaldo
Newbie

Posts: 7
|
 |
« Reply #2 on: May 01, 2009, 04:06:50 AM » |
|
It works fine with the default board settings (DHCP disabled). I can run my application from visual studio and it will deploy onto the board (over COM1) and engage the debugger.
When I enable DHCP the board does pick up an IP address from our server (though it takes about 5 seconds to do it) - so DHCP seems to work fine.
I then reboot my board into debug over COM1 as I usually do and try to run my application from visual studio. The application is pushed out to the board and begins to execute but Visual Studio seems to loose connection with the board (it exits debug mode).
I've seen mention on the forums about debugging over TCP/IP - would that help? If so - how do I achieve this?
|
|
|
|
|
Logged
|
|
|
|
|
SupportAdmin
|
 |
« Reply #3 on: May 01, 2009, 07:12:40 AM » |
|
You can debug using serial and keep DHCP enabled. The problem is the device is taking a long time to get an IP and so VS2008 is timing-out. The text below from the Microsoft micro framework forum Issue:
After deploying an application from Visual Studio, the device is rebooted. In some cases, DHCP can cause Visual Studio to time out while waiting for a reconnect, preventing Visual Studio from debugging the device.
Resolution: Add a registry key and value to increase the amount of time Visual Studio will wait for a reconnect. The default of 5 seconds may be extended by creating the following key and setting its timeout, retries, and override values:
HKCurrentUser\ Software\ Microsoft\ .NetMicroFramework\ NonVersionSpecific\ Timing\ AnyDevice
'timeout' (DWORD): milliseconds to wait before retrying (constrained to 50 < timeout < 60000) 'retries' (DWORD): count of retries to attempt (constrained to 1 < retries < 1000) 'override' (DWORD): if present and non-zero, ignore constraints above, and attempt to apply any valid DWORD values.
If any one of the values provided is out of bounds or malformed, it is silently ignored and the default values remain in effect. However, the others that are valid are still be applied.
The default values are as in v2 SP1: timeout = 100 for platforms that support a soft reboot, 1000 otherwise; retries = 10.
|
|
|
|
|
Logged
|
|
|
|
Osbornaldo
Newbie

Posts: 7
|
 |
« Reply #4 on: May 01, 2009, 11:28:08 AM » |
|
Thanks again for you help - that worked great.
So far am very impressed with the support offered on this forum.
Particularly when you consider this problem was more of a general MF/Visual Studio issue than anything to do with GHI.
Thanks again!
|
|
|
|
|
Logged
|
|
|
|
|
microt
|
 |
« Reply #5 on: May 17, 2009, 07:48:52 PM » |
|
•Enabled DHCP using the MFDeploy's Target > Configuration > Network menu. Works great
But how do I do it from the code I tried EnableDHCP(); at start up
Error 1 The name 'EnableDHCP' does not exist in the current context C:\Installs\MSVC#\Test\Test_01\Test_01\Program.cs 66 13 Test_01
What am I missing
|
|
|
|
« Last Edit: May 20, 2009, 01:03:04 PM by microt »
|
Logged
|
|
|
|
|
SupportAdmin
|
 |
« Reply #6 on: May 20, 2009, 01:41:42 PM » |
|
These questions are best answered by the Microsoft forum for Micro Framework
The function is NetworkInterface.EnableDhcp()
|
|
|
|
|
Logged
|
|
|
|
lbq1221119
Newbie

Posts: 15
|
 |
« Reply #7 on: May 21, 2009, 03:13:12 AM » |
|
i have the same problem as above, and when i look into register,
i can not find
HKCurrentUser\ Software\ Microsoft\ .NetMicroFramework\ NonVersionSpecific\ Timing\ AnyDevice
there is not a NetMicroFramework under Microsoft.
do i missing something?
|
|
|
|
|
Logged
|
|
|
|
|
SupportAdmin
|
 |
« Reply #8 on: May 21, 2009, 11:02:27 AM » |
|
Maybe they removed it or moved it?! Again, this question is better answered by Microsoft
|
|
|
|
|
Logged
|
|
|
|
sutsch
Newbie

Posts: 15
|
 |
« Reply #9 on: May 22, 2009, 02:08:15 PM » |
|
If the entries are not there just add them! Work like a charm! :-)
|
|
|
|
|
Logged
|
|
|
|
|
microt
|
 |
« Reply #10 on: June 25, 2009, 11:32:17 PM » |
|
Using 3.0
Tried enabling DHCP using the MFDeploy's Target > Configuration > Network menu.
Error: Unable to update configuration sector memory
|
|
|
|
|
Logged
|
|
|
|
|
SupportAdmin
|
 |
« Reply #11 on: June 26, 2009, 09:14:39 AM » |
|
Reload the firmware as the configuration could be corrupted. Also, enter TinyBooter before trying to update
|
|
|
|
|
Logged
|
|
|
|
|
microt
|
 |
« Reply #12 on: June 30, 2009, 04:12:00 PM » |
|
Since there is lot of delay if DCHP is enabled..and there is a blank screen..is there a better way of doing this?
-Start of with a static IP <or> not TCP/IP. So the system comes up fast.. -Once the system is up and running..from the Applicaiton software..Print "DHCP enabled..getting new IP" on the LCD -Then enable TCPIP & DHCP and time out if DHCP does not work, so the applicaion can and go to a static IP
|
|
|
|
|
Logged
|
|
|
|
|
GHI_Support
|
 |
« Reply #13 on: June 30, 2009, 04:41:03 PM » |
|
Yes, you can do this in your software. Also, the screen is not blank, we do print getting Ip address when DHCP is enabled! unless you disabled debug messages.
|
|
|
|
|
Logged
|
|
|
|
|
SupportAdmin
|
 |
« Reply #14 on: June 30, 2009, 08:23:45 PM » |
|
I think once you enable DHCP in software then it gets saved in flash and so next time you power up the device it will still wait for an IP address. This problem was reported to Microsoft long time ago! Maybe future release will handle DHCP better
|
|
|
|
|
Logged
|
|
|
|
|