Netduino home hardware projects downloads community

Jump to content


The Netduino forums have been replaced by new forums at community.wildernesslabs.co. This site has been preserved for archival purposes only and the ability to make new accounts or posts has been turned off.
Photo

Netduino Plus Unable to connect to from MFDeploy or Visual Studio after loading demo project


  • Please log in to reply
23 replies to this topic

#1 avword

avword

    Member

  • Members
  • PipPip
  • 11 posts

Posted 26 September 2010 - 10:25 PM

I picked up a Netduino Plus at the Maker Faire today. I started to follow the "how to's" on this page: http://netduino.com/projects/


Got through the "blinking an led" how to with no problem. Everything works. Then I did second one "pushing the button". I had no problem doing that one any loading the code onto the Netduino Plus - the board works as expected.

However, after loading that code on there, the Netduino Plus seems to be stuck. I can't load anything else new into it. Hitting F5 in visual studio (with USB and theNetduinoPlus_NetduinoPlus board selected in properties section of the project) causes visual studio to wait forever at "Preparing to deploy assemblies to the device"

Looking thru the forums, I see a thread that would seem to address this issue maybe, except that the solution was to use MFDeploy.exe to load new firmware on the unit. However, I'm basically having the same issues in MFDeploy. When I plug in the board, it shows up in the list in MFDeploy, but as soon as you try to communicate with the board MFDeploy hangs. For example, if you go to Device Capabilities MFDeploy freezes. It only unfreezes when you unplug the Netduino board from the USB port and then the MFDeploy window wakes up and says "Error: No response from device". In one of the forum postings, it suggests I just try to deploy the firmware on the unit by quickly hitting "deploy" in MFDeploy right after I plug in the unit. I've been trying all sorts of combinations of pluging in and quickly trying functions in MFDeploy - nothing seems to work.

I have tried this on 2 different computers with the same results

I guess it should be noted that the "pushing the button" demo is still working on the unit. Shortly after powering up the unit, the button does control the state of the LED on the unit.

