Let's Make Robots!

Wall following using Sharp sensors

Hey guys,

I'm using the following sensors for wall following (2 of them):


Everything is fine until I get too close to the wall i.e. <10 cm. How can this be fixed. I've found another sensor which has range from 3cm to 10cm. Should I use that or some mechanical solution or is it possible to fix te problem using just 2 of these sensors.

Thank you.

Wall following robot

Hey guys,

Just wondering if I'm on the right path. I have to make a robot tht stays a fixed distance from a wall. I'm thinking of using 2 ultrasonic sensors that would be mounted near the front and rear wheels. So the robot is parallel when the difference between sensor1 and sensor2 is zero.

So I guess use one sensor (say, in the front) to check the distance from wall and both sensors to align it to the wall (PID?). Huh... any tips, hints.



While loop breaks unexpectedly

Hi guys,

This is my first robot. The microprocessor is a QIC board and micrrocontroller is the Microchip PIC 16F877. The code is written in PIC C, a C compiler.

The robot is to solve a maze which is black and white. The robot is to stay on the black line and I use two sensors in the front of rover called resistor1 and resistor 2. There are two sensors for turning: resistor3 and resistor4.

The problem is that my code works but it shouldn't! I will only post a sample of my code below: