Sign in to follow this  
Followers 0
Shadowdog1998

Devices and hardware

10 posts in this topic

If you havnt ever heard about it, vex is kinda cool to check out. http://www.vexrobotics.com/ Anyway i do the programming for a school robotics team of mine. These bots have a brain(cpu) that receives its own special programing, its a piece of cake drag and drop a few things and you have 4 motors running, a servo (think of a windshield wiper motor, only goes so far 180 degrees and back) and what ever. What im wondering is how do you program for other hardware. Stuff that is not already set up for idiots. Say I have a controller and I want the computer to receive input from it, or if i have a motor that I want to run at a certain speed for a certain amount of time. I am imagining all the electrical engineering here ^_^ thats not what is getting me, its that I have no clue how you would even go about setting up programs for something like this or if thats even what you would do.

Example: A fan that you want to run at a certain speed, so to get it to this speed you need to control the amount of electricity going to it.

If you can point me in the right direction I will be quite thankful.

Edited by Shadowdog1998
0

Share this post


Link to post
Share on other sites

You can control the fan speed using PWM (Pulse Width Modulation)

By switching voltage to the load with the appropriate duty cycle; the output will approximate a voltage at the desired level. Use an inductor and a capacitor to remove noise!

Or you can use a DAC (Digital to Analog Covertor) to output the correct voltage! but i think you better use the PWM method!

Regards

0

Share this post


Link to post
Share on other sites

  • Learn some basic electronics. Don't be afraid, it's not hard. A good place to start reading is here. You don't need to master this stuff, but you do need a good understanding.
  • Learn how to solder. Assuming you actually want to build projects, you'll need to know how to solder. Again, this isn't hard so don't be afraid! You can get everything you need for soldering for under $20 at radio shack.
  • Build an AVR programmer. You need a "brain" and that would be a microcontroller. The AVR microcontrollers are nice, and you can program them almost directly from a serial port on your computer so the hardware needed to program the chips is very easy to build. This is a nice one. Order this kit (which is really most useful for the PCB) and get started.
  • Buy some AVR chips. These range in size from 8-pin tiny guys with just a few pins for controlling things to huge 40-pin behemoths. They can be programmed in C, assembly or BASIC and are generally more versatile than other microcnotrollers. They're pretty cheap too.

You can get started for under $50 and be programming AVR chips in no time. Once you get the basics down, you're limited by only your imagination.

0

Share this post


Link to post
Share on other sites
You can control the fan speed using PWM (Pulse Width Modulation)

By switching voltage to the load with the appropriate duty cycle; the output will approximate a voltage at the desired level. Use an inductor and a capacitor to remove noise!

Or you can use a DAC (Digital to Analog Covertor) to output the correct voltage! but i think you better use the PWM method!

Regards

i was actualy asking more in general and that was just an example but thanks for that info

0

Share this post


Link to post
Share on other sites
  • Learn some basic electronics. Don't be afraid, it's not hard. A good place to start reading is here. You don't need to master this stuff, but you do need a good understanding.
  • Learn how to solder. Assuming you actually want to build projects, you'll need to know how to solder. Again, this isn't hard so don't be afraid! You can get everything you need for soldering for under $20 at radio shack.
  • Build an AVR programmer. You need a "brain" and that would be a microcontroller. The AVR microcontrollers are nice, and you can program them almost directly from a serial port on your computer so the hardware needed to program the chips is very easy to build. This is a nice one. Order this kit (which is really most useful for the PCB) and get started.
  • Buy some AVR chips. These range in size from 8-pin tiny guys with just a few pins for controlling things to huge 40-pin behemoths. They can be programmed in C, assembly or BASIC and are generally more versatile than other microcnotrollers. They're pretty cheap too.

You can get started for under $50 and be programming AVR chips in no time. Once you get the basics down, you're limited by only your imagination.

thanks, yeh i know a decent bit about electronics and when i need help with that i know the guys to go to

those electronics online books are great

and thanks for pointing me in the right direction now that i know what im looking for "microcontrollers" i might actualy get some where xd

Edited by Shadowdog1998
0

Share this post


Link to post
Share on other sites

Follow this video, it is good.

0

Share this post


Link to post
Share on other sites

I'm doing something the same as that now.

I ended up buying a Parallax Servo Controller and talk to my device via USB/Serial. Then I found a serial library for the language I needed, just add code and attach it to hooks. Voila! There are a few tweaks in the PSC that I don't really care for and it's a little overkill for my needs (in terms of ports.. I got 16 when I only need 2-4...) but it's working!

0

Share this post


Link to post
Share on other sites

The chips are so cheap, there's no harm is getting a larger chip than you need.

As for controlling servos, it's trivial. That thing can control 16 servos but for $40 it's a bit much. You probably could have built the same thing for $5. Controlling a servo is nothing but a variable width pulse you can generate easily with timer/counters.

0

Share this post


Link to post
Share on other sites
lego mindstorm sets.

My school uses these, and they do indeed make building robots quite easy. There are also a variety of programming languages available to use with them instead of the drag and drop programming tool included in the set. I, personally use NQC (Not Quite C), however, C++ and Java are also available to use along with a few others I believe. There are also some very good competitions in my area that schools from many states from across the country come to. (Robofest.net)

Also, I have been trying to get into microcontroller programming lately with something such as a PIC but I must wait for a while as robofest is this weekend and I need to finish programming.

0

Share this post


Link to post
Share on other sites
lego mindstorm sets.

My school uses these, and they do indeed make building robots quite easy. There are also a variety of programming languages available to use with them instead of the drag and drop programming tool included in the set. I, personally use NQC (Not Quite C), however, C++ and Java are also available to use along with a few others I believe. There are also some very good competitions in my area that schools from many states from across the country come to. (Robofest.net)

Also, I have been trying to get into microcontroller programming lately with something such as a PIC but I must wait for a while as robofest is this weekend and I need to finish programming.

trust me check out the vex robot kits, you actualy have the option to drive them via controllers plus building them you have a lot more options

where im at in indiana we have an area robotics competition sponsored by General Electric. Some of there engineers build us a game every year, and then 14 or so schools compete. Students have to build the bot and program it. Each round is 2 minutes long and for the first 30 seconds your bot has to drive on its own in autonomic mode, then 1:30 it can be drove by up to 2 drivers.

http://www.youthbotin.org/

and yeh im in the picture on the main page xd but im not going to tell you which one is me

Edited by Shadowdog1998
0

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0