So in summary, after loading code from the pushing the button demo on the Netduino Plus, I can no longer communicate with the board from the computer. Is there anyway to completely reset this thing? (the button won't reset it now, because it is being used to control the LED).

Thanks

#2 avword

avword

    Member

  • Members
  • PipPip
  • 11 posts

Posted 26 September 2010 - 10:47 PM

SOLVED. Right after I posted this, I came across this post: http://forums.netdui...indpost__p__216
http://forums.netdui...indpost__p__216


I followed those instructions, then loaded the new firmware on the unit and I am back up and running.

I would echo the other posters in that thread that say the new firmware link should be posted on the downloads page. There should be an item number 4 on the list in upper left that says "download and install the firmware so you don't waste an hour of your life"Posted Image

#3 stacyh3

stacyh3

    Advanced Member

  • Members
  • PipPipPip
  • 47 posts

Posted 26 September 2010 - 10:53 PM

I've been running into the same issue every once in a while. I've been able to get around it by going through the erase process as well. It seems like there's some timing going on there too. Sometimes it takes 2-3 tries to get through the erase. I'll try to keep track of my steps to see if I can make the problem repeat and maybe gain some insight into the issue. Stacy

#4 bill.french

bill.french

    Advanced Member

  • Members
  • PipPipPip
  • 260 posts
  • LocationPrinceton, NJ

Posted 28 September 2010 - 02:35 AM



I followed those instructions, then loaded the new firmware on the unit and I am back up and running.


What new firmware did you install? I thought the firmware that came with the netduino plus was the latest available?

I am having the exact same problem.

#5 Chris Walker

Chris Walker

    Secret Labs Staff

  • Moderators
  • 7767 posts
  • LocationNew York, NY

Posted 28 September 2010 - 02:42 AM

Hi bill.french, Welcome to the Netduino community. What exactly is happening on your Netduino Plus? We'd like to make sure you get back up and running... The firmware on the Netduino Pluses is the latest release. We're working on an updated based on early feedback, but it's at least a few days away from being posted... Chris

#6 bill.french

bill.french

    Advanced Member

  • Members
  • PipPipPip
  • 260 posts
  • LocationPrinceton, NJ

Posted 28 September 2010 - 03:04 AM

Let me start off by saying that I had never heard of arduino or netduino or maker faire until about noon yesterday when I read the engadget article on the netduino plus, and I nearly fell out of my chair. Ethernet? C#? $60??? So I packed my three little kids in the car and headed to Queens. I was so excited about the netduino plus, that I completely forgot to check out the 3d printer corral. Anyway, I'm having trouble!! I'm getting stuck on "preparing to deploy". I did just as the OP did, once I sent the button/led demo, I was unable to further deploy using VS. I've used two totally different computers now, both running fully patched x86 XP. I am able to erase using mfdeploy by holding the button and plugging it in, but obviously it's a bummer dealing with VS crashing and going in circles to deploy very simple programs. The demo and other code does work once I have loaded it. Any suggestions would be greatly appreciated.

#7 avword

avword

    Member

  • Members
  • PipPip
  • 11 posts

Posted 28 September 2010 - 03:19 AM

What new firmware did you install? I thought the firmware that came with the netduino plus was the latest available?

I am having the exact same problem.


Bill,
I installed the firmware located here: http://forums.netdui...ndpost__p__2737

I think the firmware on the unit that I got at the maker faire was older than that.

I will say that visual studio still gets hung up sometimes - but now I am able to either press the reset button or unplug/replug the unit during the deploy process and everything starts working again.

#8 Chris Walker

Chris Walker

    Secret Labs Staff

  • Moderators
  • 7767 posts
  • LocationNew York, NY

Posted 28 September 2010 - 03:21 AM

Hi bill, It sounds like you can deploy apps and you can also erase apps--but Visual Studio is having troubles re-deploying apps. Is that correct? A few quick things: 1. Is there an app that you can deploy--but then when you try to redeploy/re-run it from Visual Studio it gives you troubles? a. If yes, can you attach a copy to this post and we can try it here. 2. What procedure are you following that causes Visual Studio to go in circles? We'd like to try to reproduce this and get you some good instructions or updated firmware ASAP... If there are any issues with the network-enabled firmware that we cannot address right away, you can also switch over to the regular Netduino firmware temporarily. But let's see if we can get you all fixed up first... Chris

#9 bill.french

bill.french

    Advanced Member

  • Members
  • PipPipPip
  • 260 posts
  • LocationPrinceton, NJ

Posted 28 September 2010 - 03:43 AM

To reproduce it, I followed the "pushing the button" demo exactly. Deploy the project, and it works: the led turns on when I press the button. Then, I change led.Write(!buttonstate) to led.Write(buttonstate) -- removing the !, just to get it so the light turns off when you press the button, and I go to redeploy and is gets stuck on "preparing...". It's done it every time. The circles I'm referring to is: once I'm stuck, I have to kill visual studio, erase the app using MFDeploy, going back into visual studio, loading the project (hopefully I've saved it before trying to deploy!) and trying to deploy again. I believe once I'm stuck I can also unplug the netduino, wait a little while, and visual studio will eventually say the deployment failed, and at least I can save my work. Now I try and save before I deploy, which is probably not a bad practice, anyway.

#10 Chris Walker

Chris Walker

    Secret Labs Staff

  • Moderators
  • 7767 posts
  • LocationNew York, NY

Posted 28 September 2010 - 03:53 AM

bill.french, I've submitted this as a bug report and we'll try to reproduce it in the next 24 hours or so. Normally, you'd be able to press the reset button on the Netduino to reset it--but in this case the reset functionality is disabled (since the button is being used as an InputPort instead). If you run the "blink the LED" sample project, does that redeploy alright? If not, does pushing the button fix the situation? Chris

#11 bill.french

bill.french

    Advanced Member

  • Members
  • PipPipPip
  • 260 posts
  • LocationPrinceton, NJ

Posted 28 September 2010 - 04:13 AM

I am able to deploy the below code multiple times. Thanks for you help with this. --Bill

namespace NetduinoApplication1
{
    public class Program
    {
        public static void Main()
        {
            // write your code here
            OutputPort led = new OutputPort(Pins.ONBOARD_LED, false);
            bool b = false;
            while (true)
            {
                b = !b;
                led.Write(B);
                Thread.Sleep(50);
            }

        }

    }
}


#12 Chris Walker

Chris Walker

    Secret Labs Staff

  • Moderators
  • 7767 posts
  • LocationNew York, NY

Posted 28 September 2010 - 04:16 AM

Now if you switch to the "button" sample app, do you have the same problem as before? Is it on the very second deployment that Visual Studio gives you troubles?

#13 bill.french

bill.french

    Advanced Member

  • Members
  • PipPipPip
  • 260 posts
  • LocationPrinceton, NJ

Posted 29 September 2010 - 01:07 AM

