background preloader

Projects, Tutorials

Facebook Twitter

Cheap Arduino Wireless Communications. I was looking for a way to handle wireless communications between two Arduino boards. Other options like Xbee or Bluetooth were going to cost $50 to over $100. Then I found a cheap RF transmitter and receiver at Sparkfun. The total cost is only $9! Here are a few limitations to RF solution: Communications is only one way. The advantages are that it is cheap and it is pretty easy to use. Below are some images showing how I hooked up the receiver and transmitter to two different Arduino boards. Here’s a picture of the my actual bread boarded circuit. Since the receiver is constantly picking up random noise I add a few extra bytes to every data packet. I broke the Arduino code into two files. I did all of my initial testing without any of these improvement and everything worked fine with these devices inside the same room.

Add an antenna. I got a lot of help from the transmitter/receiver data sheets, and from this article. I’ll mention an even cheaper idea I had while doing this. Permalink. Arduino Tutorial - Lesson 5. We've done a lot so far, blinking lights, printing messages...all of that stuff is output: signals coming from the Arduino. The next step is to start playing with input, with the Arduino responding to outside events. In this lesson we will begin with the most basic kind of input, a push-button switch! You're probably familiar with switches, there's tons of them in your house. One kind of switch you use every day is a light switch. A light switch is a simple device with two positions, on and off.

When on, two wires are connected inside, which allows current to flow. When off, the two wires are disconnected. On the left, the switch is open and no current flows. (thanks wikipedia!) In this photo, you can see the internals of a light switch. Light switches are great but we need something smaller. These little switches are a 1/4" on each side, cost about 25 cents, and can plug directly into a breadboard. Find 5 things around the house that have switches. Switch capability Fig 5.2 Valid inputs. DIY Projects, Inspiration, How-tos, Hacks, Mods & More @ Makezine.com - Tweak Technology to Your Will.

The format of this book is very different from the regular O'Reilly books. It is written by a geek for geeks. So it doesn't start with a smooth introduction about the basics. It seems to have a rocky start since a lot of assumptions is made about the reader. The diagrams also seem to be hand-drawn on napkins. Chapter 4 really rocks. Overall the book is excellent for getting started with Arduino. Labs / DC Motor Control Using an H-Bridge. Overview In this tutorial, you'll learn how to control a DC motor's direction using an H-bridge. To reverse a DC motor, you need to be able to reverse the direction of the current in the motor. The easiest way to do this is using an H-bridge circuit. There are many different models and brands of H-Bridge.

This tutorial uses one of the most basic, a Texas Instruments L293NE or a Texas Instruments SN754410. If you simply want to turn a motor on and off, and don't need to reverse it, for example if you're controlling a fan, try the tutorial on controlling high current loads with transistors. (:toc Table of Contents:) Parts For this lab you'll need: Solderless breadboard 22-AWG hookup wire Arduino Microcontroller module Light Emiting Diodes, LED 10Kohm resistors Switch L293NE or SN754410 H-bridge 12V DC power supply DC Motor Prepare the breadboard Connect power and ground on the breadboard to power and ground from the microcontroller.

(Diagram made with Fritzing) Add a Digital Input (a switch) Find a motor. Arduino Tutorial: An Introductory Guide. Update! Don’t miss our famous article: Top 40 Arduino Projects of the Web. Previously we introduced you to the Arduino and it’s awe-inspiring incredibleness. Now we’ll take you on an in depth plunge with enough resources and projects to keep you occupied for the next decade. The best place to get started would definitely be their comprehensive website. I strongly encourage you to browse their resources. They have vast tutorial, learning, hacking and reference sections. Arduino Tutorials: As usual, Instructables has plenty of tutorials also.If you’ve ever thought, “Can the arduino do…?” The Arduino uses the ATmega168. Martijn Thé – iPhone & iPad Development & Interaction Design » Interfacing an optical mouse sensor to your Arduino. In this tutorial I’ll describe how you can connect the optical sensor inside a cheap mouse to your Arduino and have it read out the x- and y-movements.

This will enable your Arduino to handle mouse input, detect surface movements, measure surface speed, etc. Materials This is what you need: Arduino board (any *duino will do) and the Arduino IDE.Optical mouse containing the PAN3101, ADNS-2610, ADNS-2083 or ADNS-2051 optical sensor. These sensors come in many mice sold today. Step 1 – Open up your mouse! The optical sensor and LED were covered with the black protective cap. Step 2 –Take a look at the datasheets Check out the datasheet of the sensor you’re dealing with (Google).We only need to connect 4 pins of the sensor to the Arduino, of which two are used for data and two for the power supply.

Step 3 – Cutting the controller wires (optional) To make sure the mouse’s own controller does not interfere with the Arduino, I had cut the SDIO and SCLK wires running to the chip in the mouse. Arduino-Python 4-Axis Servo Control | Principia Labs. Tutorials / Using a transistor to control high current loads with an Arduino. In this tutorial, you'll learn how to control a high-current DC load such as a DC motor or an incandescent light from a microcontroller.

