You are here: Home
Ok i'll mail complete code.
But I'm not generating a PWM signal on portB, just a high and low pulse,
later i'm using a transistor circuit for switching, now my concentration is only on
portB to how to hold a signal , not on portA.
Yes PWM is generated using timers, and i'm getting the output of it,which i'm generating in different port.
Now I have taken a seperate I/O port, where i'm getting the signal high and low, now my question is
how to control this signal for particular count/timer period[say for about maximum 5 to 10 minutes the
signal should be high and next it should be low]
Here is the part of the code:
sbit CLOCK = P2^3;
unsigned char check = 1;
void timer1_ISR`(void)
{
//timer tick functions
if(check == 0)
{
CLOCK = 0;//getting a low signal
}
else
{
CLOCK = ! CLOCK;//toggling high& low
}
}
I'm checking this in the isr routine.
Hope I have not confused, please let me know where i'm going wrong.