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.

Denisetoo

Member Since 25 Dec 2012
Offline Last Active Feb 19 2017 12:09 AM
-----

Topics I've Started

Request For Help In Running C#, "Hello World" Program

20 January 2013 - 05:51 PM

Hello,

 

I am having issues running a simple "Hello World" with my netduingo using C# express, Windows 7

 

This is the code:

 

"using System;

using System.Threading;
using Microsoft.SPOT;
using Microsoft.SPOT.Hardware;
 
 
 
namespace HelloWorld
{
    public class HelloWorld
    {
        public static void Main()
        {
            // write your code here
 
            Debug.Print("Hello World");
        }
 
    }
}
"
 
After debugging it, F5,
 
This is what I get in the output window "Incrementally deploying assemblies to device
Deploying assemblies for a total size of 296 bytes
Assemblies successfully deployed to device.
The debugging target and the debugger engine failed to initialize because of unspecified device errors.
The debugger engine thread has terminated unexpectedly with error 'Could not reconnect to the debugging target after rebooting it.'.
"

Request For Help In Testing Pot, Button and RGBLed Go Modules

19 January 2013 - 02:48 PM

Hello,

 

I am attempting to test the potentiometer, button, and RGBLed go modules.  The following code worked until I upgraded to 4.2.2.  Any suggestions are appreciated.

 

 

using System;
using System.Threading;
using Microsoft.SPOT;
using Microsoft.SPOT.Hardware;
using SecretLabs.NETMF.Hardware;
using SecretLabs.NETMF.Hardware.NetduinoGo;
 
namespace PotGoSocketOnly
{
    public class Program
    {
       
        static NetduinoGo.RgbLed led = new NetduinoGo.RgbLed(GoSockets.Socket4);
        static NetduinoGo.Potentiometer pot = new NetduinoGo.Potentiometer(GoSockets.Socket3);
        static NetduinoGo.Button button = new NetduinoGo.Button(GoSockets.Socket2);  // this button will start/stop the flashing
 
        public static bool currentState = false; // keep track of if the button was pressed to turn it on, or off
        public static void Main()
        {
            // write your Main code here
 
            button.ButtonReleased += new NetduinoGo.Button.ButtonEventHandler(button_ButtonReleased);
            //  button.ButtonReleased += new NetduinoGo.Button.ButtonEventHandler(button_ButtonReleased);
 
 
            currentState = false; //make sure we start with it off
 
            while (true) //we're using a device, it will never end
            {
                if (currentState) // see if we should be displaying the LEDs or not
                {
                    led.SetColor((byte)255, (byte)0, (byte)0); // turn on the red LED
                    System.Threading.Thread.Sleep((int)(100 * pot.GetValue()));
                    // pause for a moment based on the potentiometer state
                    led.SetColor((byte)0, (byte)0, (byte)0);
                }
            }
        }
        //button handler
        static void button_ButtonReleased(object sender, bool isPressed)
        {
            currentState = !currentState; //set the state to the opposite of whatever we were before
            Debug.Print("Button Has Been Pushed");
        }
 
 
 
       
    }
}
 

STM DEVICE IN DFU MODE NOT RECOGNIZED IN MFDeploy

19 January 2013 - 12:24 AM

Hello,

 

I am having difficulties erasing the firmware using MFDeploy while in DFU mode.  The MFDeploy does not recognize the STM Device in DFU mode.  MFDeploy does recognize netduingo while not in DFU mode.

 

Any suggestions?

 

Thank you, for your time.


Request For Help In Running C# Programs With 4.2.2

16 January 2013 - 10:52 PM

I updated my netduingo to 4.2.2.  Before I updated I was able to run the program to blink the onboard led on the netduinogo.  Now I get these errors: "The debugging target is not in an initialized state; rebooting...."

 

After a about five to ten minutes I get this in the Visual C# output window:

 

"Incrementally deploying assemblies to device

Deploying assemblies for a total size of 1796 bytes
Assemblies successfully deployed to device.
The debugging target and the debugger engine failed to initialize because of unspecified device errors.
The debugger engine thread has terminated unexpectedly with error 'Could not reconnect to the debugging target after rebooting it.'."
 
When I move unplug the USB connector and replug it, the software is not downloaded to the netduinogo as it did before I downloaded 4.2.2. I have used the steps:
 
change the USB to serial, back to serial.  I still get these errors.
 
Any ideas on how I may correct this?
 

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.