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.

carb's Content

There have been 185 items by carb (Search limited from 07-June 23)


By content type

See this member's


Sort by                Order  

#38590 ADC reads show unexpected values

Posted by carb on 06 November 2012 - 02:06 AM in Netduino Plus 2 (and Netduino Plus 1)


Dim senstemp As New AnalogInput(Cpu.AnalogChannel.ANALOG_1)
Dim Temp As Double = 0


JManual,

Try something like the following:
Imports SecretLabs.NETMF.Hardware

 Dim TempSensor As New SecretLabs.NETMF.Hardware.AnalogInput(Pins.GPIO_PIN_A0)

Also I have some code listed in Visual Basic for the Netduino Go and shieldbase.

Just search for TMP36, should help with averaging the temperatures and conversion to different scales.

Just remember that the shieldbase has a 12 bit ADC (3.3vdc / 4096) while the other Netduinos use 10 bit ADCs (3.3vdc / 1024).

Hope this helps,
Chuck



#38505 Serial port / Project Help

Posted by carb on 04 November 2012 - 06:51 PM in Netduino 2 (and Netduino 1)

So my goal is to drive two of these relay boards for a total of 32 channels. I will need to cascade 4 shift registers to get this done. Would you say that I can drive this directly off the netduino ? If not what would my alternative be transistors?


Thomas,

You may want to look at this shield, it is made by a membeer of this forum. Multiplexor shield

I have one that I put together but have not used yet. The price was right.

Chuck



#38315 Power Outage in New York

Posted by carb on 01 November 2012 - 01:20 AM in General Discussion

We just got out power back. Much of New Jersey is completely devastated. Still millions without power and so many people lost their homes to fire and the ocean.

Glad to here all are well, you can replace everything but your life.

Be safe,
Chuck



#38314 Best WiFi option for Netduino

Posted by carb on 01 November 2012 - 01:17 AM in Netduino Plus 2 (and Netduino Plus 1)

Thanks for the suggestions, everyone. Seems like a Ethernet to WiFi bridge is the easiest solution, albeit a little bulky relative to other solutions. But for my purposes, it will work fine for now. I wanted WiFi connectivity with as little work as possible for this application, but I'm sure I will mess around with other solutions as well in the future, specifically the Wixel. Thanks again.

Anshul,

I like the IOGear GWU627 WiFi Adapter, about $35 and roughly the same size as the netduino Plus.

Chuck



#38141 Anyone else building Netduino Powered Halloween Props?

Posted by carb on 28 October 2012 - 07:46 PM in General Discussion

Giuliano,

I purchased a couple of the Parallax Rev B PIRs.

I connected one the PIRs to my Netduino Classic, and it worked fine without a pull resistor. I wrote sample code to operate the onboard LED and a digital output for a relay. Connecting the PIR to Ground, 3.3 vdc and D2

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

namespace PIR_Test
{
  public class Program
  {
    static OutputPort D1 = new OutputPort(Pins.GPIO_PIN_D1, false);
    static InputPort PIR = new InputPort(Pins.GPIO_PIN_D2, false,Port.ResistorMode.Disabled);
    static OutputPort LED = new OutputPort(Pins.ONBOARD_LED, false);
   
    public static void Main()
    {
      Thread.Sleep(20000);
      while (true)
      {
        LED.Write(PIR.Read());
        D1.Write(PIR.Read());
      }
    }
  }
}
Chuck



#37998 What drives your passion?

Posted by carb on 27 October 2012 - 11:03 AM in General Discussion

Steve, Great story, you ever consider writting a book? I voted. :) Chuck



#37988 Grove-Base Shield and Relay Netduino Plus/Arduino

Posted by carb on 26 October 2012 - 05:16 PM in Netduino Plus 2 (and Netduino Plus 1)

I do not set the initial pin state. The netduino probably does boot with the pin positive and they stay positive. I believe that it is a software issue I probably need to change a setting in the firmware.

Thank you for the suggestion

Aberkley,

Netduinos use the Digital ports in almost every application.

I wrote the following code to test it on my Netduino classic and it worked fine. With a voltmeter I had 3 milli volts when the button was NOT pushed, 3.3 vdc when the Onboard button is pressed.

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

