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.

zee's Content

There have been 47 items by zee (Search limited from 24-May 23)


By content type

See this member's


Sort by                Order  

#47216 Piezo on Netduino ?

Posted by zee on 15 March 2013 - 03:46 AM in General Discussion

Hi,

 

I need help here.. I am now doing a project for drum using piezo & led.. I have been researching for it for almost a week, but the results seem to be only for Arduino Uno. I could not find any help on the codes for Netduino Plus 2. Is there any codes that is similar to this project?




#48201 Maxbotix Distance/Proximity Sensor Code

Posted by zee on 09 April 2013 - 03:24 AM in Project Showcase

Hi Omar,

 

I followed your C# for analog but when run the program, it stop by itself. Is there anything that i missed out??

Btw, where should i print out the distance?




#48198 uPLibrary : a .Net Micro Framework Helper Library

Posted by zee on 09 April 2013 - 02:02 AM in Project Showcase

Hi Paolo,

 

Just to clarify, to do a project on ultrasonic for distance measurement, is it a must to have this library? If yes, i encountered this errors and need your help. Thanx..

 

I tried to install the package but it show me this errors:

 

 

PM> Install-Package uPLibrary
Install-Package : The current environment doesn't have a solution open.
At line:1 char:16
+ Install-Package <<<<  uPLibrary
    + CategoryInfo          : InvalidOperation: (:) [Install-Package], InvalidOperationException
    + FullyQualifiedErrorId : NuGetNoActiveSolution,NuGet.PowerShell.Commands.InstallPackageCommand
 
 



#48424 RTTTL - Ringtone Player

Posted by zee on 16 April 2013 - 03:31 AM in General Discussion

I think the Queue class is found within the the System.Collections namespace, so try changing from just new Queue() to new System.Collections.Queue() or probably better to simply add this statement in the beginning of Program.cs

 

using System.Collections; 

 

You might also want to look at this post also covering an RTTL player:

 

http://forums.netdui...sed-controller/

 

Yes yes.. It works! Thank you Hanzibal  :D




#48404 RTTTL - Ringtone Player

Posted by zee on 15 April 2013 - 09:35 AM in General Discussion

Hi,

 

I am currently doing a project on ringtone player. This code we found on http://dev-bin.com/2...e-player-rtttl/ .. Hence we decided to try it out and we found an error in Program.cs. We try to solve it by refer to the reference on the link but it did not seem to work.

 

static Queue SongQueue = new Queue();

 

 

Error 1 The type or namespace name 'Queue' could not be found (are you missing a using directive or an assembly reference?) C:UsersL33532DesktopMidPresentationMidPresentationProgram.cs 18 16 MidPresentation
Error 2 The type or namespace name 'Queue' could not be found (are you missing a using directive or an assembly reference?) C:UsersL33532DesktopMidPresentationMidPresentationProgram.cs 18 38 MidPresentation
 
 
PS: Need your help as soon as possible because our deadline is in 2 more days. URGENTTTT!!!  :o  :unsure:  :wacko:
 
Thanx.. :)

Attached Files




#49131 Set password on touch shield with servo

Posted by zee on 07 May 2013 - 01:59 AM in General Discussion

Hi,

 

Has anyone tried to do a project on touch shield with servo? It is to set a correct password on the touch shield and servo will turn it if the button been pressed correctly. 

 

I did followed the codes from http://forums.netdui...=+touch +shield and I am using the same product https://www.sparkfun.../products/10508

 

I still could not understand of how and where to insert the code for setting password and connect together with servo (if possible).




#49321 Set password on touch shield with servo

Posted by zee on 10 May 2013 - 01:18 AM in General Discussion

Oh. Thanx Hanzibal. Will try to work it out.  :)




#49203 Set password on touch shield with servo

Posted by zee on 08 May 2013 - 01:27 AM in General Discussion

Hi,

 

Thank for the quick response. You mean, touch shield can't be used for password? In order for me to use a servo to do some actions, I need to use something like this?

 http://www.karlssonr...CFVSVMgodv04AEw

or

https://www.sparkfun.../products/10250

 

 

I'm sorry for this noob question. But, what else can touch shield do?




#47215 PWM - Deploy Fail

Posted by zee on 15 March 2013 - 03:37 AM in Netduino Plus 2 (and Netduino Plus 1)

