Close

Does this project spark your interest?

Become a member to follow this project and don't miss any updates

Tiny robot family

A family of tiny robots, each with their own way of life.

Similar projects worth following
This project is in this list
Browse all lists »

This project was created on 03/22/2014 and last updated a year ago.

Description
This is my growing family of tiny robots based on ATtiny controllers, pager motors and photo-transistors.
Details

These three little autonomous vehicles have a lot of similarities such as controller, battery and movement mechanism, and they all percieve the world through photo-transistor eyes. But they are all distinct designs with different capabilities and behaviors. They are the first members of a growing family of miniature robots that I have been playing with off and on for a long time


A key aspect of their design is at least one photo-transistor eye and one controlled LED. This allows them to interact in a meaningful way. Depending on how they are programmed, this could be as complex as data transmission between bots or as simple as interfering with the sight of other bots. The resulting interaction would also depend on the type of bots. For example, the eyes of robot 1 point downward to scan the surface, while robot 3 only looks forward.

At this point I have not programmed them for any complex interaction. Their main behavioral features are thus:

  • Robot 1 - Has left and right eyes looking down. Can detect lightness patterns on the ground. Here is a video of it acting as a line follower.
  • Robot 2 - Has one downward eye and one forward. Controlls a group of LEDs around its perimiter. It can see the lightness of the ground and look forward. It can also signal in all directions with the LEDs.
  • Robot 3 - Has one eye looking forward and two separately controlled LEDs pointing about 45 degrees to either side. It is supposed to be able to detect obstacles and determine which direction to turn to avoid them. I am still developing this feature.


The hardware:
The controller could be any of the 8-pin ATtinys. I have used the tiny85 because that's what I had on hand. I have considered a version based on the ATtiny10, but haven't gotten around to that. The batteries are LIR2032 rechargeable lithium coin cells that I pulled out of some solar key chain lights from the 100yen shop(dollar store). They don't last very long between charges, but I'm not planning on spending much money for fancy new batteries.
Here is the underside of each one.


You can see the 2N7002K mosfet transistors for driving the motors. There are also various resistors, capacitors and LEDs. The schematics are here:



The software:
At this point, the software is very simple, but it is easy to add another behavioral pattern in the code since the main loop simply calls a behavior function. Robot 1 has a line following bahavior. Robot 2 scans the ground and can signal to other robots in the area. Robot 3 avoids obstacles(still working on that one). I would be willing to upload the current code if requested, but since it is continually changing and far from complete, I won't put it here just yet.

If I make new robots, videos, changes etc. I will post a log here about it.

Components
  • 1 × ATtiny85 Microprocessors, Microcontrollers, DSPs / ARM, RISC-Based Microcontrollers
  • 2 × 2N7002K MOSFET Discrete Semiconductors / Transistors, MOSFETs, FETs, IGBTs
  • 2 × small motors from andromedabots
  • 1 × some red LEDs
  • 1 × some ASDL-6620 phototransistors
  • 1 × various smd resistors and capacitors see the schematics
  • 1 × LIR2032 3.6V rechargeable battery

Project logs

View all 2 project logs

Discussions

starwriter wrote 2 months ago point

Any chance of getting the code for the other two little robots. ;)

Are you sure? yes | no

alexis wrote 3 months ago point

Neat little robots. Here is a similar project but I dont think its being worked on anymore. 

I think it had line following capability and a basic IR communication between robots.

Schematic, pcb, and code is all available.


They should have been used for testing swarm algorithms but we did not go very far, built a few dozen.


http://warrantyvoidifremoved.com/formica

Are you sure? yes | no

shlonkin wrote 3 months ago point

Thanks for the link. Those are really cool robots. I was trying to get into that field of research a few years ago, but circumstances forced me to quit school and set all my dreams aside. 

Are you sure? yes | no

rylangrayston wrote 3 months ago point

hey I love these little line following bots and I have a few ideas for you that would make for alot of fun with them...
What if you used glow in the dark paper and UV LEDs so that each bot can both draw and follow lines, It would look just like the lines in this video, but the patterns could be some what emergent. 

https://www.youtube.com/watch?v=LnPqw8A4gJQ

I would start out with some code like this:

if (folowingLine == true){

UVLED = 'OFF'

}

else { UVLED = 'ON' 

driveAroundAmlislyLookingForLine();

}

Are you sure? yes | no

shlonkin wrote 3 months ago point

That's actually a really cool idea. Ants behave in a very similar way and I've seen a few simulations based on just that same idea, but I've yet to see a physical experiment that didn't use actual ants. If someone tries it and gets some interesting results, they could publish a paper on it.

Are you sure? yes | no

Mid-Ohio Area Robotics wrote 4 months ago point

These are the cutest little things ever! I really like them, are you going to be having PCBs made for them? You might want to consider Elecrow, with their PCB service I'd imagine you could get PCBs for less than $.7 USD. Nice project! Check mine out if you get the chance :D

Are you sure? yes | no

pepeu wrote 4 months ago point

Hey! Very interesting project! Do you know of a replacement for the ASDL-6620 since they seem to be out of production/stock? 

Are you sure? yes | no

shlonkin wrote 4 months ago point

There are many different phototransistors available. Just look for one that works with visible light and fits your voltage needs. I don't have time now to search for a replacement, but your supplier should have some kind of phototransistor that should work.

Are you sure? yes | no

JJ071992 wrote 5 months ago point

Hey awesome project, i'm gonna try this myself sometime. Is there a reason why you don't have a power switch so you don't have to disconnect the battery everytime? A small dip-switch wouldn't need much extra space.

Are you sure? yes | no

shlonkin wrote 5 months ago point

Hi. Just for simplicity and because I didn't have any really small switches.

Are you sure? yes | no

