Showing posts with label attiny. Show all posts
Showing posts with label attiny. Show all posts

Dec 23, 2012

LEGOtiny

After my last Mini RC Car project I knew I wanted to make a smaller better one.  Some months later and this is the result:


The reason why this one is in a LEGO body is because of this question on LEGO Stack Exchange where it was asked if it was possible to power the small LEGO City wheels.  At that point I had already started playing with micro DC motors and I also started using the ATtiny chip.  This was a perfect storm.  I had to build a super small LEGO vehicle.

Here are all the parts needed to make this build:


  • Set of gears from a race track car
  • LEGO wheels set
  • LEGO brick 2x2
  • Micro motor
  • 0.1uf capacitor
  • Transistor
  • Diode
  • ATtiny
  • Socket
  • Power adaptor
I'll go over the small details in an Instructables ASAP.  For now here's shot from the inside:


Here's a video where I show the final result:





Dec 18, 2012

Jumping on board

Here his a 'how-to' for running two low voltage (3.3V) micro controllers on a breadboard.

The first one is the chip(s) used with the TI LaunchPad. I've tested this setup with the MSP430G2211 and the MSP430G2231. The chip will run at 3.3V and is rated up to 3.6V.


This setup needs a 100nf capacitor between pins 1 and 14, then pin 10 needs to be connected to positive using a 47k resistor.  I use the LaunchPad board to program the chip before transferring it to the breadboard and this is pure laziness since there must be a way to program it in place.




The second one is the ATtiny (in this case the Attiny13) which can run the same code as the Arduino (ATmega328) and can be programmed using the Arduino IDE and uploaded using the Arduino board as an ISP for ATtiny.  You will find all kind  of help online for using the ATtiny13, ATtiny45, ATtiny85, ATtiny44 or ATtiny84.


The chip will run at 3.3V or 5V.  As you can see by this diagram, this is the most simple one to use.  No crystal and no resistor are necessary for running it.


May 30, 2012

Mini RC Car - Part 5 (final)


After weeks of 'other things', here is the 5th and final post on the Mini RC Car project.


It's alive!!!

This final configuration works on a single 9v battery. Yes only one power supply because I found the real source of the noise problem coming from the DC motor. Like any good bug it was a code 12 since I assumed that the motor had a capacitor on it... NOT!  Here you can "see" the result.




Parts:
1x racetrack toy car
1x micro servo
1x 9v battery
1x 5v power regulator
1x pn2222 transistor
1x 1N4001 rectifier diode
4x ceramic 0.1uf capacitors
1x 16MHz crystal
1x 28 pin socket
1x 4 pins female headers
1x 3 pins male headers
1 9v snap connector
1 Atmega328
1 BlueSmirf bluetooth breakout board
1 PCB
1 Wires
scrap metal/wood for structure

Tools:
Dremel
Soldering iron
Hot glue gun
Arduino board (e.g. UNO) for programming the chip
Android device with bluetooth


For the maniacs out there I'll probably add this on Instructables where I'll go over all the geeky details.

To view the whole project go here.

Thanks for reading.

Feb 21, 2012

Mini RC Car - Part 4

Back on track with 5v...continuing the Mini RC Car build.

So I couldn't wait on my 3.3v voltage regulator.  I decided to switch the car to 5v and use a good old 9v battery.  This is what it looked like when I tested the new power system:


This has to be the ugliest RC car ever made.

After getting over the look of the beast, I now have to do the following:

  • Test the servo
  • Clean up the electronics (there is still some quick prototyping part or assembly)
  • Make a more permanent stack assembly for the battery, power regulator and circuit board.
  • Programme the Arduino and the Android phone (remote)

This shouldn't be too long.  Here's the car running a test with the new power system:



To view the whole project, go here

Feb 14, 2012

Mini RC Car - Part 3

A few bumps in the road...continuing the Mini RC Car build.


First I decided to get rid of the variable voltage regulator.  It was causing all kinds of problems mostly because I'm using a 3.7v power source.  Anyway the Arduino runs fine for now and I have some 3.3v regulators coming through mail pretty soon.

A glitch never comes alone but I'm lucky since the next problem was simple. The DC motor is creating noise feedbacks that are confusing the servo.  That one is an easy fix by adding a 0.1uf capacitor on the motor.

The third one is a show stopper. Or maybe I should say 'a show slower'.  The cellphone battery I'm using is not strong enough for this whole operation.  It's a 3.7v 850ma LiPo cell.  I have to power the Arduino, the BlueSmirf Bluetooth board, the servo and the DC motor which is done using a transistor.  I guess I should have done some calculations first.

Soooo, I'll get to that and I'll order the right battery.  Until then, PAUSE on this project.   Mmmmm, that gives me an opportunity to start another thing.  Muha ha ha ha ha

To view the whole project, go here

Feb 11, 2012

Mini RC Car - Part 2

...continuing the Mini RC Car build.

To attach the steering servo, I drilled holes in the frame and bolted the two together.


I then hot-glued the front frame to the rear half, making sure I had enough ground clearance and all 4 tires on the ground.

The next step was creating a board that would support the Arduino chip, a socket for the bluetooth breakout board, the 3.3v voltage regulator and a socket for the servo connector.  Here's the prototype:


After a bit of soldering, here what I have so far:


Now that I have all the main components, I'll do the final assembly and start programming the on-board Arduino code and the Android controller app.

To view the whole project, go here

Feb 9, 2012

Mini RC Car - Part 1

While cleaning up the basement, we came up on that old electric racetrack and finally decided to get rid of that thing.  Of course I kept all the electrical circuitry and the kids kept the cars to play with.


Since I needed another project to start to justify not working on all the important stuff, I decide to re-purpose one of those car into a mini RC car that I would control using my Android phone. Communication will be done through bluethooth which I tested earlier.

My first test was to control the motor using an ATtiny13 Micro-controller.  This chip uses the same code as Arduino but has only 8 pins.  I powered the assembly using a LiPo battery from a dead cellphone.


I started by cutting the frame in two and hot glued a micro servo on the front part.


I then used a PC card slot-cover and bended it into a frame that would join the two half.

To view the whole project, go here

Jan 29, 2012

DIY Proto board

With the Arduino board, I'm using the proto shields very often. It all sounds good with the exception that I often have many ongoing projects and only two proto shields. On top of that I would like to start using the ATtiny and not only the Atmega328 and the UNO board is not made for the ATtiny.

The solution? Make my how proto board of course!

I wanted the board to be compact but still contain a mini breadboard so I decided to used one half of a mini breadboard.


To make things convenient, I also wanted to use a ZIF socket to easily change the micro-controller chip(s). Here are all the parts before assembly:


Part list:
1: ZIF socket 28 pin (~$2.95)
2: 8 pin female header (~$0.50 2x)
2: 6 pin female header (~$0.50 2x)
1: 5 pin female header (~$0.50)
1: 4 pin female header (~$0.50)
1: 16MHz Crystal (~$0.95)
1: Mini breadboard (~$3.95)
2: Capacitor Ceramic 0.1uF (~$0.25 2x)
2: Electrolytic Capacitors - 100uF (~$0.35 2x)
1: Voltage Regulator – 5V (~$1.25)
1: 9V Snap Connector (~$1.25)
1: PCB board (~$1.25)
+ some wires for connecting the components.

Total cost: ~$16.0

Here's the final product.


I'm pretty happy with it because it's small, it doesn't need a separate proto shield, I can use it with either 1 Atmega328 or 1-2 ATtiny(s) and the ZIF socket makes things a lot easier when switching chips.