Monday, April 11, 2016

Robot Journal - Pamela

SNACK: confidential / Silent Killer Ninja Android
Okay, my mum was not just robots, but it was kind of stealthy (if the slowness equal stealthiness). In addition, a play of words for snack, tasty treats based on the Android release - in my case, Ice Cream Sandwich. To save you from falling asleep or get munchies, I get off on food and get to the tutorial.
I was told we bonus for every goal has been to create a robot, I went home and lasers, rail guns, and other deadly weapons in an assortment of chemicals dreamed of my fellow co-workers' robot melt. As long as it does not harm a human being, eagerly approve Asimov, okay?


Robot Journal - Pamela
Robot Journal - Pamela
When we found out just short of the destruction of toothpicks to attach the robot for the competition, and it was mentioned that we have to meet some hard, my heart was broken. A 6x6-inch box that will fit our robots and weigh no more than 1.5 pounds had. I kind of weight with my arms limitation was all about how to add?
It's probably for the best; My advice was not always looked at as weapons, for fear of seeing a little tricky Bots in the arena melt into a puddle of acrylic and metal bits. For the record, the laser can be truly secure, especially when you have a "kill" switch received. All told, the safety of the observers, if I go this route is allowed to fight everyone there would have been necessary for the goggles.

Step 1: Planning and Design
Our free time was given six months to build a robot. Holiday, free day, and they need help with the project at the last minute after a six-month rapid influx of college students in a panic, caffeine, and reduced down to a few weeks full of Jamba Juice.

I decided early on that I wanted to be a robot ninja-themed, and that I wanted to control it with an Android device via Bluetooth. The easiest way to accomplish this is with IOIO was awesome. I drive my robot decided to go with the four large servos, and for my ninja theme, I can control the spinning ninja stars with plenty of torque to the servos. In addition, I have a quick opening of the CO2 valve, the quick, to inflate bicycle tires along with some CO2 from compressed got intended. CO2 from the smoke and shrapnel bombs that ninajadera theme (usually made of iron or ceramics) went along with what was known to use release. Then, the compressed CO2 released quickly enough to cool the surrounding air and moisture condensation will need to create a quick mist. This is needed to open up a lot of ball valves, parts of the list, so I had to add another big server. If one thing was certain, my bot was not to be trifled with torque server combinations, and will require a pretty serious battery.

The final part of my list:
  • IOIO
  • Servos 5 stars
  • 2 medium servos
  • From 16G CO2 cartridge
  • Trek Bicycle quick release valve
  • Transformer Prime running ICS to control my robot
  • 7.4v Lipo battery
  • CO2 valve mounted from Polymorph
  • 1-2 "nylon screw

For me, chassis, I'm a sexy black matte finish, ninja stars and some of acrylic sheets with a mirror finish sorting out, cutting laser cutter. I used to inkaspesa get ready to design laser cut. Inkaspesa an awesome open-source SVG graphics editor. Inkaspesa design files here:

Robot Journal - Pamela
Robot Chassis SVG
Robot Journal - Pamela
Ninja Stars SVG
When it came to weight were a couple of design flaws. After the initial weight, I realized I increased my bot drops down to a lean and mean machine to trim the Ninja. I cut out the size of the chassis acrylic and nylon screws and ask you to switch. Another design element that I had covered wires.

SNAK final weight of 1 pound, 7.5 ounces with a full end up being the CO2 cartridge.

Step 2: SNAKE coding
Coding for IOIO was pretty fun. The fastest way to set up with IOIO "IOIO beginner's Software Installation Guide" is to follow. Instead of dark v3.6.2, v3.7.2 I used without any problems. I was basically element of Ice Cream Sandwich SDK and it works great! Later, I switched to Android 2.3.3 SDK so I can run the controller as well as the phone. A toggle button, two seekbars, and an open source library to two joystick, multi-touch graphical user interface code with some minor changes in was very easy. Here are a few links which greatly helped me to develop are:
  • IOIO Wiki.
  • IOIO Lib basics, which went on IOIO activity.
  • IOIO for the PWM output.
Multi Touch sense, the two buttons at the same time, which was helpful when you need to be able to control the Making.
Android reference, which is a great reference for me was the toggle button and seekbar.
If you run into trouble when developing for IOIO, IOIO discussion group for help, I recommend checking out.

I Bluetooth, which was a big relief for me to work more in order code do not need to change anything - I just plug in a Bluetooth dongle, the IOIO Lib library, my tablet, and everything worked just added! And I was coding, ninja stars, I was moving with a moving robot. When I tested the CO2, it is the force behind a substantial amount of work and it was great - hopefully enough to take off some toothpicks.
Here is my code will be available for IOIO

During the war,
My five for fighting, SNAK managed to come out with all his toothpicks untouched. Unfortunately, I rushed to my second revision ninja stars and did not have enough time to put them firmly mounted servos. This led to them coming loose in the arena, and the molten polymorph handy, I use zip tying them to the servos. On top of that, snakes, Sensei, the heat of the battle, which some disorientation (* cough * like driving completely off the platform around the arena again and again) was not caused enough with the training, and the leadership he flipped a couple of times.

Robot Journal - Pamela
Robot Journal - Pamela