(:toc Table of Contents:) Parts You will need the following parts for this tutorial. Solderless breadboard 22-AWG hookup wire Arduino Microcontroller module 10Kohm potentiometer power diodes (for DC Motor version only) DC power supply TIP120 transistor DC Motor - or - Incandescent lamp and socket (Diagram made with Fritzing) Add a potentiometer Connect a potentiometer to analog in pin 0 of the module: Connect a transistor to the microcontroller The transistor allows you to control a circuit that's carrying higher current and voltage from the microcontroller. Pinout of a TIP-120 transistor, from left to right: base, collector, emitter. Note: you can also use an IRF510 or IRF520 MOSFET transistor for this. The schematic symbol of an NPN transistor where B is the base, C is the collector, and E is the emitter. click the image to enlarge Connect a motor and power supply Notes.

Arduino Tutorial - connecting a parallel LCD. Using Relays with Arduino – Turning on the Lights. Warning!!! This project deals with AC electricity which is dangerous if you don’t know how to treat it safely. You must treat electricity with caution. There are many books and websites about electrical safety procedures and if you’re not sure how to be safe you should read that information. The most basic advice I can give is always assume any exposed wires are live and touching them will hurt a lot at best and kill at worst. Microcontrollers are good at controlling small devices, but frequently we DIY-ers want to use them to control things that aren’t so micro. The first thing you need is a cheap extension core that you are willing to cut in half. I spliced the relay into the black wire on my power cord. The last step and the one that makes this project useful is getting the microcontroller to control this relay.

In this circuit the transistor acts as a switch and it allows you to turn on the relay. Credits. Arduino Interrupts. Often when working on microcontroller projects you need a background function to run at regular intervals. This is often done by setting up a hardware timer to generate an interrupt. The interrupt triggers an Interrupt Service Routine (ISR) to handle the periodic interrupt. In this article I describe setting up the 8-Bit Timer2 to generate interrupts on an Arduino ATMega168.

I walk through steps required for setup and inside the ISR function. If you are following the Arduino sound articles this one will be important to read as well. The Arduino default processor is an ATMega168 (datasheet link). Interrupts? Interrupts Links When a new character arrives the UART system generates an interrupt. If you have lots of interrupts firing or fast timer interrupts your main code will execute slower because the microcontroller is spreading it’s processing time between your main code and all the ISR functions.

With an interrupt you don’t have to keep checking to see if a character has arrived. Arduino Tutorial - Learn electronics and microcontrollers using Arduino! So, I get two or three emails a day, all basically asking the same thing: "Where can I learn about electronics? " In general, most of these people have seen some of my projects and want to be able to build similar things. Unfortunately, I have never been able to point them to a good site that really takes the reader through a solid introduction to microcontrollers and basic electronics. I designed this tutorial course to accompany the Arduino starter pack sold at the Adafruit webshop. The pack contains all the components you need (minus any tools) for the lessons Follow these lessons for happiness and prosperity.

Lesson 0 Pre-flight check...Is your Arduino and computer ready? Here are some recommended tools: If you need to get any soldering done, you may also want.... All of the content in the Arduino Tutorial is CC 2.5 Share-Alike Attrib. Love it? To some extent, the structure of the material borrows from: The impressively good "What's a microcontroller? " A Multi-Protocol Infrared Remote Library for the Arduino.

Do you want to control your Arduino with an IR remote? Do you want to use your Arduino to control your stereo or other devices? This IR remote library lets you both send and receive IR remote codes in multiple protocols. It supports NEC, Sony SIRC, Philips RC5, Philips RC6, and raw protocols. If you want additional protocols, they are straightforward to add.

The library can even be used to record codes from your remote and re-transmit them, as a minimal universal remote. To use the library, download from github and follow the installation instructions in the readme. How to send This infrared remote library consists of two parts: IRsend transmits IR remote packets, while IRrecv receives and decodes an IR message. #include <IRremote.h> IRsend irsend; void setup() { Serial.begin(9600); } void loop() { if (Serial.read() ! This sketch sends a Sony TV power on/off code whenever a character is sent to the serial port, allowing the Arduino to turn the TV on or off. How to receive Hardware setup. The World Famous Index of Arduino & Freeduino Knowledge. Spooky Projects – Introduction to Microcontrollers with Arduino.

Arduino Diecimila / Burning the Bootloader without AVR-Writer. Online | Arduino. My older son recently started school and needed his own desk for doing homework. I wanted to make something nicer than a simple tabletop with legs, and realized that I could also build in a bit of fun for when the homework is finished. Both my boys and I still had space travel on our minds from our summer trip to Kennedy Space Center. For this desk project, I decided to go with a NASA theme. I researched the Apollo Program as well as NASA's Mission Control Center, and designed my own console roughly based on those. I say "roughly" because the actual Mission Control does more monitoring than controlling, and isn't awash in the whiz-bang rocket noises young kids appreciate.

I took great liberties and made more of a "space-themed" play console than an accurate simulator. The desk resides under my son's loft bed (which I also built), and stays closed until the homework is finished: When playtime begins, the lid flips up to reveal the Mission Control console: Arduino Tutorials. Top 40 Arduino Projects of the Web.