namespace Digital_Pin_Test
{
  public class Program
  {
    static OutputPort D1 = new OutputPort(Pins.GPIO_PIN_D1, false);
    static InputPort Button = new InputPort(Pins.ONBOARD_SW1, false,Port.ResistorMode.Disabled);
   
    public static void Main()
    {
      while (true)
      {
        D1.Write(Button.Read());
      }
    }
  }
}
For Visual Basic use:
Imports System
Imports System.Threading
Imports Microsoft.SPOT
Imports Microsoft.SPOT.Hardware
Imports SecretLabs.NETMF.Hardware
Imports SecretLabs.NETMF.Hardware.Netduino

Namespace Digital_Pin_Test
  Public Class Program
    Shared D1 As New OutputPort(Pins.GPIO_PIN_D1, False)
    Shared Button As New InputPort(Pins.ONBOARD_SW1, False, Port.ResistorMode.Disabled)

    Public Shared Sub Main()
      While True
	D1.Write(Button.Read())
      End While
    End Sub
  End Class
End Namespace
Good Luck,
Chuck



#37975 Grove-Base Shield and Relay Netduino Plus/Arduino

Posted by carb on 25 October 2012 - 10:05 PM in Netduino Plus 2 (and Netduino Plus 1)

Developing relay that is controlled via buttons on website. I notice that relay was ON for Netduino Plus board and it was off for the ardiuno (EtherTen). I am using a Grove Relay that plugs into the Grove-Base shield. Apparently the Netduino Plust I/O pins set to high (3.3V) is there a way to set them to low(turn them off)?

Aberkley,

How do you have the initial pin state? Is it set to false.

Dim led As New OutputPort(Pins.GPIO_PIN_D5, False)

That is for Visual Basic but it similar for C#.

The Netduino may boot with the pin positive but once booted should go to the initial state very quickly. If it doesn't you may be able to add a pull down resistor.

By the way welcome to the forum.

Chuck



#37949 Netduino + hangs while calling time using NTP service

Posted by carb on 25 October 2012 - 02:57 AM in Netduino Plus 2 (and Netduino Plus 1)

Skarphedinnos, It didn't find any problems in the code, but it looks like baxter may have you on the right track. It will try it on my ND+ and computer tommorrow. I normal connect the Netduino to the router via a IOGear WiFi adapter that is ported for access via the internet remotely. It is a GWU627 a are reasonablly priced. Good Luck, Chuck



#37936 Netduino + hangs while calling time using NTP service

Posted by carb on 24 October 2012 - 10:56 PM in Netduino Plus 2 (and Netduino Plus 1)

Skarphedinnos, I am not best person to help on this question, but I might be able to if I had a little more information. For instance having the code to look at would allow someone to verify proper usage and declarations. What classes are you using? Assuming that you are using C# are you using the proper case etc. Please provide more information and I think you will likely get the help that you are looking for. Chuck



#37818 Guidance with a cable testing project

Posted by carb on 23 October 2012 - 12:32 AM in General Discussion

Dick,

Have you seen the multiplexor shied here on the forum it provides 32 IOs using 5 DIO on the Netduino. Multiplexor Shied

Just a thought,
Chuck



#37743 Serial question

Posted by carb on 22 October 2012 - 01:22 AM in Netduino 2 (and Netduino 1)