En general, mi robot y un asesino estaba en guerra menos de un amante. Es un pequeño robot de la diversión, fue fácil, tuve una gran cantidad de par motor, y fue muy divertido de ver y de control. De CO2 fue divertido, pero no lo uso mucho. Estoy atrapado en una baldosa otros robots embestir, o palillos de dientes para proteger mi vuelo se ha centrado en.
Al final, me IOIO tiene que aprender un poco sobre el desarrollo de un diseño del robot eficiente. Tengo un poco de conocimiento de mi robot de Android da esperanza. Ahora, si me perdonas, Snak unos láseres de alta potencia, armas de riel, o algún tipo de turbina está equipada con.


RC Hobby Controllers and Arduino

Remote Control Arduino
Robots, cars, robot cars, and the sport needs some degree of remote control devices of all sorts. Most of the time, do it yourself, or some other XBee wireless technology to implement this test. Sometimes it is not a bad idea, but it is more often than not driven and somewhat frustrating way to see more from them. If you find yourself thinking, "I just put the stick RC car battery to push and move it, I remember the good old days."


Well, welcome back to the good old days.
RC transmitter / receiver combos, easy and cheap to seriously tricked out of the range, but the nice thing about them is that they are a standard, all of the staff makes them essentially interchangeable. It turns out that an RC receiver to connect your Arduino project is the same as connecting to a server, and as easy to code. In this tutorial, I will use your Arduino to interpret commands from a remote base in the RC will be, so you can control some of your favorite processed sketch of a simple four-wheeled robot!

That sounds great, but I've never touched an RC transmitter ...
It's no big deal, I'll walk you through it. Radio control transmitter and receiver, usually the model is used to drive a car or plane. A typical transmitter of control surfaces, wheels or joystick, as well as some would like a switch or dial. Each degree of freedom that the controller is assigned to a channel. In other words, since a joystick or a dial switch will cover one of the two channels (x and y) across. RC transmitter is usually somewhere between four and six of these channels.

Since most of the models of RC servos can be generalized as a fancy box, that's exactly what the receiver is set up to control. Server header in a row: they come in different shapes and sizes, they all share a common feature. These headers are lined up so that the servos in your model can be plugged directly into the receiver. Arduino, because it is the "Server Language" and explains how it can decide to use this handy you can plug in the receiver.

Let's Hook it up!
OK, that's the spirit! We have to get a feel for what looks like a transmitter input from the RC receiver will hook up a few channels. RC transmitter / receiver pair have six channels, but we'll just hook up three. We need these three digital input pins, as well as the receiver, it means the ability to 5V. Here's how I have mine hooked up to a diagram:
RC Hobby Controllers and Arduino
RC Hobby Controllers and Arduino
Note that the RC receiver upside-down, it's easy for me to flip my doll to trace. You can use the male-female jumper if you need to have them. If not, you get stuck with some men and women can use the jumper. I chose the digital pins that are pretty much arbitrary; Arduino that you want to use any of the digital inputs should be able to, but should correspond to the bottom of the code.

Now, upload a sketch and see the pins coming in. "Server" is the language that is really pushing out the RC receiver PWM, or pulse width modulation. Arduino is a convenient function to read the pulse and there is built-in to return to their length in milliseconds. PulseIn This function is called (). A simple sketch that I've written to print the serial input of the monitor receiver provisional Let's take a look at:


     
/*
 RC PulseIn Serial Read out
 By: Nick Poole
 SparkFun Electronics
 Date: 5
 License: CC-BY SA 3.0 - Creative commons share-alike 3.0
 use this code however you'd like, just keep this license and
 attribute. Let me know if you make hugely, awesome, great changes.
 */
 
int ch1; // Here's where we'll keep our channel values
int ch2;
int ch3;

void setup() {

  pinMode(5, INPUT); // Set our input pins as such
  pinMode(6, INPUT);
  pinMode(7, INPUT);

  Serial.begin(9600); // Pour a bowl of Serial

}

void loop() {

  ch1 = pulseIn(5, HIGH, 25000); // Read the pulse width of
  ch2 = pulseIn(6, HIGH, 25000); // each channel
  ch3 = pulseIn(7, HIGH, 25000);

  Serial.print("Channel 1:"); // Print the value of
  Serial.println(ch1); // each channel

  Serial.print("Channel 2:");
  Serial.println(ch2);

  Serial.print("Channel 3:");
  Serial.println(ch3);

  delay(100); // I put this here just to make the terminal
              // window happier
}


PulseIn () function takes three arguments: the first pin that is on your pulse; What you're looking for is a kind of second pulse; And the third is a time-out number, which is how long you're willing to wait for a pulse. What is the function of microsecond pulse length, and the way we read the incoming PWM as if we were going to a server. When you run this code, you should be spitting out onto some of the terminals. Perhaps you mean you do not have a lot of numbers, but they should be somewhere between 1000 and 2000 the number associated with what is really important is that when you move the control surface, it should not be changed. If you do not know what channels are in every part of the transmitter, this is a good way to find out: Just stick, push buttons, knobs to turn and flip the switch, and the swung note, which channels are affected.

Now we have these standards, we can work with them and all kinds of codes. This is my sketch after sketch below pulseIn () in the context of the changing values.

     
/*
 RC PulseIn Joystick
 By: Nick Poole
 SparkFun Electronics
 Date: 5
 License: CC-BY SA 3.0 - Creative commons share-alike 3.0
 use this code however you'd like, just keep this license and
 attribute. Let me know if you make hugely, awesome, great changes.
 */

