IES Practical - 5

You might also like

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 5

Introduction to Embedded Systems

Practical #5
Name Jeet save Division B
Class S.Y.B.Sc.IT Roll Number 21302E3007
Practical 5 Create a counter circuit which can count from 00-99 is ascending and descending order,
Date:
Circuit Diagram: Paste the Screenshot / Picture of the Circuit

Vidyalankar School of Information Technology


Code : Write the code(No screen shot)

Code for counter counting form 00 –99:

#include<reg51.h>
delay(unsigned int y)
{
unsigned int n;

for (n = 0; n < y; n++)


{
;
}
}

void main()
{
int a[10]={0xC0,0xF9,0xA4,0xB0,0x99,0x92,0x82,0xF8,0x80,0x90};
int i,j;

while(1)
{
for(j=0;j<10;j++)
{
P2=a[j];
for(i=0;i<10;i++)
{
P3=a[i];
delay(30000);
}
}
}
}

Vidyalankar School of Information Technology


Output: Paste the Screenshot / Picture of the Output of the Circuit

Vidyalankar School of Information Technology


Vidyalankar School of Information Technology
Vidyalankar School of Information Technology

You might also like