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.

Brian Ingenito's Content

There have been 16 items by Brian Ingenito (Search limited from 22-November 18)


By content type

See this member's

Sort by                Order  

#63346 Problem attempting 4.3.2.2 Firmware Update

Posted by Brian Ingenito on 02 July 2015 - 12:06 PM in Netduino 3

Chris, I installed the sdk and dfuse on a 3rd pc - windows 7.  Same thing, the netduinoupdate just pegs a core and does nothing.  Not all is lost though.  I was just about to switch over to the pi 2 or my gadgeteer and offer to mail your team the board for diagnostics rather than throwing it away when I stumbled on an older howto for flashing with mfdeploy.  From the firmware download, I renamed the flash file extension to .hex so I was able to browse from mfdeploy and to my complete shock it worked.  I got a small error at the end, but all commands in mfdeploy started working and I was able to deploy my app onto the board with visual studio.  Wifi stayed as yellow and wouldn't connect but I'm suspecting my router.  I will confirm that part after work today.




#63261 Problem attempting 4.3.2.2 Firmware Update

Posted by Brian Ingenito on 26 June 2015 - 03:40 PM in Netduino 3

netduinoupdate on both pc just pegs the cpu and requires a force kill when I hit update.




#63248 Problem attempting 4.3.2.2 Firmware Update

Posted by Brian Ingenito on 26 June 2015 - 12:28 AM in Netduino 3

The continuing saga...

 

Managed to hit reset enough times and while trying to select erase firmware in mfdeploy that I think I managed to get a command through.  I can now open the network configuration dialog but I'm back to day one where on startup the wifi doesn't even attempt anymore.  When that first happened to me I reinstalled the firmware but I'm still stuck with the above issue with the cpu peg in the updater and it won't do anything.




#63247 Problem attempting 4.3.2.2 Firmware Update

Posted by Brian Ingenito on 26 June 2015 - 12:17 AM in Netduino 3

Some other things when working this out:

 

netduinoupdate just pegs a cpu and never does anything when I try to upgrade or erase the app (I figured my app had some loop that was consuming everything on the device).  I have a dmp file of netduinoupdate with a pegged cpu if it will help.

 

in mfdeploy, it connects and shows all the deployed assemblies fine but nothing after that works.  Just about every option under the debug menu results in no reply. I can't even open up the network configuration anymore.  It either gives me a null references exception or I get a message saying it is old configuration.  I've tried both the default mfdeploy and the ipv6 one.

 

The power led and wifi led are all on when the device powers up.  In the bootloader mode, the blue debug led and power led are both on.




#63246 Problem attempting 4.3.2.2 Firmware Update

Posted by Brian Ingenito on 25 June 2015 - 11:50 PM in Netduino 3

I'm getting a similar issue. I haven't used my board in a couple weeks and when trying on my win10 I can't deploy anymore and mfdeply app fails on most actions I try.  Restarting the board with the button down and running the netduinoupdate it shows the device but I can't do anything and have to force kill.  Figuring the latest win10 build has destroyed my usb drivers (it killed audio and other stuff for me), I switched to my win8 pc.  Netduino update runs on that, shows my board as Netduino 3 Wi-Fi 4.3.22 and I want to force wipe it and reinstall and it just hangs when I hit update.  I'm afraid my board is dead and I've only done one project.




#62947 Set Network settings during runtime?

Posted by Brian Ingenito on 28 May 2015 - 01:33 AM in Netduino 3

I started working on this before I saw that we would get a wrapper....

 

It looked like the following would do the trick:

 

// Set the static public initialized field to false so that when we later invoke Initialize it will short circuit return

CC3100SocketNative._isInitialized = false;

 

// On the static public _cc3100 instance, add the wireless settings. I'm a bit lost on priority without looking further

CC3100SocketNative._cc3100.sl_WlanProfileAdd(ssid, null, securitytype, securitykey, null, priority);

 

// Re-initialize

CC3100SocketNative.Initialize();

 

 