int ch1; // Here's where we'll keep our channel values
int ch2;
int ch3;

void setup() {

pinMode(5, INPUT); // Set our input pins as such
pinMode(6, INPUT);
pinMode(7, INPUT);

Serial.begin(9600); // Pour a bowl of Serial

}

void loop() {
  
  ch1 = pulseIn(5, HIGH, 25000); // Read the pulse width of
  ch2 = pulseIn(6, HIGH, 25000); // each channel
  ch3 = pulseIn(7, HIGH, 25000);
  
  if(ch1>1000){Serial.println("Left Switch: Engaged");}
  if(ch1<1000){Serial.println("Left Switch: Disengaged");}
  /* I found that Ch1 was my left switch and that it
  floats around 900 in the off position and jumps to 
  around 1100 in the on position */

Serial.print("Right Stick X:"); // Ch3 was x-axis
Serial.println(map(ch3, 1000,2000,-500,500)); // center at 0

Serial.print("Right Stick Y:"); // Ch2 was y-axis
Serial.println(map(ch2, 1000,2000,-500,500)); // center at 0

Serial.println(); //make some room

delay(100);// I put this here just to make the terminal
           // window happier
}


Here you can see that I've figured out my transmitter, which controls channel control surface which, in plain English, and I have a few print statements that have written on the transmitter will be reflected in my work. You can extend the receiver for each channel, with Firmata to replace the sketch and your RC transmitter can control a Processing sketch, but I think I can give a good demonstration of the robot is to drive it around and slap this thing on . So let's get it!

Rig radio receiver robot?
I Ardumoto robot platform chassis and motor driver shield wizard for me to be selected for this project. Since it has only two wheels, differential steering and a good way to show that not everything is easy to mix. The first thing we do prototyping header, which we added to the header shield Ardumoto receiver to create a change in the slope of an impromptu "REMoto" If you're going to play:

RC Hobby Controllers and Arduino
RC Hobby Controllers and Arduino

I made three, six rows, because my six-channel transmitter and receiver, as long as you are running the server header on battery power and ground should not be necessary to connect the header. When you solder in mind that your receiver is going to descend on the upside in this sport, and wire it accordingly. How do you see the picture above, I should be able to visit one of these wired. Land row all together and bridge plug into the ground - and then each signal pin to a digital pin is broken out - with the same power range. This mode is not clear, but it works quite well. The robot chassis is connected with the receiver RC in our changing Ardumoto Shield and what looks like:

RC Hobby Controllers and Arduino
RC Hobby Controllers and Arduino

Not bad, right? It's almost time to drive these things because you are sure that the motor is connected properly and make sure to add a power supply (9V battery good for me). Just step left-right-left motor commands / steering commands to the server to translate is to write some code. I now give you code, and it'll explain below.


     
/*
 RC PulseIn Joystick Servo Control
 By: Nick Poole
 SparkFun Electronics
 Date: 5
 License: CC-BY SA 3.0 - Creative commons share-alike 3.0
 use this code however you'd like, just keep this license and
 attribute. Let me know if you make hugely, awesome, great changes.
 */

int ch1; // Here's where we'll keep our channel values
int ch2;
int ch3;

int move; // Forward/Back speed
int turn; // Turning Factor

int pwm_a = 3; //PWM control for motor outputs
int pwm_b = 11; //PWM control for motor outputs
int dir_a = 12; //direction control for motor outputs
int dir_b = 13; //direction control for motor outputs

void setup() {

pinMode(5, INPUT); // Set our input pins as such
pinMode(6, INPUT);
pinMode(7, INPUT);

Serial.begin(9600); // Pour a bowl of Serial (for debugging)

  pinMode(pwm_a, OUTPUT); //Set control pins to be outputs
  pinMode(pwm_b, OUTPUT);
  pinMode(dir_a, OUTPUT);
  pinMode(dir_b, OUTPUT);

  analogWrite(pwm_a, 0);
  analogWrite(pwm_b, 0);
}

void loop() {
  
  ch1 = pulseIn(4, HIGH, 25000); // Read the pulse width of
  ch2 = pulseIn(5, HIGH, 25000); // each channel
  ch3 = pulseIn(6, HIGH, 25000);
  /*
  if(ch1>1000){Serial.println("Left Switch: Engaged");}
  if(ch1<1000){Serial.println("Left Switch: Disengaged");}

Serial.print("Right Stick X:");
Serial.println(map(ch3, 1000,2000,-500,500));

Serial.print("Right Stick Y:");
Serial.println(map(ch2, 1000,2000,-500,500));

Serial.println();

delay(100);

clearAndHome();
*/

move = map(ch2, 1000,2000, -500, 500); //center over zero
move = constrain(move, -255, 255); //only pass values whose absolutes are
                                   //valid pwm values

/*What we're doing here is determining whether we want to move
forward or backward*/
if(move>0){digitalWrite(dir_a, 1);digitalWrite(dir_b, 1);};
if(move<0){digitalWrite(dir_a, 0);digitalWrite(dir_b, 0); move=abs(move);};

/*Here we're determining whether a left or a right turn is being 
executed*/
turn = map(ch1,1000,2000,-500,500);
turn = constrain(turn, -255, 255);

/*This is where we do some mixing, by subtracting our "turn" 
variable from the appropriate motor's speed we can execute
a turn in either direction*/
if(turn>0){analogWrite(pwm_b, move-turn); analogWrite(pwm_a, move);};
if(turn<0){turn=abs(turn); analogWrite(pwm_a, move-turn); analogWrite(pwm_b, move);};


Serial.print("move:"); //Serial debugging stuff
Serial.println(move);

Serial.print("turn:"); //Serial debugging stuff
Serial.println(turn);

Serial.print("move-turn:"); //Serial debugging stuff
Serial.println(move-turn);

Serial.println(); //Serial debugging stuff
Serial.println();
Serial.println();

}



