FEZ Cerbuino Bee - deployment issues

I’ve been having issues with deploying to the Cerb Bee for serveral days. Today I made some progress to discover when it actually happens.

If I choose deploy from the menu in VS I can deploy over and over. It works fine. If I however press F5 (run with debugger) this happens;

Found debugger!
Create TS.
Assembly: Microsoft.SPOT.Hardware.Usb (4.2.0.0) Assembly: Microsoft.SPOT.Hardware.PWM (4.2.0.1)
Assembly: GHIElectronics.Gadgeteer.FEZCerbuinoBee (1.0.6.0) Attaching deployed file.
Assembly: System.Http (4.2.0.0) Attaching deployed file.
Assembly: Microsoft.SPOT.Net.Security (4.2.0.0) Attaching deployed file.
Assembly: Microsoft.SPOT.Touch (4.2.0.0) Attaching deployed file.
Assembly: System.Net.Security (4.2.0.0) Attaching deployed file.
Assembly: GadgeteerApp3 (1.0.0.0) Resolving.
The debugging target runtime is loading the application assemblies and starting execution.

No breakpoints are hit in the code. If I hit stop debugging I can no longer deploy to the device (this is the message):

An error has occurred: please check your hardware.
Request failed
Source: Microsoft.SPOT.Debugger
Stack :
at Microsoft.SPOT.Debugger.Engine.Request.Wait() in c:\depot\current\CLIENT_V4_2\Framework\Debugger\Engine.cs:line 761
at Microsoft.SPOT.Debugger.Engine.SyncMessage(UInt32 cmd, UInt32 flags, Object payload, Int32 retries, Int32 timeout) in c:\depot\current\CLIENT_V4_2\Framework\Debugger\Engine.cs:line 1993
at Microsoft.SPOT.Debugger.Engine.GetAssemblies() in c:\depot\current\CLIENT_V4_2\Framework\Debugger\Engine.cs:line 2928
at Microsoft.SPOT.Debugger.Engine.ResolveAllAssemblies() in c:\depot\current\CLIENT_V4_2\Framework\Debugger\Engine.cs:line 2941
at Microsoft.SPOT.Debugger.VsProjectFlavorCfg.Deploy() in c:\depot\current\CLIENT_V4_2\Framework\CorDebug\VsProjectFlavorCfg.cs:line 869
at Microsoft.SPOT.Debugger.VsProjectFlavorCfg.<Microsoft.VisualStudio.Shell.Interop.IVsDeployableProjectCfg.StartDeploy>b__0() in c:\depot\current\CLIENT_V4_2\Framework\CorDebug\VsProjectFlavorCfg.cs:line 634
========== Deploy: 0 succeeded, 1 failed, 0 skipped ==========

The only way to be able to deply to the device after this happens is to erease the deployment in mfdeploy.

So, I can deploy to the device, but I can never attach the debugger because the device gets stuck in a mode where I can never deploy to it again.

Hope this helps GHI to troubleshoot this and put out a fix.

Thanks.

We released an firmware today, are you using it?

http://www.tinyclr.com/forum/topic?id=8498

I just downloaded it and tried the new version (tiny boot loader and new firmware). Same issue.

please provide exact steps and complete code.

Start Visual Studio. File -> New Project. Select Gadgeteer. Select .Net Gadgeteer Application (v4.2).

Open up Program.gadgeteer. Verify that Cerb Bee is showing as device.

Choose Build -> Deploy.

Verify that Deploy worked ok.

Choose Build -> Deloy.

Verify that Deploy worked ok.

