| | | | |
In lugnet.robotics, Philippe Hurbain wrote:
|
YAL: Yet Another LegWay
Allen Foster and
Harold Jarvie posts showed me that
it was possible to build a LEGO-only self-balancing robot, inspired by the
famous Steve Hassenplugs
LegWay.
Here are some details of my implementation, using two regular light sensor to
monitor YAL inclination.
The code is a simple PID algorithm
implemented in BrickOS, direct translation of
Allen Foster code. The input comes
from front and back light sensors difference, the output is applied to both
motors.
Yal works best with diffused overhead lighting and doesnt like at all
lateral lights (windows)
|
I built one of these yesterday, and it works surprisingly well! I like the very
simple design. Like Steve Hs original LegWay, it requires very few parts.
Although it is a little tricky to put it together.
I found that the performance of the robot is highly dependent on a couple of
factors:
- Solid-color, bright or white floor seems to work better than patterned floors.
- You have to hold the robot perfectly vertical when you start the program so that it gets a good offset reading between the two light sensors. The better you do this, the better the resulting balance.
- Works best in a dark room with no lights pointing directly at the robot.
Very nice job! It makes me want to add some code to make it move around and
chase the cats.
I have to second this. John has done a very nice job with BricxCC. He has also
made it possible for me to finally get a working GCC installation with BrickOS
on my Windows 98SE machine. Thanks, John!
- Chris.
| | | | | | | | | | | | |
| |
| <snippage>
> * Solid-color, bright or white floor seems to work better than patterned floors.
> * You have to hold the robot perfectly vertical when you start the program so
> that it gets a good "offset" reading between the two light sensors. The
> better you do this, the better the resulting balance.
> * Works best in a dark room with no lights pointing directly at the robot.
</snippage>
i'm thinking that making a vertical frame to start it would help. something
like two support barsthat are vertical in which you would put the YAL to
start it off in a perfectly vertical position. you could even make it hinged
on one side so you could program a short burst of speed after registering
"vertically" which would allow it to get out of the frame by itself.
also, perhaps adding a third motor with an weight (micro-motor?) that could
be offset to change the center of gravity slightly could give the YAL
direction to go. like forcing it to tip and move in the direction of the
tip.
and final thought, it would seem that YAL is pretty much a lateral motion
bot, so maybe it would be easier for it to balance with a solid axle?
just a few thoughts.
regards,
mike
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.576 / Virus Database: 365 - Release Date: 1/30/2004
| | | | | | |