28BYJ-48 Stepper Motor with ULN2003 driver and Arduino Uno

First, lets see the little steppers in action! Our main character, StepperBot, is “instructed” to move in a square path on my coffee table, making 90 degree turns at the corners. Turning exactly at the right time and by the right angle is critical avoid falling off and crashing on the floor in an embarrassing pile of messy wires.https://www.youtube.com/watch?v=831qjVX6YLA(more…)

Using Bluetooth and an Android phone for debugging Arduino sketches

I bought a Bluetooth module a few months ago and never really tried to use it because in my mind it would be another module that would require hours digging the internet to find libraries, and some code sample to get me started. Only after reading Stan's post about Bluetooth modules I realized how easy is to get them working and how useful they can be to troubleshoot projects that require movement (like robots). Bluetooth basically makes your serial port wireless and open a whole new set of possibilities with two way communication…continue reading →

Programming ATtiny84 / ATTiny44 with Arduino Uno

My order of ATTiny84 chips from Mouser arrived yesterday, so it is time to load the Arduino Blink example sketch onto it. I made a small line follower using the ATTiny85 a while back, and quite liked the idea of having a smaller, cheaper IC that can run simpler Arduino sketches. The ATTiny84 comes with extra 6 I/O pins (see datasheet), so it should be an even better replacement of an Arduino for smaller projects. Here is a beautifully rendered mapping of the ATTiny84 / ATTiny44 pins courtesy of  Alberto (PighiXXX):ATTiny84 ATTiny44 pinout (more…)

Connecting Arduino Uno and the JY-MCU Bluetooth module using SoftwareSerial

My previous post covers the basics of setting up a Bluetooth connection between an Arduino Uno and an Android phone using the JY-MCU Bluetooth module. We connected the  JY-MCU Bluetooth module to the Arduino via a serial connection on (digital) pins 0 (rx) and 1 (tx).This uses Arduino’s built in hardware support for serial communication (via something called UART) and requires no additional libraries. The Arduino has a 64 byte serial buffer and can receive and store data in it, while executing other tasks in your program. For some great examples of using serial communication, as well as wealth of other Arduino related info see Nick Gammon’s web-site.There are a couple of downsides of this set-up for Bluetooth connectivity: (more…)

How to connect an Arduino Uno to an Android phone via Bluetooth

The purpose of this tutorial is to cover the basics of setting up a connection between  Arduino Uno and an Android phone via Bluetooth. Smart phones pack a ton of cool features (camera, accelerators, speakers, microphone, a nice screen to show data from your sensors, wi-fi adaptor...) that will make an excellent addition to a robot, or any other Arduino project. I will use Blueterm a basic free Android terminal emulator app to send a single digit (zero or one) from a phone to a BlueTooth module connected to the Arduino Uno via a serial…continue reading →

Arduino controlled LCD using a shift register and the SPI library

Now that I got my recycled 40x2 character LCD working with Arduino, the next step is to get it to show something useful.  I decided to add it to my Bluetooth Controlled robot  and display data from its two ultrasonic distance sensors (initially). Gradually  more interesting info like battery voltage and wheel encoder data can also be shown, as I get those components working. The problem is that now I need to find another 6 digital pins to control the LCD itself. Fortunately, there is an alternative: add a 74HC595 shift register and take advantage of the Arduino SPI library. Here is how: (more…)

Controlling a 40 x 2 character LCD with Arduino Uno and the LiquidCrystal Library

A couple of days ago I came across a discarded Meridian PBX phone and naturally, took it apart. Among some of the more promising salvaged components was a 40 x 2 character LCD. There was a ribbon cable attached to the LCD with a 14 pin female connector. The pins were helpfully labeled on the front of the panel (from 1 to 14). On the back of the LCD I could see five KS00065B LCD Driver chips.40x2-LCD-HD44780-Arduino-Uno-LiquidCrystal-libraryThe next thing to find out was how to hook this up to my Arduino Uno. (more…)