Hi zee, The code looks fine at first glance. Let's check out the other variables... What board are you using? Netduino? Netduino Plus 2? When you open up project properties, and then go to the .NET MF tab...do you see your Netduino in the device pulldown? When deployment fails, go to the Output tab in Visual Studio. If it shows more information about what failed during deployment, please post that info here. Chris

 

Hi Chris,

 

Thanx for the response..

 

I am using Netduino Plus 2.. Yes, there is Netduino in the device pulldown.. 

The error in the output tab, stated "Unable to communicate with device - USB:Netduino"..




#46858 PWM - Deploy Fail

Posted by zee on 08 March 2013 - 12:37 AM in Netduino Plus 2 (and Netduino Plus 1)

Hi.. Thanks for the quick reply.. I did not set any frequency on it.

 

Here are my codes..

 

 

using System;
using System.Net;
using System.Net.Sockets;
using System.Threading;
using Microsoft.SPOT;
using Microsoft.SPOT.Hardware;
using SecretLabs.NETMF.Hardware;
using SecretLabs.NETMF.Hardware.Netduino;
 
namespace Dimmer_PWM
{
    public class Program
    {
        public static void Main()
        {
            // write your code here
 
            SecretLabs.NETMF.Hardware.PWM led = new SecretLabs.NETMF.Hardware.PWM(Pins.GPIO_PIN_D5); 
            SecretLabs.NETMF.Hardware.AnalogInput pot = new SecretLabs.NETMF.Hardware.AnalogInput(Pins.GPIO_PIN_A0);
            pot.SetRange(0, 100);
            int potValue = 0; //store and retrieve the potentiometer's current position
 
            while (true)
            {
                //read the value of the potentiometer
                potValue = pot.Read();
 
                //change the led intensity base on the potentiometer's value (0-100%)
               led.SetDutyCycle((uint) potValue);
                             
            }
 
        }
 
    }
}



#46813 PWM - Deploy Fail

Posted by zee on 07 March 2013 - 09:02 AM in Netduino Plus 2 (and Netduino Plus 1)

Hi,

 

This is my second time try to run this project. Its from the 'Getting Started with Netduino' on Chapter 6, Dimmer Code..I have installed the SecretLabs.NETMF.Hardware.PWM and there is no error in the code. However, when it is running, it states that "unable to communicate with device - USB:Netduino" under the output tab.

There is also a message box pop-up "There were deployment errors. Continue?".

 

 

Please help me !!! Thank you!




#48678 Touch Shield

Posted by zee on 24 April 2013 - 03:18 AM in General Discussion

Hi,

 

I am doing on a project for home security. I decided to add in the touch shield https://www.sparkfun.../products/10508. I am sure the codes are all correct as when i run it, there is no error. But i am curious about my wiring. Unsure if it is correct or wrong.

 
Connected with 2 1K resistors. 1 resistor for SCL and the other for SDA. It is connected together with the 5V from the netduino board. 3.3V directly connected from the netduino to the touch shield. Interrupt port on D2 with ResistorModes.PullUp (from shield board TX to resistor (with SDA) to D2).. All grounds are connected.
 
Is there any missing or errors on my wiring?



#48679 Touch Shield

Posted by zee on 24 April 2013 - 03:18 AM in General Discussion

Btw, i am using Netduino Plus 2




#48876 Touch Shield

Posted by zee on 30 April 2013 - 09:25 AM in General Discussion

Problem solved !  B)  :D  B)  :D

 

One of the jumper is faulty. HAHA! :D




#46864 Error: No response from device (HELP!!!)

Posted by zee on 08 March 2013 - 02:04 AM in General Discussion

Hi Black Rose, When you power on your Netduino Plus, does the blue LED go out after a few seconds (indicating that it has booted)? If so, try to erase your current Netduino app: 1. Unplug your Netduino Plus and all components 2. Open up MFDeploy on your computer, select USB transport 3. Hold down the pushbutton on your Netduino Plus. This will force it into bootloader mode. 4. Connect your Netduino Plus to your PC (and keep holding the button). 5. Within 2 seconds, press the ERASE button in MFDeploy. Does that fix things for you? Also...after that, I'd recommend upgrading to the lasest firmware (v4.1.0.6 or v4.1.1 alpha 7+). Chris

 

 

Hi Chris,

 