vsureshkeerthi wrote 6 months ago point

what is the specification of the motor used in this??? 

Are you sure? yes | no

kumkum1kiran wrote 6 months ago point

Hii.... gud work...

Do you Know...It's very funny and an interesting job to build an Art Robot that can do art or drawing with you…a Robot Art!!! Want more information...just check out...

https://www.mepits.com/project/265/Science-Projects/How-to-make-a-Robot-Art,-A-simple-DIY-Art-Robot-!!!

Are you sure? yes | no

Sandeep Kumar Singh wrote 7 months ago point

I want to build it..It cool but when i go through your procedure then i found some codes i just  want to know how to upload it in IC  with arduino... please help me out 

Are you sure? yes | no

Sandeep Kumar Singh wrote 7 months ago point

I join this site today so no idea.. plz

Are you sure? yes | no

Adam Fabio wrote 7 months ago point

Sandeep, the tiny robots run on ATtiny85 processors. Do you have an ISP interface? (That's the easiest way to program them)

Are you sure? yes | no

Sandeep Kumar Singh wrote 7 months ago point

No, In fact i don't know about ISP Interface... Can you tell me how t make.buy it... 

Are you sure? yes | no

rellik1000 wrote 7 months ago point

Love the project.Trying to breadboard #1 before building it,without success
I'm really just a noob,but shouldn't line 34 .ino #define rsensepin 1 //ADC1 pin 7
be...#define rsensepin 2 //ADC1 pin 7

My apologies if i am missing something.

I am using leds in place of motors for testing.I should see a change in leds brightness based on sensor values....correct?

Are you sure? yes | no

shlonkin wrote 7 months ago point

Due to the vary awkward way the ATtiny85 libraries work, if you call analogRead(1), you will get the value from ADC1(pin 7), but any digital function with 1 will use PB1(pin6). So the definition really should be 1 because only analogRead() is ever called.

If you are testing with LEDs, you will only see on or off. The program does not actually change the pwm value.

Are you sure? yes | no

Coye Knoll wrote 8 months ago point

radioshacks zip zaps those tiny remote control carsuse the same types of motors. u can buy like just the motors,

Are you sure? yes | no

Mr. Spriggs wrote 8 months ago point

Hey,

I dug through the data sheet and came up with a low power version. It works just the same as you original but the ATtiny uses less than half the power the original used.

Are you sure? yes | no

shlonkin wrote 8 months ago point

Cool. Are you shutting down parts of the controller between sensor readings? I'm sure the vast majority of the power is consumed by the motors, so the benefit may be small in the end. But don't let that discourage you from tinkering with it!

Are you sure? yes | no

Mr. Spriggs wrote 8 months ago point
Shlonkin,
So after a whole bunch of testing I finally got the tiny robot working. It was so simple I could kick myself. The problem is with the code. The ledon and the ledoff are swapped. When the led should be on like getting sensor data it off.
I replaced the #defines with
#define ledoff PORTB &= ~(1 << 4)
#define ledon PORTB |= (1 << 4)
And now it works great.

Are you sure? yes | no

Mr. Spriggs wrote 9 months ago point
The problem was right there all along I wired the emitter and collector backwards. Thanks for the help.

Are you sure? yes | no

Mr. Spriggs wrote 9 months ago point
Hey Shlonkin,
So I basically built a copy of your first robot. Then dumped the hex onto the 85. I had no luck getting the great results you have on your video. I played with the setting over and over with no luck. Mine seems to see lines that are not there. I even went and added some sleep mode code to minimize the noise when its reading the sensors.
Any insight?

Are you sure? yes | no

shlonkin wrote 9 months ago point
Here is something you could try. Check the sensor voltage directly with a meter while on a white surface then on black. There should be a significant difference in voltage between them, like around half of your battery voltage in difference. This should be true for both sensors. If you have that, then it is likely a software issue. You are running at 8MHz, right? Try the default sensitivity of 3.
If you are not getting sufficient voltage difference, try changing the resistance value in the sensor circuit. It could be too high or too low.

Are you sure? yes | no

Mr. Spriggs wrote 9 months ago point
I built basically a copy of your Robot 1. Im planning on giving it to my nephew as a X-mas. I was wondering are you running it a 8 MHz or 1 Mhz
Thanks

Are you sure? yes | no

shlonkin wrote 9 months ago point
I was running it at 8MHz. It would work fine at 1MHz, but you'd want to change some of the numbers in the code to compensate for the slower clock.

Are you sure? yes | no

DayDreamingPhd wrote a year ago point
I'v been looking at an old 1920 valve amp radio & loking to buy 1 to rebuild & stil keep the valves make it into annolg to digital & if I could get a few people helping m,e this would be grate fun , I have no exspeerence in elictronics & programing. but this would make progject to be on www.kickstater.com .

Are you sure? yes | no

bootdsc wrote a year ago point
Looks like someone found an old BEAM robotics article and decided to pass it off as there own.

Are you sure? yes | no

shlonkin wrote a year ago point
Not really, though they do look kind of similar. I've never seen a BEAM bot with a microcontroller, but then again I've never read a BEAM robotics article.

Are you sure? yes | no

ZaidPirwani wrote a year ago point
well, here is what I did yesterday...
https://github.com/Ejaad/tiny85Bots

Are you sure? yes | no

shlonkin wrote a year ago point
That's a really cool robot! How well does it work? Do you have a video of it?
I really like your idea of glue stick wheels, but I'm guessing that thing goes way fast.

Are you sure? yes | no

Eric wrote a year ago point
Saw this on sparkfun today and immediately thought of the robot family: essential sensor kit https://www.sparkfun.com/products/12862. Needless to say, desired components could be sourced individually more cheaply, but a good example of the possibilities.

Are you sure? yes | no

Similar projects