OK, let me see if I can explain how the steering was on the sketch. What I've done is basically between -255 and 255 in a number of forward / back direction of my control stick is mapped, the former and the latter representing the full full speed ahead with representing the disadvantaged. Ardumoto slope from the communication, you have to break out of two different numbers: direction and speed. To do that, I check whether my number is positive. If so, I change the direction of 1. Both the motor is negative, then I just 0. I get the absolute value of that number, and I do not have to use it as a basic set of both motor commands for both the PWM value of the motor vehicle. I "The basic PWM value" because it is not actually the two motors, instead of a turn-rate is subtracted from one side gets sent.

It's my turn-rate and apply it to a number of I -255 and 255 control rod side-to-side direction of the map, with the former representing a full turn to the left and right of the latter representing a full roster. And that's the number I have, I know how to apply it to the motor. On the down side of this method is that we want to turn on the motor is slowing. This method is not a zero-turn radius, but it works reasonably well. I check to see whether my number is negative. If so, I turn to the left motor speed-rate minus the absolute value. If positive, the absolute value of the motor speed of the turn-rate minus.

There are obviously other ways to implement the differential steering; With a little more code you can send back the appropriate motor reverse and place. Also, this code does not steer you might expect when driving in reverse. However, this means you should start with radio control robot, and I hope that the next robot project you've been inspired to grab a hobby transmitter!

Sunday, April 10, 2016

Robot Journal - Michelle

Let's make a robot
To defeat the robot is a robot ... Wait, you mean I did not win? Well, it was a nice try anyway.

How will a tiny, 6-inch battle bots are made for the curious, want to know more about the design process, or just want to know why I hate coding, then this tutorial is for you. I am running as a summary of the wheels on the two servos and a stepper with a round bot that there is rotation around a bar. Nothing like building your bot onto a wrecking ball.



Parts List
I'm the one with the maximum torque, which led me full rotation servos start by looking through the motor for the SparkFun (steppers way too heavy to even consider). I like servos because I do not need a motor controller, I just plug it in to them and their work can get my Arduino.

I knew I needed two servos; I had to use Xbee for wireless and Fio decided on, because I like them. I use a really old Fio I had lying around for most of prototyping the new FiOS was not ready until the end, but I ended up using the bots new ATMega32U4 Fio. It's nice to have two UART line to take command, so I still have my Xbee USB cable connection and debugging was over.
Robot Journal - Michelle
Robot Journal - Michelle
Chassis Design
Once I figured out the motor and wheels, I need to figure out how I wanted to design a bot. I knew I wanted a large weight swinging around, so I decided that a circular robot will be the least amount of line snags. Servos and by the time the wheel is taken into account, though, it did not give me much room to make changes to the design.
I have two servos, and an Arduino wheels I have some servers Mike (thanks Mike!) Was borrowed from, so I grabbed inkaspesa and got to work. The first prototype was printed only on paper, and then I took part and made sure fit. At this point I had a fairly finished design team stuff and need for laser printers to print. So I have a piece of cardboard (cardboard so it is easy to squeeze in a bit stiffer lineup) ended up with. Then it was time for acrylic ... I grabbed some screws and everything will fit. But I still need to find a way to mount the servos.
Tim, we have some lying around the mounting bracket is designed for servos recommended that came out of the calipers and a lot of math. Again, cardboard and acrylic and mounted. For the moment the acrylic pieces work well as a top piece. At this point I was a decently put-together bot code to work on it, so it was about time to get to work properly.