I have the same problem too, after ive upgraded the firmware to 4.2,2. But when plugged into the USB, the LED is not blinking. However there is an error message saying that "There were deployment error. Continue?" and error output message " Unable to communicate with device - USB:Netduino"..

 

I encountered this problem before. The first was i need to change the hardware. So,i am afraid if the problem i faced is similar like before.

 

Your help is kindly appreciated! :)




#48875 Touch Shield

Posted by zee on 30 April 2013 - 09:16 AM in General Discussion

I don't fully understand what you mean by "from shield board TX to resistor (with SDA) to D2" though?

 Ignore this. Haha!

 

I did found the solution Last Friday and when i want to try again today, seems like its not working. Whats happening??  :wacko:  :blink:

 

This should be correct right?

readonly InterruptPort irqpin = new InterruptPort(Pins.GPIO_PIN_D2, true, ResistorModes.PullUp, Port.InterruptMode.InterruptEdgeLow);

 

Both resistors are connectec to 5V. 1 resistor will wired up to SDA and the other resistor to SCL. And, InterruptPort is directly connected from touch shield to D2. Right?




#46873 Error: No response from device (HELP!!!)

Posted by zee on 08 March 2013 - 07:27 AM in General Discussion

Hi Chris,

 

I managed to solve the problem. Yup,thanks for the help Chris! :)




#47168 Piezo sensor

Posted by zee on 14 March 2013 - 02:57 AM in Netduino Plus 2 (and Netduino Plus 1)

Hi..

 

I need help here! I am doing a project for drum with led lights up upon hit the piezo. Can arduino codes be used for netduino plus 2? Researching since just now and the results are all for arduino uno.




#47071 mscorlib.dll error

Posted by zee on 12 March 2013 - 09:17 AM in Netduino Plus 2 (and Netduino Plus 1)

Sorry Stefan.. My typo error.. Instead of 'i', I accidentally typed '1'..

 

instead of :

 

string note = song.Substring(i, 1);
int beatCount = int.Parse(song.Substring(i + 1, 1));
 
 My silly mistakes:
string note = song.Substring(1, 1);
int beatCount = int.Parse(song.Substring(1 + 1, 1));

 

Sorry for the Inconveniences cause..




#47070 mscorlib.dll error

Posted by zee on 12 March 2013 - 09:07 AM in Netduino Plus 2 (and Netduino Plus 1)

Sorry.. the PWM i editted it to SecretLabs.NETMF.Hardware.PWM speaker = new SecretLabs.NETMF.Hardware.PWM(Pins.GPIO_PIN_D5);




#47069 mscorlib.dll error

Posted by zee on 12 March 2013 - 08:58 AM in Netduino Plus 2 (and Netduino Plus 1)

Hi Stefan,

 

Here's the code below:

 

 

 

public static void Main()
{
// write your code here
 
// store the notes on the music scale and their associated pulse lengths
System.Collections.Hashtable scale = new System.Collections.Hashtable();
 
// low octave
scale.Add("c", 1915u);
scale.Add("d", 1700u);
scale.Add("e", 1519u);
scale.Add("f", 1432u);
scale.Add("g", 1275u);
scale.Add("a", 1136u);
scale.Add("b", 1014u);
 
// high octave
scale.Add("C", 956u);
scale.Add("D", 851u);
scale.Add("E", 758u);
 
// silence ("hold note")
scale.Add("h", 0u);
 
int beatsPerMinute = 90;
int beatTimeInMilliseconds =
60000 / beatsPerMinute; // 60,000 milliseconds per minute
int pauseTimeInMilliseconds = (int)(beatTimeInMilliseconds * 0.1);
 
// define the song (letter of note followed by length of note)
string song = "C1C1C1g1a1a1g2E1E1D1D1C2";
 
// define the speaker
PWM speaker = new PWM(Pins.GPIO_PIN_D5);
 
// interpret and play the song
for (int i = 0; i < song.Length; i += 2)
{
// extract each note and its length in beats
string note = song.Substring(i, 1);
int beatCount = int.Parse(song.Substring(i + 1, 1));
 
// look up the note duration (in microseconds)
uint noteDuration = (uint)scale[note];
 
// play the note for the desired number of beats
speaker.SetPulse(noteDuration * 2, noteDuration);
Thread.Sleep(
beatTimeInMilliseconds * beatCount - pauseTimeInMilliseconds);
 
// pause for 1/10th of a beat in between every note.
speaker.SetDutyCycle(0);
Thread.Sleep(pauseTimeInMilliseconds);
 
}
 
Thread.Sleep(Timeout.Infinite);
}
 
 
 
