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

Building a small lego robot


  • Please log in to reply
7 replies to this topic

#1 Stefan W.

Stefan W.

    Advanced Member

  • Members
  • PipPipPip
  • 153 posts

Posted 28 June 2011 - 09:16 PM

Hi,

I'm pretty new to electronics and microcontrollers, and I've gotten a netduino because I wanted to get into this topic, and so after a few starting excercises (like blinking leds, using shift registers with SPI, using LDRs as sensors and so on) I think about setting off to my first "real" project: a small lego robot (built with old parts that I used to play with a long time ago ;)). There are, at this moment, two things unclear to me yet though, so if anybody could clear those up for me that would be great:

  • I'm going to run this robot on batteries, and i'm wondering if directly plugging in a 9v battery to Vin/Ground (maybe with a rectifying diode to prevent wrong polarization) will be fine, or if i need a supply with a regulated voltage (which would probably need a bigger voltage on the battery, which i'd like to avoid - i'm already going to have to use 8 AA batteries to power the motors).
  • In which state are the netduino pins when the netduino turns on? Or, to be more direct: Can I damage the netduino when I connect a pin to the netduinos 3.3V on startup? (If it's going to be used as an input with ResistorMode.PullUp later).

Thanks for your help, and for a great product :)

Stefan
I believe that no discovery of fact, however trivial, can be wholly useless to the race, and that no trumpeting of falsehood, however virtuous in intent, can be anything but vicious.
-- H.L. Mencken, "What I Believe"

#2 Chris Walker

Chris Walker

    Secret Labs Staff

  • Moderators
  • 7767 posts
  • LocationNew York, NY

Posted 28 June 2011 - 09:24 PM

Hi Stefan, You can supply 7.5V-12VDC to the VIN pin, unregulated. A 9V battery will work fine. In fact, we do that frequently with the Netduino Minis. As for startup--the pins are set as inputs with pull-ups enabled by the micro at boot. This may cause attached devices to see a bit of a "logic high" during boot, but you should haven't to worry about damaging the Netduino itself during boot unless you're trying to draw/supply large amounts of current. For your motors and such, your best bet is to use a separate power supply. Chris

#3 Stefan

Stefan

    Moderator

  • Members
  • PipPipPip
  • 1965 posts
  • LocationBreda, the Netherlands

Posted 28 June 2011 - 09:26 PM

Hi Stefan, Welcome to the forums! Connecting a battery to the Vin and Gnd will be fine, as long as it's between 7.5 ans 12V. You can't damage the Netduino if stuff is connected to it on power on. While the Netduino boots, all ports have a bit of current for a second though. Kind regards, Stefan
"Fact that I'm a moderator doesn't make me an expert in things." Stefan, the eternal newb!
My .NETMF projects: .NETMF Toolbox / Gadgeteer Light / Some PCB designs

#4 Stefan W.

Stefan W.

    Advanced Member

  • Members
  • PipPipPip
  • 153 posts

Posted 28 June 2011 - 10:14 PM

Hi Stefan,

You can supply 7.5V-12VDC to the VIN pin, unregulated. A 9V battery will work fine. In fact, we do that frequently with the Netduino Minis.

As for startup--the pins are set as inputs with pull-ups enabled by the micro at boot. This may cause attached devices to see a bit of a "logic high" during boot, but you should haven't to worry about damaging the Netduino itself during boot unless you're trying to draw/supply large amounts of current.

For your motors and such, your best bet is to use a separate power supply.

Chris


Yes, I planned to use a seperate block of batteries for the motors, using an H-Bridge, i got as much from the web. Thanks to you and Stefan for the information!
I believe that no discovery of fact, however trivial, can be wholly useless to the race, and that no trumpeting of falsehood, however virtuous in intent, can be anything but vicious.
-- H.L. Mencken, "What I Believe"

#5 Stefan

Stefan

    Moderator

  • Members
  • PipPipPip
  • 1965 posts
  • LocationBreda, the Netherlands

Posted 29 June 2011 - 07:55 AM

Yes, I planned to use a seperate block of batteries for the motors, using an H-Bridge, i got as much from the web. Thanks to you and Stefan for the information!

I used such a bridge for my robot, see this thread for more. Perhaps the code could be of use for you?
"Fact that I'm a moderator doesn't make me an expert in things." Stefan, the eternal newb!
My .NETMF projects: .NETMF Toolbox / Gadgeteer Light / Some PCB designs

#6 Mario Vernari

Mario Vernari

    Advanced Member

  • Members
  • PipPipPip
  • 1768 posts
  • LocationVenezia, Italia

Posted 29 June 2011 - 05:56 PM

Just a question Stefan W... What kind of motors are you using with the lego? the originals ones? If so, how do you solved the wiring of them (the plain special connectors I mean)? Cheers
Biggest fault of Netduino? It runs by electricity.

#7 Stefan W.

Stefan W.

    Advanced Member

  • Members
  • PipPipPip
  • 153 posts

Posted 03 July 2011 - 12:44 AM

Just a question Stefan W...
What kind of motors are you using with the lego? the originals ones?
If so, how do you solved the wiring of them (the plain special connectors I mean)?
Cheers


I did not yet, but I planned on cutting a lego cable open (i have a damaged one anyway) and soldering it to hookup wire. When i'm done, i'll report on how it worked out - and yes, original lego motors (the ones that i have now are the old ungeared ones, i ordered some newer ones from ebay).
I believe that no discovery of fact, however trivial, can be wholly useless to the race, and that no trumpeting of falsehood, however virtuous in intent, can be anything but vicious.
-- H.L. Mencken, "What I Believe"

#8 Stefan W.

Stefan W.

    Advanced Member

  • Members
  • PipPipPip
  • 153 posts

Posted 03 July 2011 - 12:45 AM

I used such a bridge for my robot, see this thread for more. Perhaps the code could be of use for you?

I'll have a look into it when I run into trouble, but for now this is my learn-as-you-go project - thanks though :)
I believe that no discovery of fact, however trivial, can be wholly useless to the race, and that no trumpeting of falsehood, however virtuous in intent, can be anything but vicious.
-- H.L. Mencken, "What I Believe"




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.