Yes, I have the same issue with the button app. I can deploy it once. Then I cannot deploy it again without erasing.

I've also tried the below code, which uses D0 for the button, instead, so I could still have access to the reset. Reset has no effect on how visual studio acts, however. I can see that the board resets (the net leds and the blue led cycle and then my code resumes) but visual studio is uneffected.

Once VS is stuck, i can only unstick it by unplugging the netduino, plugging it back it, waiting for it to boot, then unplugging it again. My code never stops running except during netduino boot up.

I've tried every combo i can think of involving resetting, power cycling, and deploying to get it to work without erasing. No luck.

using System;
using System.Threading;
using Microsoft.SPOT;
using Microsoft.SPOT.Hardware;
using SecretLabs.NETMF.Hardware;
using SecretLabs.NETMF.Hardware.Netduino;

namespace NetduinoApplication1
{
    public class Program
    {
        public static void Main()
        {
            // write your code here
            OutputPort led = new OutputPort(Pins.ONBOARD_LED, false);
            InputPort button = new InputPort(Pins.GPIO_PIN_D0, false, ResistorModes.PullUp);

            while (true)
            {
                led.Write(!button.Read());
            }

        }

    }
}


#14 Chris Walker

Chris Walker

    Secret Labs Staff

  • Moderators
  • 7767 posts
  • LocationNew York, NY

Posted 29 September 2010 - 01:19 AM

So just to confirm: Deploying the LED blinky app multiple times works...but deploying the pushbutton/LED app a second time fails (unless you erase your current app first)? What version of Windows and which edition of Visual Studio are you using? Is this in a virtual machine--or on a native Windows machine? Chris

#15 bill.french

bill.french

    Advanced Member

  • Members
  • PipPipPip
  • 260 posts
  • LocationPrinceton, NJ

Posted 29 September 2010 - 01:26 AM

Yes, blinky deploys multiple times, deploying the pushbutton/led app (using either d0 or the onboard button) fails after the first deployment. I used fully patched windows XP and whatever version of VS is linked in the download section, 2010 express. I've tried it on several computers now, including a Sony vaio, a dell netbook, a dell optiplex, and vm under fusion on a macbook pro. I've even tried it with and without a usb hub involved.

#16 Chris Walker

Chris Walker

    Secret Labs Staff

  • Moderators
  • 7767 posts
  • LocationNew York, NY

Posted 29 September 2010 - 01:55 AM

bill, we'll load up a Windows XP clean install and see if we can reproduce... In the meantime, you may want to reflash with the regular Netduino firmware or avoid using the pushbutton in your programs... I should know more a bit later this week... Chris

#17 bill.french

bill.french

    Advanced Member

  • Members
  • PipPipPip
  • 260 posts
  • LocationPrinceton, NJ

Posted 29 September 2010 - 11:23 AM

Could Windows 7 work better? It's also not isolated to the built on button; i wired up an external button to d0 with the same results.

#18 Chris Walker

Chris Walker

    Secret Labs Staff

  • Moderators
  • 7767 posts
  • LocationNew York, NY

Posted 29 September 2010 - 02:08 PM

bill, It shouldn't matter. Trying it under Windows 7 would provide a good datapoint--but Visual Studio should work well under everything from XP to 7. Chris

#19 Eric Burdo

Eric Burdo

    Advanced Member

  • Members
  • PipPipPip
  • 130 posts

Posted 29 September 2010 - 02:17 PM

In the meantime, you may want to reflash with the regular Netduino firmware


Have you tried the re-flashing bit? I had this error happen a few times... reflashed (technically, I upgraded to the newest "approved" firmware, and the errors went away. Been working fine since then.
~ Eric D. Burdo ~ http://brick-labs.com/

Today LED's, tomorrow, the world!!! Well, OK, maybe servos.

#20 bill.french

bill.french

    Advanced Member

  • Members
  • PipPipPip
  • 260 posts
  • LocationPrinceton, NJ

Posted 29 September 2010 - 02:42 PM

I assume if I upgrade the firmware to the one in that thread, I'll lose the networking components? That's fine as I continue to get warmed up to the netduino, but obviously not a long-term solution. I chuckle as I type: the networking part is kind of important to me. Still hopeful, --Bill




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

home    hardware    projects    downloads    community    where to buy    contact Copyright © 2016 Wilderness Labs Inc.  |  Legal   |   CC BY-SA
This webpage is licensed under a Creative Commons Attribution-ShareAlike License.