Now I'm studying Microprocessor with 8051 I do my project so I can't write a program . I would like some of EXAMPLE .etc ...Red light Green light in crossroad .
I would like some source code.Please Give Me some help !!!
It's easy to write a program to the 8051 microcontroller. But first of all you need a flash programmer to download your codes in to 8051. You can find easily this circuit by searching net. Then you need a KEIL in order to program 8051 with high level language c. Also you can find a lots of examples written in c in linux forums. That is a short example program blinking led connected to the 8051 P0.0 pin.
#include <reg51.h>
#include <stdio.h>
long int i,j;
main()
{
while(1)
{
P0_0=1;//set P0.0 pin to logic 1
for (i=1;i<=1000;i++) //for delay
for (j=1;j<=1000;j++) // for delay
P0_0=0; //set P0.0 pin to logic 0
for (i=1;i<=1000;i++) //for delay
for (j=1;j<=1000;j++) // for delay
}
}
Thank you so much!!!
I have all things to load a program but my problem is "I don't have a EXAM code.
....How can I write a assembly...I need some EXAM project with ASSAMBLY LANGUAGE.
while(1)
{
P0_0=1;//set P0.0 pin to logic 1
for (i=1;i<=1000;i++) //for delay
for (j=1;j<=1000;j++) // for delay
P0_0=0; //set P0.0 pin to logic 0
for (i=1;i<=1000;i++) //for delay
for (j=1;j<=1000;j++) // for delay
I need more details.This project I make a crossroads.Simulate form a traffic lights.It's has RED GREEN and Yellow light....Help me please....I don't have a little knowledge about assembly.