After catching up on the thread I decided to call it quits otherwise I would have forged ahead and whipped up a pull request once I got it working.  The place where I'm most stuck is how to actually test the above.  I don't even have a Netduino.IP in my references or sdk.  I think I'm missing something silly.

 

Sidenote - I was quite surprised that the class fields above were public.




#62946 Hang in CC3100 socket for HttpWebRequest

Posted by Brian Ingenito on 28 May 2015 - 01:03 AM in Netduino 3

Thanks Chris.  Done - https://github.com/n...CC3100/issues/3




#62842 Hang in CC3100 socket for HttpWebRequest

Posted by Brian Ingenito on 24 May 2015 - 07:34 PM in Netduino 3

Kicked off a thread for the call from the button event and it works great now so it is definitely related to attempting on that same thread as the interrupt.  Strange.  I miss async delegates, etc.  Will clean up with a hacky timer or possibly a queue/waithandle/processing thread of some sort.  This will go on my desk at work under a big red staples easy button to kick off a teamcity build.

 

I'm making this as solved but I'd love to hear some thoughts on why it doesn't work within the event handler.  That is a common scenario that will hit people.




#62836 Hang in CC3100 socket for HttpWebRequest

Posted by Brian Ingenito on 24 May 2015 - 06:10 PM in Netduino 3

I can get to the URL from other machines on my network so I know it is accessible.  As a test, I switched to requesting google on the board and it hangs in the same CC3100.CallFunction within getaddrinfo on the DNS lookup.  I changed it to request by IP and back to the problem above.

 

- Green light for wifi

- When I print out Microsoft.SPOT.Net.NetworkInformation.NetworkInterface.GetAllNetworkInterfaces()[0] in the immediate window, the gateway looks fine (it is my router).  No dns though so I guess I need to manually put that in the network config.  Sorry to fork the thread again, but is there a way to get the dynamic dns enabled so that it can pick up a dns from dhcp?




#62835 Hang in CC3100 socket for HttpWebRequest

Posted by Brian Ingenito on 24 May 2015 - 06:02 PM in Netduino 3

Thanks Mark.  I wasn't sure if there was a pump going on the main thread that you weren't supposed to infinitely put to sleep.  I've been doing UI dev on windows for too long.




#62832 Hang in CC3100 socket for HttpWebRequest

Posted by Brian Ingenito on 24 May 2015 - 05:49 PM in Netduino 3

  public class Program
  {
    private static OutputPort _led;
    private static NetduinoGo.Button _button;

    public static void Main()
    {
      _led = new OutputPort(Pins.ONBOARD_LED, false);
      _button = new NetduinoGo.Button((GoBus.GoPort)1);

      while (IPAddress.GetDefaultLocalAddress() == IPAddress.Any);

      _button.ButtonPressed += Button_ButtonPressed;

      Debug.Print(IPAddress.GetDefaultLocalAddress().ToString());

      while (true) { Thread.Sleep(100); }
    }

    private static void Button_ButtonPressed(object sender, bool isPressed)
    {
      try
      {
        _button.ButtonPressed -= Button_ButtonPressed;
        _led.Write(true);

         SendRequest();
      }
      finally
      {
        _button.ButtonPressed += Button_ButtonPressed;
        _led.Write(false);
      }
    }

    private static void SendRequest()
    {

      try
      {
        HttpWebRequest request = (HttpWebRequest)HttpWebRequest.Create(@"http://192.168.1.15/BuildTrigger/StartBuild.aspx");
        request.Timeout = 10000;
        request.ReadWriteTimeout = 10000;

        // I don't care about the response...
        WebResponse response = request.GetResponse();
        if (response != null)
        {
          response.Close();
        }
      }
      catch (Exception ex)
      {
        Debug.Print(ex.ToString());
      }
    }
  }

I have to say that I really don't feel good about the while/sleep in the main but I haven't yet figured out a way to keep the program running under the debugger or standalone unless the main thread keeps going.   I can include the HTTP_Client code if you want too, but it is essentially the same thing.  The only real difference is it looks at the response code and debug prints the response.




#62830 Hang in CC3100 socket for HttpWebRequest

