go away spammer

Author Topic: How to control robot movement through ATmega8 controller, without sensor ?  (Read 4122 times)

0 Members and 1 Guest are viewing this topic.

Offline kahTopic starter

  • Beginner
  • *
  • Posts: 4
  • Helpful? 0
Hi everyone, I do have certain doubt. In those common robots, there are sensors such as photo resistor or IR emitter to detect and provide analog signal to the microcontroller, which later processed to control the robot. Can i just control or pre-programmed the movement of the robot in the programming part first, so that the robot will move according to the path and speed i set , without depending on the sensor ? Is it possible to do that by AVR programming ?

Hope you guys can give some advice for me. Thanks a lot in advance.

Offline richiereynolds

  • Full Member
  • ***
  • Posts: 112
  • Helpful? 3
Yep, you can. That's totally up to your program, you can program it to do whatever you like, you don't need to use sensors if you don't want to.

Offline gossamer

  • Beginner
  • *
  • Posts: 4
  • Helpful? 0
Ok, by sensors you mean distance sensors ?

You cant program robot speed or even direction if you dont have feedback from sensors that measure those units. But for some common movement you dont need distance sensors.
You dont even need sensors at all, but than you will have some heuristic principles in robot movement.
For example if you are using some kind of smart h-bridge (motor controller) and for example servo motor for steering your program could go like:

SetSpeed (50)
Sleep(time)
SetSpeed (10)
Sleep(time)
SetSteering(20)
...
// this is only pseudo code. where setspeed is percentage of max voltage or some other unit

I hope you got the point what you can achieve without distance sensors... you will not know your current position in space, nor you could not achieve some trajectory. But you will definitely have moving bot :) 

Offline corrado33

  • Supreme Robot
  • *****
  • Posts: 611
  • Helpful? 11
I would have to agree with everybody else.  It is possible, for example, to have your robot move around a room in the same pattern every time, as long as they started in the same place every time.  However, maybe the floor is slippery one day, and the wheels slip a little bit, you aren't going to travel as far as the robot is supposed to.  That's why even one sensor is a good thing.

Offline kahTopic starter

  • Beginner
  • *
  • Posts: 4
  • Helpful? 0
oh thanks a lot for all your advice. but i am still confused. If there is no sensor involved, then how am i supposed to program the code , so that the mobile robot will move according to the path and velocity set by me ? I am very new to programming, so I dont really understand much, but I did some research on programming, but most code involving sensor as the analog input. Thats why i am confused. Can anyone help me with the code ??

thanks a lot.

Offline waltr

  • Supreme Robot
  • *****
  • Posts: 1,944
  • Helpful? 99
Well its what is called "Dead Reckoning" in aviation. Turn for a fixed period of time, then go straight for a fixed period of time. If all goes well then you arrive at the destination.

Offline Canabots

  • Contest Winner
  • Robot Overlord
  • ****
  • Posts: 245
  • Helpful? 6
  • It's not a bug, it's a feature!
    • Salmigondis Tech
 I'm in agreement with Waltr's definition.

The sensor's purpose is to gather data of the surroundings, it's not actually required for the bare movement of the robot.
Now, if your robot is about to run into a table, that's where the sensor comes in handy, allowing you detect the object, avoid it, and if you code it, go around the object to continue to the destination.

Now, as for moving the robot, all you'd have to do is use the command to control servos(if you're using modified ones) or gear head motors.
« Last Edit: April 04, 2010, 11:38:40 AM by Canabots »
My robotics, electronics, software, or other stuff blog:
www.saltech.wordpress.com

Offline kahTopic starter

  • Beginner
  • *
  • Posts: 4
  • Helpful? 0
ohh, then is there any sample programming code for me to browse through about programming the bare movement of the robot , such as movement like moving straight at certain distance, then turn with specific speed. How do i program the path and wanted movement then ?

Offline waltr

  • Supreme Robot
  • *****
  • Posts: 1,944
  • Helpful? 99
Did you read the many SoR tutorials and articles? Great starting point.

Offline kahTopic starter

  • Beginner
  • *
  • Posts: 4
  • Helpful? 0
yea, i did some reading on the tutorial. but i dun really understand or how to relate those to my situation. Which tutorial do u mean ?

 


Get Your Ad Here