Code Part 1
A few years ago I was a small robot from my netbook W, A, S and D to use it for that great work can be controlled, but it did not work so well when I tried to port it to a joystick. A 45 degree angle, etc. What to do? So I decided to write new code. This code got a bit crazy, but it was essentially the idea, device, joystick and a few buttons presses the search angle and velocity (how far out I'm pushing the joystick based on) account, and then push them all the actions and sends out a fairly large number. I do worry about the value of each separately, but then you need to make things a bit better, so I decided against it.

So after playing around a bit, I had a joystick value calculating and mashing them together. But the United Nations will work mashing, and it was mashed together properly? How strange, I would like to know if the joystick, or 45 degrees if the bot just do not like driving? Well, I read in a data-processing script on my bot using Arduino as a decoding function, both numerically and graphically, and then decided to write to the standard display. Processing surprisingly easy to use. It is never used, and I gave it my graphics and an afternoon was able to print some information. int getting a string of serial data from a character array, and then, there was another story, though.

Once I found a bug in processing all of my script, I was able to see the data being sent. But it's still (and this is why I wrote the sketch) was not right. So I went back to the joystick code to see if I could get hard data. I did a bit of tweaking, and remember - you have only one byte, 256 is not a useful number. Now I have to work the joystick code!
Robot Journal - Michelle
Robot Journal - Michelle

More coding
I got the code for processing the work, but I do not want to obey resembling some bots. So I figured since I was a pro processing, and my information is a graphical representation of the code, I have my bot to send a quick program that will help me to want to de-bug. If the picture is similar to the last sketch, it is. But in this case, it reads the standard mouse pointer, and the angle and speed calculation, and can tell if you are hovering over a button. It's definitely there is some error, but it gets the job done; I tested several functions to manipulate the data, and I am able to see the actual values ​​are not.
Robot Journal - Michelle
Robot Journal - Michelle

I hate coding
So I figured I'd start on the arms - I finally driving Bots (business still does not work, at least in front, backwards, left and right) got. Servo or stepper, servers or stepper? Or maybe a DC motor. My original plan was for a move, but they are large, heavy like Overkill. Not to mention that they need to 12V; You can get away with less, but it's not going to 3.7V Lipo. Servos On the other hand, Arduino can cause problems when you are on the (originally more than PWM timer pins) to use them. I started coding, and decided to move on.
Then I remembered that you just can not turn steppers. A step, then another, then another short delay to take the code, tell them. This works great by itself, but not as well as other code that is delayed. On the other hand, I'm not picky about steppers. If a server is just going to turn you in to take a break, that's fine. Basically, I need to move servos my time delay function is to be set up. Work Code - so simple driver solder, batteries, and a breakout board for me to add all parts of the building.

Joystick
Then came joystick. A joystick, a few months ago with a hand cannon that was built into a piece of plastic manufactured from conductive yarn spools. It caught my attention and I decided to turn in a full joystick. I have a thumb joystick, a pro mini, a small battery charger and grabbed a Lilypad Xbee board, it will not fit in the round and the bottom of the well.
Then come crunch time. I like the idea of ​​using the thread spool, but I just did not have time. Not too long ago we had a bunch of boxes Witilt discontinued but are still sitting around. They looked like they would be good to controllers, but hopefully they were not too short. So I have some buttons, LED and mounting hardware for a quick printout of the inkaspesa with mounting holes, and I'd like to try. It works pretty well, so I 110mAh battery, a pro mini, and Xbee Breakout (and Xbee) and I have recently designed a board that was caught in a Lipo charger combines with an FTDI breakout. I LED, buttons, joystick and start welded to each of the board. Let's just say it was a tight fit and I work well with USB port side of the line-up and got a piece, but it adds to the charm.
Robot Journal - Michelle
Robot Journal - Michelle

Robot Journal - Michelle
Robot Journal - Michelle

Rally
Small protoboards your friends. I have two servos, a stepper, a simple driver, two batteries, and the Fio (Xbee connected) there. When I debug your bot's no fun driving all over your desk, and a power LED for that since, wanted to make a separate switch the motor on and off.

Small protoboards and some imagination, I got everything fit. This board can be just as easy to connect components, three of which sounds boring, but it was actually quite nice sets of pads are attached. You need to connect the holes, and you have the ability to share and ground, etc., there are things, the three pads are pretty nice. There's even a convenient mounting hole that I was able to use the server connection is mounted on the board.

I finally got something done and it was time to assemble. This laser cutter took a couple of trips, but rubbing against the top plate is cut and the stepper motor shaft is not. I'm fishing the heaviest weight I-Mart (3/8 oz) and grabbed a couple of them could not find the connected stepper. Everything spun, but just bass fishing line winding around until the end. Before the tournament, I designed some weapons to help spin the weapon.

Everything worked fine until the time when I realized that the competition is just too thin connector, and keep coming off the hand. The next competition will be redesigned before hand. Otherwise, it's about; I am the last minute of acrylic, which is tied standoffs pulling loose from the cable cut to prevent prying claws and arms, but that's about it. I hope you learned something, now it's time to go to your own design. Good luck and have fun!
Robot Journal - Michelle
Robot Journal - Michelle


Robot Journal - Michelle
Robot Journal - Michelle




Saturday, April 9, 2016

SparkFun Ethernet Shield Quickstart Guide

Network / Internet connection SparkFun Arduino Ethernet Shield and equipped with powerful Ethernet use the library!
SparkFun Ethernet Shield Quickstart Guide
SparkFun Ethernet Shield Quickstart Guide
In this tutorial, we cover how to get up and running with SparkFun Ethernet Shield. Requirements, hardware, assembly, and all programming will be covered. Follow along, and your Arduino Twitter skimming and hosting web pages should be no time!

Necessity
In addition to the slope, you get the most from SparkFun Shield Ethernet will be a few more bits and pieces:

Header (and soldering tools)
Heading for your Arduino is a solid, providing electrical connection with the shield. If you've got a few options when it comes to headers, but most of the slope I recommend stacking headers. This means you dolls, or even other shield, plug in the unused pins to Arduino.
SparkFun Ethernet Shield Quickstart Guide
SparkFun Ethernet Shield Quickstart Guide
You will need to solder the slopes of the header. So, if you are not one already, I have a good, inexpensive soldering iron, solder, and not want to say anything. If a stand is not hurt, and it can save your carpet. (More on this in the assembly section).

Another Ethernet cable
The Shield your Ethernet RJ45 jack and a router or switch will be in the interface. CAT5, CAT6, really should be doing something with a pair of RJ45 terminations. 1, 3, 5, or 10 feet - in a length that works best for you. Or you can check out the best fit for your own cable!
SparkFun Ethernet Shield Quickstart Guide
SparkFun Ethernet Shield Quickstart Guide
μSD card (optional)
You can quickly find out that the Ethernet-equipped Arduino Arduino sketch will use a big chunk of RAM and flash. If you host Web pages, or if you want to read and store data, instead of an Arduino μSD card is a great way to expand upon the limited memory. 1GB or so of course not - - you do not need a high-capacity card, even though you've got lying around your SD card really should work..
SparkFun Ethernet Shield Quickstart Guide
SparkFun Ethernet Shield Quickstart Guide
Arduino Development Board
Ethernet Shield can work with almost any development platform, it certainly is better suited for Arduino. If you are looking to add an Arduino with this shield, I want to say that rock-solid Arduino Uno. Other Arduinos (Mega Leonardo, because of) the slope should work with, but a Transmog Shield may require you to move around the pins.
SparkFun Ethernet Shield Quickstart Guide
SparkFun Ethernet Shield Quickstart Guide
Arduino software
No revelations here, you will need to Arduino Arduino IDE program. Fortunately for us, Ethernet library as well as an excellent IDE comes with an SD library. If you do not have the latest version, you can download it from the Arduino downloads page.

Next Part Coming Soon..................


Stepper Motor Quickstart Guide

Stepping up to the Challenge
There are a handful of motorcycles to choose from, and sometimes it's as clear that one will be best suited for your specific application. In this tutorial, we are one of the motors, stepper motor will be discussed, and when it is better to choose on the option of a stepper motor. How do we EasyDriver stepper motor driver board, driver board with one of the simplest around the motor to be used will be discussed.


Stepper Motor Quickstart Guide
Stepper Motor Quickstart Guide
Necessity
Here is a list of recommended items required to follow along:

  • EasyDriver stepper motor driver
  • Small stepper motor
  • breadboard
  • Male-to-male jumper wires
  • Male header to break away - straight
  • Arduino Uno (or similar microcontroller)
  • Soldering iron and accessories
  • 12V power supply (or variable power supply)

How it works
Stepper motor, rather than just spinning in one direction or the other that is different from the regular DC motors, they can spin in very precise increments. Imagine a motor in an RC airplane. Motor rotation direction or the other very quickly. Motor speed can vary the amount of power given to you, but if you can not tell the driver to stop at a certain position. Now imagine a printer. The motor including a printer, there are a lot of moving parts inside. Such a motor, paper feed rollers that act as the ink is printed on a piece of paper as the spinning move. This paper is a proper distance motor to move to the next line and the next line of text or image will be able to be able to print. Another motor of a thread rod that is attached to the rest of the print head moves back. Again, that's one letter after another threaded rod to print an exact amount needs to be moved. This is where the stepper motor will come in handy.

Stepper motor degree (or steps) of an exact amount can move when told to do so. This is a move in the right position and hold in that position, thereby allowing total control of the motor. It is for a very short period of time so that by powering the motor inside the coil. Motor power trade-off you have to keep it all the time position that you desire. We will not go into too much detail, but I'm asking you all the information you can check out the Wikipedia article on stepper motors. All you need to know for now is that of a stepper motor to move, you move it in one direction or another to tell a certain number of steps, and it is to say the speed of the steps in that direction.

There are many varieties, as well as stepper motor driver board with which to control them. The methods described in this tutorial, not to mention the other motor and driver can be used to estimate how use. However, it is always recommended that you consult datasheets and guides specific to the motor and driver model.

How to use it
Here we are, how to assemble and hook up with the firmware upload to the Arduino motor control will be discussed.

Rally
The easiest way is easy for drivers to use a breadboard for easy access onto the header is added to it. Alternatively, you can solder wires straight boards. These instructions assume that you are using breadboard system.

Easy Driver solder directly to the male headers in the first step. Simple drivers of very few pins to be used in this example. However, when the collapse of a breadboard connected to the header pins are soldered to the board for more stability is recommended. This is a simple method, to cut off the desired amount of headers in their appropriate locations breadboard space, the Easy Driver space, and then solder the connections are.
Stepper Motor Quickstart Guide
Stepper Motor Quickstart Guide
Stepper Motor Quickstart Guide
Stepper Motor Quickstart Guide
Stepper Motor Quickstart Guide
Stepper Motor Quickstart Guide



Hook-Up
Once you have all of the header soldered on, it's time to hook up your Arduino easy driver. Using the picture below, all the necessary connections.
Stepper Motor Quickstart Guide

Note: small stepper motor looks different than pictured. It should be part of a 4-pin connector. The 4-pin male header connected to facing upward (see the Assembly picture # 3). Due to the nature of this particular move in both the orientation of the connector, meaning you can hook up the black wire from the left or from left to yellow wire. It will work in both cases. If you are using a different motor, where to go to find out which cable documentation.

Important: stepper motor requires more power than can be supplied by Arduino. In this example, we'll Uno powering a 12V external supply. Note that the power input (M +) EasyDriver Vin pin on the Arduino is connected. This is the same power supply to both the Arduino and will allow the motor with power.

Firmware
Once you have everything set up correctly, you can upload the firmware for Arduino. The following are some very simple example code to get you up and running. There are many online examples, as well as a stepper library included with Arduino IDE. Feel free to play around with the code, change the value to see what happens, and feel free to explore other codes.

Going Forward
Now that you've figured out how to operate the stepper motor in its simplest level, it's time to take the next level. Easy driver and stepper motors in general about the vast amount of information on the web. The next best place to look would be EasyDriver website. In addition, a great tutorial on bildr. Another great resource is the Easy Driver Schematic. Easy Driver curious as to what you do on the other pins are then designed to give you some insight. Lastly, stepper motor involved in my project, Arduino can check out one. It is, I EasyDriver controlled by an X-Y gantry that moves automatically to create a Ouija board to use stepper motors.
Are you well on your way to your next project should be to add to the stepper motor. If you have any questions, comments, or just want to show off your projects, then drop us a line in the comments below. Happy hacking!

Flexiforce Pressure Sensor (25lbs) Quick Start Guide

Role
This is a quick how-to explain everything you need to start using Flexiforce pressure sensors. 25lb version of this example, but the concept is applied to the flex sensors.


Flexiforce Pressure Sensor (25lbs) Quick Start Guide
Flexiforce Pressure Sensor (25lbs) Quick Start Guide

Necessity
Hardware required to follow these guidelines:
  • Arduino Arduino UNO or other compatible boards (eg Pro Micro)
  • Flexiforce Pressure Sensor
  • breadboard
  • M / M jumper wires
  • 1 megohm resistor (resistor kit on our part)


Hardware
Flexiforce pressure sensor is essentially a variable resistor. No pressure is applied, the outer leads of the resistance, probably greater than 10 Mega Ohm (meters can measure more than me) is incredibly large. When pressure is applied, the resistance measured between the leads decreases, until you have reached the maximum pressure for it to become measure. In this case, the pressure is about 25 pounds, and I have pressure sensor measures the current Flexiforce about 50K Ohms maximum amount that you're used to the pressure.

Using a multimeter you can check your sensor range. Only two of the multimeter to measure the resistance of the leads and the meter connected to the set. The strain sensor and watch the changes in resistance value.

Now, let's read the value with an Arduino. To do this, we Flexiforce sensor and a voltage divider circuit with an additional resistor. I have chosen this example because it is 1M ohm Flexiforce about the middle of the dynamic range of the sensor. Many other similar values may work as well.

5V voltage divider to make one side and the other GND. In the middle, where the sensors and prevent Flexiforce connection with a jumper cable to connect the Arduino analog pins. In this case I used to pin A0. Fritzing is a diagram of the setup:

Flexiforce Pressure Sensor
Fritzing Wiring Diagram

* NOTE *: exactly the same as the image sensor Flexiforce sensor, but do not look too close. The Flexiforce sensor has a larger surface area.
Software
Now you have your circuit is wired and ready, it's time to write some very basic Arduino code. This code is almost exactly the same as the example Arduino AnalogReadSerial value. Let's take a look to see what it is doing:

     
// Flexiforce quick start example
// Reads A0 every 100ms and sends voltage value over serial

void setup()
{
  // Start serial at 9600 baud
  Serial.begin(9600);
}

    void loop() 
{
  // Read the input on analog pin 0:
  int sensorValue = analogRead(A0);
  
  // Convert the analog reading (which goes from 0 - 1023) to a voltage (0 - 5V):
  float voltage = sensorValue * (5.0 / 1023.0);
  
  // Print out the value you read:
  Serial.println(voltage);
  
  // Wait 100 milliseconds
  delay(100);
}
 
100ms or 10 times a second code that is only a small loop is infinite. Each pass through the loop, it A0 pin and the corresponding value of the voltage measurement between 0 and 1023. 0 and 1023 indicate that this represents the ground are sitting at A0 5 volts. For other numbers, we are measured by the number of fraction, 5.0 / 1023.0 by multiplying the voltage can think of. We then spit the standard serial port on the back, we can see real-time changes in value.

Go ahead and try. Make sure you have connected the hardware correctly. Arduino program, Arduino open up the serial monitor (make sure it is 9600 baud), and as you change the value of the voltage and clock Flexiforce press release Pressure Sensor.

Conclusion
Now that you know how to use pressure sensors Flexiforce. Believe it or not, here's what you have learned in a variety of analog sensors, which can collect and use the data in the exact same way. Now it's all up to you to use this type of product, but you have to imagine. If you have any other questions or comments, please drop them in the box below. Enjoy!

Mono Audio Amplifier Quickstart Guide

The tiny Texas Instruments TPA2005D1 audio amplifier based on. It is up to 1.4 Watts in an 8-ohm speaker, and you can drive; It will not shake a stadium, but it will provide plenty of volume for your audio projects.



Quick Start

  • Connect your line-level audio inputs only the + and - header.
  • Header - Out + and connect your speaker.
  • 5.5V to + 2.5V and the ability to connect - header. (Yet S (shutdown) pin some connections.)


Send some audio input, and you will hear it on speaker! Sound, not loud enough to hear you buzzing, or you would like to add a volume control, read on.
Mono Audio Amplifier Quickstart Guide
Mono Audio Amplifier Quickstart Guide

How it works
Traditional audio power amplifiers use transistors with a gain of a certain number of analog inputs to produce an analog output. This sounds great, but the areas between transistors on and off to work. Transistors work most efficiently when they are fully switched on or off, and a lot of waste heat as energy when they're in the middle run.

Class-D amplifier radically different. At any moment, the output transistors are fully on or fully off, which is very efficient. This means that the audio is not output, but the truth is, most of it off for low output value (GND) PWM- like a digital waveform for the high output value (VCC) is mostly, and.
Mono Audio Amplifier Quickstart Guide
Mono Audio Amplifier Quickstart Guide
The PWM signal of 250 kHz, which is much higher than the encoded audio frequency (<20 kHz) is the clock. Mechanical devices that are only audio frequency response of the speakers, PWM signal to the frequency of the original audio is filtered by the speaker coil itself. You can hear all the music!

TPA2005D1 datasheet check out if you want to know more about this amplifier.

To use amplifier
Header - IN + and add your input source. Because the input is differential, it technically does not matter which direction you have to connect them, but if you are one of the inputs or the slope of the ground, the line connection - terminal. (If you encounter problems with hum, see tips below).

Header - Out + and connect your speaker. Polarity does not matter if you're using a speaker, but if you will be using multiple speakers, make sure that all of them the same way you avoid the problem of phase wire. The speaker can be 4 or 8 Ohms. Watts into 8 Ohms maximum output amplifier is 1.4. This small-wattage speakers with amplifier can drive, but you do not turn up the volume too high to avoid damage to the speaker should be careful. You can also decrease the volume of the speakers can drive greater than 1.4W. In general, the speakers sound much better than smaller speakers; We've had great fortune with old automotive speaker.

Pins - + Connect a power source. 5.5V to 2.5V power source may be a source of at least 280 milliamps, and you should be able to get the maximum volume. The red LED will illuminate when the board is powered up..

Apply an audio signal input, and you should be able to hear the speaker. To change the volume, change the volume of the source signal, or a board (instructions below), add a volume control potentiometer.

Adding a volume control knob
If you want, you can easily add this board is a 10K potentiometer to control volume. You can control the volume from 0% to 100% reduction of the input signal will allow you to control the volume. Note that the amplifier will not be any loud - you can do it if you want to see change in the gain resistors. Here's how to add a volume control potentiometer:

Remove the solder jumper SJ1. On the white board in the bottom right corner of the small blob of solder are in parentheses. The easiest way to do this jumper solder wick application, and it is with your soldering iron is hot. When you're done, to ensure that the two sides are separated electrically from each other.

Now, on the bottom right of the board 10K potentiometer connected to the pad. The following link has been shown to the right of the board silkscreen. With 0.1 "board pins (such as the COM-09806) -spacing directly on, or a chassis you use a cable to connect the board to the potentiometer, etc. You can solder a trimpot

Note: Potentiometers come in two styles: "Linear Candles" and "audio (or logarithmic) taper". Audio Potentiometers a logarithmic taper volume control of the audio like this one in favor of the application is to give a more natural feel, but the linear taper will work just fine.

How to use the shutdown pin
SDN * input when it is being used to stop the amplifier can be used to save energy. SDN * When disconnected, or a high logic signal (> 2V) connected, the amplifier will work normally. SDN * pin to ground or logic signal is low (<0.8V) when connected, amplifier and LED will be closed. You can use this feature to save battery power-driven projects can.

Change the Gain Resistors
Gain amplifier chip, which sets how much the input signal to be amplified using two fixed resistors. 150K resistors that we're using on this board, as recommended by the datasheet for a profit 2. If you want the output to be loud, you can install a small resistor.

The amplifier gain for the equation 2 * (150K / R) is. So if you use a 100K gain resistor, 50K resistor will receive 3 to 6, etc. The datasheet for the smallest value that should be used for a profit of 20 to 15K, but we've gone down to 3K (fair results obtained = 100).

Amplifier board to add your own two positions through the hole resistors. The white rectangle on the keyboard are in. You can just put them over the top of your hole resistors, remove the existing surface mount resistors do not need to. (New resistors in parallel with the surface of the resistance value of the resistor will reduce a little left, but this usually is not a problem).

For best results, the gain resistors should be matched as closely as possible. If you have a bag of identical resistors, all of them with a multimeter to measure the resistance and the earliest that could pick up.

Counsel
The output of the amplifier into a coil (a speaker or a magnetic transducer) is designed to be connected with something. Since the output is not a true analog signal, a preamplifier, etc., should not expect to use this board

The board differential input such as MP3 and MP3 Shield trigger for direct connection to the audio signal, such as a floating ground is not safe.

And amplifier to your audio source (such as audio coming from a desktop computer) is different AC power supply, the output you could hear a loud hum. Audio input side and the ground power supply (PWR - - headers) in order to fix it, a jumper cable connections.

Like a 250 kHz PWM- signal output of the amplifier, it is possible to radiate interference from nearby sensitive circuitry. For this reason, as small as possible to keep the wires between amplifier and speaker.

Questions?
If you have any questions or problems, tell us in the tech support@sparkfun.com and we will do our best to help you. If you're building our part of the project we want to hear about cool!
Rejoice!
- SparkFun your friends at the time.