Posted by Brian Ingenito on 24 May 2015 - 05:37 PM in Netduino 3

mscorlib.dll!System.Threading.WaitHandle.WaitOne(int millisecondsTimeout, bool exitContext)  
[Managed to Native Transition] 
Netduino.IP.LinkLayers.CC3100!Netduino.IP.LinkLayers.CC3100.CallFunction + 0xcb bytes      
Netduino.IP.LinkLayers.CC3100!Netduino.IP.LinkLayers.CC3100.sl_Socket + 0x29 bytes      
Netduino.IP.LinkLayers.CC3100!Netduino.IP.LinkLayers.CC3100SocketNative.socket + 0x60 bytes      
[Native to Managed Transition] 
[Managed to Native Transition] 
Microsoft.SPOT.Net.dll!Microsoft.SPOT.Net.SocketNative.socket(int family, int type, int protocol) + 0x2e bytes           
System.dll!System.Net.Sockets.Socket.Socket(System.Net.Sockets.AddressFamily addressFamily, System.Net.Sockets.SocketType socketType, System.Net.Sockets.ProtocolType protocolType) Line 41 + 0x28 bytes      C#
System.Http.dll!System.Net.HttpWebRequest.EstablishConnection(System.Uri proxyServer, System.Uri targetServer) Line 1393 + 0x189 bytes   C#
System.Http.dll!System.Net.HttpWebRequest.SubmitRequest() Line 1481 + 0x20 bytes           C#
System.Http.dll!System.Net.HttpWebRequest.GetResponse() Line 1700 + 0xd bytes             C#
BuildTrigger.exe!BuildTrigger.Program.SendRequest() Line 79 + 0x27 bytes              C#
BuildTrigger.exe!BuildTrigger.Program.Button_ButtonPressed(object sender, bool isPressed) Line 44 + 0x23 bytes       C#
NetduinoGo.Button.dll!NetduinoGo.Button.OnInterrupt() Line 59 + 0x1e bytes         C#
GoBus.dll!GoBus.GoModule._interruptPort_OnInterrupt(uint data1, uint state, System.DateTime 

I have a successful DCHP connection (thanks again Chris and DevBiker!) and can debug print an IP (I see it on my router network object lists too), but when I attempt to make a request via HttpWebRequest it hangs indefinitely within CC3100 socket waiting for a what I assume is a connection.  I get the same behavior with the netmf toolbox HTTP_Client/IntegatedSocket.  Putting a timeout on HttpWebRequest does nothing.  Could it be related to attempting to make the socket within the interrupt callback for the Go button?

 

 

 

 

 

 

 

 




#62807 WPA2 PSK

Posted by Brian Ingenito on 22 May 2015 - 11:05 PM in Netduino 3

I just deployed an empty app and it lit up.  *sigh of relief*  Thanks!  Now onto some ssl/smtp fun.  The gadgeteer with the wifly just wasn't cutting it for me.




#62805 WPA2 PSK

Posted by Brian Ingenito on 22 May 2015 - 10:55 PM in Netduino 3

Just gave another few tries and never one light besides the white or the blue.  Barring me doing anything obviously silly, I'm guessing I should box it up and return it?




#62797 WPA2 PSK

Posted by Brian Ingenito on 22 May 2015 - 05:11 PM in Netduino 3

No yellow light ever no matter what I select, just the generic white power light.  That is what is driving me crazy.  I've tried while connected to two different pc and have also updated to latest firmware as a possible fix.  Rebooting, etc and no yellow or any other light to make me feel warm and fuzzy that it is working.

 

I assume I just hit apply and applies?  Or do I need to set something else for it to take effect?




#62782 WPA2 PSK

Posted by Brian Ingenito on 22 May 2015 - 12:29 AM in Netduino 3

Attempting to configure dhcp connection against my verizon router with wpa2 and psk.  I select WPAPSK, do I use no auth?  I put in the pass phrase and ssid, and when I apply, no lights are shown other than the power light.  No yellow or anything.  It's as though it isn't even trying to connect.





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.