Perkunas, Its not to soon, I would reccommend just doing a search for "serial" on the forum, you should find some code. In the code look for something like switch or select that changes an integer based variable (I mostly work with visual basic so I may be off for C#). The 5000 & 1000 are just duration of sleep in milliseconds with the 5000 = 5 seconds of delay. If I get time tommorrow and you can't find anything that helps I will look or put something together for you to get you on track. Chuck



#37741 Do we have a light sensor?

Posted by carb on 22 October 2012 - 01:14 AM in General Discussion

Dear all,

I am new to here, please help me.
I need to control a light sensor so when strength of illumination reaches a certain level, it will automatically open a sunroof on a green house.

But I haven't found any light sensor on the Netduino platform.
So could someone help me about where to buy a light sensor and how to integrate it onto the Netduino platform?

Many thanks

Franva,

Welcome to the Netduino Forum.

There are a couple of good sources, Adafruit.com or Sparkfun.com.

Which one you pick may depend on your code skill (SPI interface or simple photocell in a voltage divider network).

Another posibility would to use a temperature sensor also to determine if the roof vent should be opened.

Hope this helps,
Chuck



#37406 New project import error

Posted by carb on 19 October 2012 - 02:54 AM in Visual Basic Support

If anyone viewing this thread could you tell me if you can see the atached file above ?

I could see it fine.

You might try searching for the file netduinoapplication1. Select open directory that contains the file, then open the solution (.sln) file. See if that finds the files that your application needs.

Chuck



#37348 Powering a Netduino and LPD8806 From Batteries

Posted by carb on 17 October 2012 - 09:25 PM in Netduino 2 (and Netduino 1)

I'm in the planning stages of building a robot costume for my son. The project will use an Adafruit LPD8806 of 1 meter length controlled by a Netduino and probably just utilize the pattern from the tutorial. I have a 4 AA battery pack, but I'm not exactly sure what is the correct way to wire this up so that the strip won't burn out and also won't damage the Netduino. Would the recommendation be to use alkaline or rechargeable AA batteries? Should I hook up the batteries to the DC barrel jack and power the light strip power from the Netduino 5v pin?

Thanks!

Nithins,

Do not try to power a 1 meter strip from the Netduino 5 vdc regulator. Per the specs on Adafruit.com that you linked to the strip pulls 120 ma for every 2.5" of length that you are planning on using (with the LEDs on at full brightness). That would be almost 2 amps of current.

You will need a separted power supply of around 2 amps for the strip. Make sure that it a regulated supply. 6 vdc will start to damage the strip.

If you want to power from a battery you will need a regulator and most likely a gel cell or Sealed Lead Acid battery 6 or 12 vdc 4 amp hour or more depending on how bright, color and duration that the LEDs are going to be on before rechaging the battery.

Edited to add link: Tutorial on using batteries to power RGB LED Strip

Hope this helps,
Chuck



#37302 LCD for beginners

Posted by carb on 17 October 2012 - 02:16 AM in Netduino 2 (and Netduino 1)

PShchegolevatykh,

I have used the LCD shield made by Adafruit LCD Shield, the one in the link is a white on blue with 2 lines of 16 character. They also have positive and negative RGB LCDs displays. Both are reasonably priced.

In using the shield I used Stefan's .Net Micro Framework Toolbox Toolbox it has a sample to use the Adafruit shield written in both Visual Basic & C#.

The other reason that I would reccommend this shield is that it only uses 2 IO pins (I2C communiction). This leaves most of the other pins for relays, sensors and switch inputs.

Happy shopping,
Chuck



#37196 Running out of memory

Posted by carb on 14 October 2012 - 11:45 PM in Netduino Plus 2 (and Netduino Plus 1)

Patrick, If Close calls Dispose then you should be able to comment the Dispose out and not see any change in the number of iterations. I saw that you were in Tampa, my house is in Crystal River about 80 miles to the North. I would like to see Tampa or Orlando get a Makers Faire to help increase the interest in Micro Processors like the Netduino. The new Go board has a lot of potential and is growing fast. You may want to restate your question and what you know at this point. Take care, Chuck



#37191 Netduino Plus Pinout Reference

Posted by carb on 14 October 2012 - 10:15 PM in Netduino Plus 2 (and Netduino Plus 1)

I think this is a fantastic idea Chuck, and one I've been aiming at doing for quite some time now. I think I just need to get off my butt and start writing some. I've actually been developing a framework for a tutorial website, but have had so many projects on the go I keep getting distracted.

Steve


Lets see what the others think. May be in Wiki we can add something in both C# and Visual Basic. Stefan's toolbox has helped me a lot for examples on how to do things.

Chuck



#37190 Running out of memory

Posted by carb on 14 October 2012 - 10:09 PM in Netduino Plus 2 (and Netduino Plus 1)

Patrick,

Your beyond my experience level. It is slow on the forum right now, but someone should be on later that can help.

One question that I had was wouldn't you normal close an item before disposing of it?
stOut.Dispose(); 
stOut.Close();
Chuck



#37185 Running out of memory

Posted by carb on 14 October 2012 - 09:17 PM in Netduino Plus 2 (and Netduino Plus 1)

Patrick,

I didn't see anything obviously wrong in the code, it could be a garbage collection issue.

I would add a debug.print to show available memory and cycle through a few times to see if you are indeed using up the memory.

If so move the debug.print to find out where. See this post Determining Available memory
Chuck



#37140 Newbie External Device Power Question

Posted by carb on 14 October 2012 - 12:39 AM in Netduino 2 (and Netduino 1)

Alright I will preface this with stating that I am completely new at this. It has been 10 years since my last Circuit Design and Digital Hardware class and most of that information has left my brain. So if the answer to my question is a recommendation to read a specific book that will work as well :)