Thanks for your help! :)



#47063 mscorlib.dll error

Posted by zee on 12 March 2013 - 07:06 AM in Netduino Plus 2 (and Netduino Plus 1)

Hi,

 

I got an error when deploy piezo. An error message box pop up "An unhandled exception of type 'System.Exception' occurred in mscorlib.dll".. Can anyone please help me where is the problem?




#46745 Netduino Plus 2 - AnalogInput & SetRange errors

Posted by zee on 06 March 2013 - 10:08 AM in Netduino Plus 2 (and Netduino Plus 1)

Hi and welcome to the Netduino forums!

 

The book describes the Netduino API, I think your problem would be fixed if you'd remove the reference to Microsoft.SPOT.Hardware.AnalogInput.dll and add a reference to SecretLabs.NETMF..Hardware.AnalogInput.dll

 

After following your instructions, there are more errors.. Anyway i am new to this Netduino Plus 2.. Could you please explain to me in detail? Thank you.

 

 

Error 1 'AnalogInput' is an ambiguous reference between 'Microsoft.SPOT.Hardware.AnalogInput' and 'SecretLabs.NETMF.Hardware.AnalogInput'
 
Error 2 'AnalogInput' is an ambiguous reference between 'Microsoft.SPOT.Hardware.AnalogInput' and 'SecretLabs.NETMF.Hardware.AnalogInput'
Error 3 The best overloaded method match for 'Microsoft.SPOT.Hardware.AnalogInput.AnalogInput(Microsoft.SPOT.Hardware.Cpu.AnalogChannel)' has some invalid arguments
 
Error 4 Argument 1: cannot convert from 'Microsoft.SPOT.Hardware.Cpu.Pin' to 'Microsoft.SPOT.Hardware.Cpu.AnalogChannel'
 
Error 5 'Microsoft.SPOT.Hardware.AnalogInput' does not contain a definition for 'SetRange' and no extension method 'SetRange' accepting a first argument of type 'Microsoft.SPOT.Hardware.AnalogInput' could be found (are you missing a using directive or an assembly reference?)
 
Error 6 Cannot implicitly convert type 'double' to 'int'. An explicit conversion exists (are you missing a cast?)
 



#47008 Netduino Plus 2 - AnalogInput & SetRange errors

Posted by zee on 11 March 2013 - 05:55 AM in Netduino Plus 2 (and Netduino Plus 1)

How was the problem solved? I'm facing the exact same problem now.

 

number 6 seems to be just a matter of changing int potValue=0; to double potValue=0;

 

 

I include the SecretLabs.NETMF.Hardware.AnalogInput command infront & add reference 'SecretLabs.NETMF.Hardware.AnalogInput..

 

eg:

SecretLabs.NETMF.Hardware.AnalogInput pot = new SecretLabs.NETMF.Hardware.AnalogInput(Pins.GPIO_PIN_A0);




#46724 Netduino Plus 2 - AnalogInput & SetRange errors

Posted by zee on 06 March 2013 - 03:38 AM in Netduino Plus 2 (and Netduino Plus 1)

Hi,

 

I am using Netduino Plus 2 and I followed the steps from 'Getting Started with Netduino' pdf on Chapter 5. I encountered few problems on the coding. There are 4 errors. Please help me!

 

 

 

Error 1 The best overloaded method match for 'Microsoft.SPOT.Hardware.AnalogInput.AnalogInput(Microsoft.SPOT.Hardware.Cpu.AnalogChannel)' has some invalid arguments
 
Error 2 Argument 1: cannot convert from 'Microsoft.SPOT.Hardware.Cpu.Pin' to 'Microsoft.SPOT.Hardware.Cpu.AnalogChannel'
 

 

Error 3 'Microsoft.SPOT.Hardware.AnalogInput' does not contain a definition for 'SetRange' and no extension method 'SetRange' accepting a first argument of type 'Microsoft.SPOT.Hardware.AnalogInput' could be found (are you missing a using directive or an assembly reference?)
 
Error 4 Cannot implicitly convert type 'double' to 'int'. An explicit conversion exists (are you missing a cast?)

 

Looking forward to your speedy response. Thank you!





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.