Google

Aug 19, 2008

code for line following robot in atmega8

Basically a line following robot is the one which follows a particular line and moves along with that line even if its straight or curved or any thing you can look at the following video for a typical example



Now this is the source code for the line following Robot.
this will work for atmega8

int main(void)
{
DDRB|=0x0F;
PORTB=0x0F6;
while(1)
{PORTB|=0x06;
PORTB&=0x0F9;
}
}

with the above code the bot will move only in the straight path now if you want it to move in different directions just change the code in the while loop

You might be also interested in:

:: centigrade (celsius) to fahrenheit calculation for 8086 Assembly Language
:: Data transfer instructions of 8086 microprocessor
:: 8085 Microprocessor simulator for linux
::Interfacing pic microcontroller with LCD

3 comments:

arnab - a person waiting for a new dawn said...

could you please post the full code for the line follower that is when it has to turn left and righ as i am not experienced iwth microprocessor programming

rocky said...

can u plz help me by giving the full prog. im new to this.

SRIKANTH said...

sir,can u pls send me the full code for line follower...