Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.
CTC problem in atmega with mikroC compiler
I need a normal code of Timer1 CTC for atmega in mikroC. I have made a simple code but i can not understand where is my error i can not compare time when i>255.
Help needed.
#include<built_in.h>
unsigned int i;
void inerrupt_ISP() org...
Here i have a problem like i am using mikroC as compiler , in it the following code is not accepted ....
OCR1A=i;
when i declare such as......
OCR1AL=i;
then it is accepted but it is only possible when ( i<255 )
if i>255
then i have to declare it like
OCR1AL=Lo(i);
OCR1AH=Hi(i);
but in this...
I have faced problems in working with CTC in atmega. I can not produce interrupt after 1 second using CTC. I observed that the value of OCR1AH is not compared with with TCNT1H .What can be done?
Suggest needed.My code is following........
#include <built_in.h>
int a=0;
void Timer1compa_ISR()...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.