Set break point in Program.generated.cs Line 23 (Mainboard = new GHIElectronics.Gadgeteer.FEZCerbuinoBee():wink:

Hit F5.

Verify that debugger is trying to attach (but is never able to).

Wait 1 minute (or however long you feel it should take for a debugger to attach)

Try pausing. Verify that unable to pause due to debugger still trying to attach.

Press stop.

Choose Build -> Deploy

Verify that Deployment fails.

Hit F5.

Verify that Deployment fails.

Disconnect board. Wait 1 minute. Connect board.

Chose Build -> Deploy

Verify that deploy fails.

Start up mfdeploy.Verify that USB and Cerb-Family_Gadgeteer is showing. Click Erase. Verfiy that Deloyment is checked. Click Erase.

Then you can start over again and verify this script.

I just tried this with FEZ Cerberus and it behaves the same. Not suprising since it’s the same firmware / cpu.

Thanks for looking into this.

do you get the same results if you generate a new project, and without changing any code, hit f5?

sounds like your program is throwing an exception before the debugger can attach.

@ twospoons What version of Windows are you using (Including 32bit or 64bit)?

Yes, see the steps to reproduce.

Windows 7 Pro, 64bit. Build 7601 Service Pack 1.
Visual Studio 2010 Ultimate, Version 10.0.40219.1 SP1Rel.

FYI: All of this worked properly with the previous version of the SDK.

So, I tried a VM, that didn’t work. I removed pretty much everything on my first laptop and installed again. That didn’t work. Did the same thing on my second laptop. Still no luck. I broke out my third laptop tonight and installed it and it worked.

I only have USB 2.0 on all of them so that doesn’t seem to be an issue for me.

Still unclear why it works on my third laptop and not the two other ones. Same version of the operating system. Might be some left over drivers / setting somewhere which the uninstallers doesn’t clear up; or it could be that I have different updates on the laptops (the third one is a work lap top with more controlled updates).

Anyways, I’m a happy camper. I will bite the bullet and do a re-install of my OS on my first laptop and see how that pans out.

Finally back to debugging code! :slight_smile:

Now I envy you…

I’m about to do the same, bring out my laptop and try it there (still can’t find the charger errrrrr)…really weird stuff for sure…

Hi,

I have the same issue. I have got my Cerbuino Bee working fine when using Windows XP. When my laptop has been upgraded to Windows 7, I re-installed all the packages.
Device Capabilities and Ping are working fine with FEZ Config tool:

Connecting to device...Cerb-Family_Gadgeteer
 HalSystemInfo.halVersion :
 HalSystemInfo.halVendorInfo :
 ClrInfo.clrVersion :
 ClrInfo.clrVendorInfo :
 ClrInfo.targetFrameworkVersion :
 SolutionReleaseInfo.solutionVersion: 4.2.5.0
 SolutionReleaseInfo.solutionVendorInfo: Copyright (C) GHI Electronics, LLC
 SoftwareVersion.BuildDate: Apr 25 2013
 SoftwareVersion.CompilerVersion: 410713
 LCD.Width: 0
 LCD.Height: 0
 LCD.BitsPerPixel: 0

FEZ Config fails when trying to retrieve the Device Version : “Cannot access the device : Error code 0x0001”.

Deploying with VS 2010 also fails:

An error has occurred: please check your hardware.
DebugPort.GetDeviceProcess() called with no argument
Source: Microsoft.SPOT.Debugger.CorDebug
Stack : 
   à Microsoft.SPOT.Debugger.DebugPort.GetDeviceProcess(String deviceName) dans c:\depot\current\CLIENT_V4_2\Framework\CorDebug\DebugPort.cs:ligne 270
   à Microsoft.SPOT.Debugger.VsProjectFlavorCfg.Deploy() dans c:\depot\current\CLIENT_V4_2\Framework\CorDebug\VsProjectFlavorCfg.cs:ligne 809
   à Microsoft.SPOT.Debugger.VsProjectFlavorCfg.<Microsoft.VisualStudio.Shell.Interop.IVsDeployableProjectCfg.StartDeploy>b__0() dans c:\depot\current\CLIENT_V4_2\Framework\CorDebug\VsProjectFlavorCfg.cs:ligne 634
========== Build: 1 succeeded or up-to-date, 0 failed, 0 skipped ==========
========== Deploy: 0 succeeded, 1 failed, 0 skipped ==========


I got it work fine on an old PC running Windows XP but I have to work on Windows 7 32 bits.
Does someone have found a solution to that problem?

Regards,

Famory

Please show us device manager screen shots to confirm what device driver you have loaded. Please try to use MFDeploy and report back what Device Capabilities can see.

@ Brett - Hi Brett,

Thanks for the help. Here are all the screenshots I have collected.

Some of the messages are in french (sorry about that).
There is some strange messages displayed when using MFDeploy. Like “LLC GHI Electronics”.

Regards,

Famory

Lets keep working on your issue here, seems this is the more relevant thread :wink:

Some of the “delay” type things you’ve mentioned before have been reported about Visual Studio 2012. Are you using VS2010 or VS2012? I would suggest VS2010 if these delays concern you (there’s an issue logged on codeplex for this delay)

Can you tell us about how much you’ve used your Cerbuino Bee on XP?

Can I ask that you uninstall the GHI SDKs and the NetMF SDK, and start again? It seems to me that some part of the issue you have is because of the first time driver install on the new Win7 PC, so I think if we have the latest SDK and can start from scratch, we will make progress (yes, you’ll need to make sure you have the firmware updated on your Cerb Bee)

@ Brett - OK. That’s fine for me.

I’m using VS 2010.

I’ve bought my Fez Cerbuino Bee 1 year ago and just updated once at the beginning. The first install on Windows XP worked fine the first time. I made the update with MFDeploy (as far as I remember). I was using VS 2010 Express and was able to deploy and debug the applications.

OK. I will uninstall it all and try again. I’m a little bit far from my old PC to update the firmware to 4.2.5.0, so I will try to update with MFDeploy command line.

@ Brett - OK. I have uninstalled it all and re-installed it:

  1. netmf 4.1 (for the Fez Panda II)
  2. nemf 4.2 (QFE2)
  3. GHI netmf 4.1
  4. GHI netmf 4.2 2013-04-30

The driver has been re-installed when I plugged the Cerbuino Bee, but I still have the same behavior when pinging or retrieving the Device Version. (Error 0x0001 with Fez Config).

These are not the steps we list on the support page. Please install in the right order and do not install 4.1 yet.

@ Gus - Hi Gus,

I have uninstalled all again and installed .netmf2 (QFE2) and then GHI NETMF 2 only. I then rebooted the PC to be sure, but I still have the same behavior.

Regards