Looking for a counter with two seven segments using 16F84

Status
Not open for further replies.

hassan1980

Full Member level 4
Joined
Jan 14, 2005
Messages
204
Helped
9
Reputation
18
Reaction score
6
Trophy points
1,298
Activity points
1,340
Hi, guys

I am looking for a counter with two seven segments using 16F84

if anyone have have it would you please post it.

Kind Regards

Hassan
 

Re: Please help me

hi;
double 7 segment ccs compiler pic code. working.
#if defined(__PCM__)
#include <16F84.h>
#fuses XT,NOWDT,NOPROTECT
#use delay(clock=4000000)

char x[10]={63,6,91,79,102,109,125,7,127,111};
char b;
char birler =0 ;
char onlar =0;

void on()
{
onlar++;

if (onlar > 9 )

onlar = 0;

}


void bir()
{
birler++;


if ( birler > 9 )
{
birler = 0;
on ();
}

}


void dsp()
{

output_b (x[birler] );
output_a(1);
delay_ms(1);

output_b (x[onlar] );
output_a(2);
delay_ms(1);


}



void main() {


while(true)
{
bir();
for(b=0;b<50;b++)
{
dsp();
}
}
}
 

    hassan1980

    Points: 2
    Helpful Answer Positive Rating
Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…