My goal is to hook an electromagnet to a netduino. I'm looking at this one http://www.amazon.co...=A1THAZDOWP300U

and I'm not really sure how to tell if the netduino can power this.

I'm guessing from these specs the answer is no:
Rated Voltage : DC 24V;Current : 0.48A
Power : 1.2W;Attraction : 9000gf

but I'm just not 100% sure what to be looking for, I know basic electronics fail :)

Thank you for any help you can provide!

Ryan,

The Netduino can not power the coil, but you can control a relay or transistor with the Netduino and thereby control the coil.

Just out of curiosity are you going to be using the coil on a valve or to pick stuff up? The reason I ask is the coil appears to be made to work with a valve. It does not appear to have a pole piece that will direct the magnetic flux to the end of the coil for lifting objects. The magnetic field will be strongest inside the coil.

By the way welcome to the forum. Search for relays in the forum and you should find some information and code that will help you get started.

If you need additional help, please ask and provide as much information as you can about what you are trying to do. Often you will get a reply fairly quick, but please remember that most on the forum are not payed (may take some time to put an answer together for you) and a fair number live in Europe so your answers may appear in the early morning here in the North America.

Hope this helps,
Chuck



#37138 Netduino Plus Pinout Reference

Posted by carb on 13 October 2012 - 10:35 PM in Netduino Plus 2 (and Netduino Plus 1)

Looks good Steve, I was thinking it would be nice to come up with a quick reference guide with code snippets for using Inputs, Outputs, Interrupts, Debug Statements, Buffers, Threading, Try / Catch, Arrays, Serial Ports, PWM, SPI, I2C and a few others. It might help some that are just starting with Net Micro Framework. But no SUX sockets. Chuck



#37063 simple wiring question

Posted by carb on 12 October 2012 - 12:34 AM in Netduino 2 (and Netduino 1)

Since most of your programing is in visual basic.
I got a question for you since I have never tried netduino with VB so here goes.
years ago I wrote a program in vb it was a simple text editor that worked with an arduino program.
All it did was change the variables graphically and with a push of a button uploaded the program.
Was hoping to do something similar with the netduino but C# makes it almost impossible to do, there is no simple up loader.
Nothing graphical built in, maybe the VB netduino version is better.

Stefan may be able to answer that better than I can. From what I have seen VB & C# have similar capabilities. I am not aware of any way to graphically change the variables.

Some are working on a graphical interface that produce a deployable program. Two come to mind, Bender has a project that he is working on that generates a console for controlling servos and the likes. Mario is also working on some things that have great potential to help some of the non programmer types.

The best thing about the 2 projects is it looks like they can maybe be used together.

When I start a project I have been trying to get a working version in both VB & C#, if nothing else I will use a converter to convert from VB to C#.

Chuck



#37061 simple wiring question

Posted by carb on 11 October 2012 - 11:56 PM in Netduino 2 (and Netduino 1)

No problem, glad I could at least get you on the right path. Most of my programing is actually in VBA (visual basic for applications) I am trying to learn VB & C# still. Chuck



#37059 simple wiring question

Posted by carb on 11 October 2012 - 11:16 PM in Netduino 2 (and Netduino 1)

Perkunas,

It may be a simple wiring question, but the code isn't easy. I am better with Visual Basic. Even when I converted it to VB I wasn't used to using that many threads.

Anyway I think the problem could be that you are using an Analog input instead of a digital input (I know yoy are short on DIOs). If you use an Analog input you would want the input to evaluate against a value 0.0 to 1.0

You have
while (anyinputfor6.Read() == true && method_state_6 == true)
Try changing to something like
while (anyinputfor6.Read() <= 0.5 && method_state_6 == true)
In other word if anyinputfor6 is less than or equal to 0.5 it would evaluate as true (ie. the switch is closed).

Hope that helps,
Chuck




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.