Search Engine www.edaboard.com

Ccs C Timer

Add Question

Are you looking for?:
timer with ccs , timer value , timer down , second timer
74 Threads found on edaboard.com: Ccs C Timer
Check out the ccs forum at: You will get a lot of ideas just browsing their forum ... The guys there are nearly as nice as the members here :-) best regards
Hi, There are example codes available to interface realTime Clock Chips which you can find with the installation of ccs Compliler. Or otherwise you can search your solution at ccs forum or Technocrafts Forum. Links are Or if you need some specific thing you can ask.
Go here: and type bootloader into the serchbox and you will get enough material to read :-) best regards
you translate the page for me, I am waiting for C-man to reply on my post, I think he knows the solution for my source code problem. Hi, first of all which PIC are you using? which clock frequency
I am using RTOS of TI ccs, but the timer interrupt of OS conflict with my task and other ISR. So I want remove the timer of OS since I do not use any timer function. Can I do so? Why the RTOS need timer?
I am making a speed measurement device. Speed ranges from 250 fps to 800 fps, so timing is really critical. I tried using this kind of loop but seems creates some kind of delay, attached is my original code. include "C:\Documents and Settings\Glenjoy\My Documents\Chronograph 2\Chronograph.h" #include long micro_S; long m
The ccs C compiler has a very extensive Help file and example library. Just goto the help file (F1) and in the index check the functions setup_timer_0 , setup_timer_1, etc. It should explain what all the arguments are for, and which are availible to you on your PIC. Do note that not all timers have the same functionality. (...)
How to use a Watch Dog timer? Am I using the WDT in a correct way?? I need a sample code for wdt in ccs C ?? Its not working only it performs task2 :| #include <16F877A.h> #fuses XT,WDT,PUT,BROWNOUT,NOPROTECT,NOLVP,NOCPD #use delay(clock=4000000, RESTART_WDT) timer0_ISR { restart_wdt() task1() } main() { (...)
555s can be very fickle when used in timer mode, they are very prone to false triggering when near any source of interference. I think you will end up tearing your hair out when used in the presence of an electrically noisy motor. You can buy timed off relays with variable timers. Also as Banjo suggested, a cheap micro PIC16C628 etc may be a better
There are example programs available for the same when you install ccs compiler. Please check the folder where you installed the PIC C compiler. Their Help manual explains about what each example program file does. Good day. Regards, blueshift
Hi, i'm new to the programming and I was trying to set up the a/d converter. I found this pwm example code from ccs examples, and I was expecting pinC7 as an analog input and the picC6 as a modulated output. However, when I checked the output on the oscilloscope it looked like it is not dependent on what input I put in C7! It looked like it goes hi
Hi, Here the example of C18 MPLAB compiler code to generate delay using timer 0: Void Delay() { T0CON=0x08; TMR0H=0x35; TMR0L=0x00; T0CONbits.TMR0ON=1; while(INTCONbits.TMR0IF==0); T0CONbits.TMR0ON=0; INTCONbits.TMR0IF=0; } I want to write the same code using ccs compiler without using built in function. Ho
I'm not familiar with ccs syntax but I would guess you are not calling the interrupt at all. Maybe I'm wrong but I can see a routine that sequences pins over 8 of the 256 counts but nothing that actually calls that routine. Do you need to create an ISR routine then call isrtcc() from within it ? The other thing that isn't clear is what is TMR0
I am doing a project where i need to find the frequency of a waveform generated by a spark plug. I am using pic 16f 877a & ccs compiler for programming. As a beginning am trying to assume that the wavform to be measured is a sine. And convert it into an adc and make it square, & find the frequency.i am beginner in this field and am nt able to pro
I have a project and I can't figure it out why it isn't working the I2C. I need to transfer some data from a PIC16F877A to another using I2C. Here is the code: Master.h #include <16F877A.h> #device adc=10 #FUSES NOWDT //No Watch Dog timer #FUSES HS //High speed Osc (> 4mhz for PCM/PCH) (>10mhz
hi all.... How can i enable the oscillator start up timer in ccs compailer????? i wn't see any settings in the ccs for that.... Regds, Sreejith
hi i m new to tis forum... can anyone say how to write 10ms delay using timer in ccs compiler... i m using PIC16F676... i m using tis controller for my project... it will be very helpful for me..... Thanks in advance
i have tried to decode rc5. but i unable to decode. do any one have c code for pic16f877 to decode rc5 protocol
Hello, Im not a common user of the ccs compiler but is it setting the timer count register to 42? Maybe it is also enabling the timer with that value as a fixed rollover value. eg timers count from 0 to 255 (8-bit) or 0 to 65536 (16-bit). When they rollover from their max count to 0 the timer generates an (...)
I'm trying to create a delay with N minutes using timer 1 .. I found the following code #include <16F628A.h> #fuses INTRC_IO, NOWDT, NOPROTECT, BROWNOUT, PUT, NOLVP #use delay(clock=4000000) //====================== void main() { int16 delay = 0; SET_timer1(delay); SETUP_timer_1(T1_INTERNAL | T1_DIV_BY_8); while(TRUE) {
I'm new to PIC programming. Can someone please tell me what are the factors that I should be concerned about when setting ADC and timer clock inputs. I have given a project to complete but this is not my study area. I'm learning everything from the beginning. I've written the code but I need it to be accurate. I'm using ccs C. Thanks in advanc
I'm newbie to programming and did some basic programs in ccs c compiler. Now like to do using timers, but don't know how to start and where. It will be very kind if anyone would help me!! Two buttons (start and stop) are connected to connected to microcontroller. When start button is pressed, timer starts counting and shows the value (...)
Hi pal, Permit me to join in the discussion.i compiled your code; #include "C:\Users\xyz1\Desktop\xyz_new\lab tutorial.h" #include <16F877A.h> #device adc=16 #FUSES NOWDT //No Watch Dog timer #FUSES HS //High speed Osc(>4mhz for PCM/PCH) (>10mhz for PCD) #FUSES NOBROWNOUT //No brownout reset #FUSES NOLVP /
hello.....i want to build a real time clock using the internal timer(s) of the pic 16f877a and display the time on 16x2 lcd. I can handle the lcd commands but please upload and explain me the timer operations using the ccs pcw compiler......!
There a "lapse" in code!!! unsigned int myStr = 0; is unsigned int myInt = 0;??? And Display show 0056 in my case (not 5432)!!! #include <16C76.h> #device adc=8 #FUSES NOWDT //No Watch Dog timer #FUSES HS //High speed Osc (> 4mhz for PCM/PCH) (>10mhz for PCD) #FUSES NOBR
Hello can anyone help to set up timer1 or timer0 for measuring timer elapsed from Rising edge of a square wave signal to the next rising edge. I want to determine the frequency.I only know ccs c . Thanks.
hello every body,I am trying to red the period of a given signal and then take decision basing on the period reads,but with period of frequency between 100Khz and 1000Khw (1Mhz) there is no problem but for frequency above 1Mhz the system is reading the same as some of the frequencies I held in the range of 100KHZ to 1000KHz;I think the problem is c
Can some body plz help me to modify the following codes for counting the frequency up to 2Mhz of a square wave and sine wave: #include <16f877a.h> #use delay(clock=20M) #include #include #fuses hs,nowdt,nocpd,nolvp,noprotect #byte portc=0x07 #bit led=portc.4 void LCD_D(); unsigned int16 value; void main()
Is timer0 a 16 bit timer? Try this configuration in ccs C. Clock is 8 MHz. //timer0 //Prescaler 1:1; TMR0 Preload = 59981; Actual Interrupt Time : 2.777 ms //Place/Copy this part in declaration section void Inittimer0(){ T0CON = 0x88; TMR0H = 0xEA; TMR0L = 0x4D; GIE_bit = 1; (...)
Library for what compiler ? many library in Asambly or on the web site of microchip. Or if you what in C you can use many compiler, but I like ccs because it's come with a lots of library. I2C, SPI, serial, ADC, timer, Real time clock, etc... I thing is the most complete.
Hi, it's so easy for example to creat 1khz square wave using ccs c compiler. We calcualte time duration T=1/1000Hz = 1 ms Then divide it by 2 ---> 1ms/2 = 500 us while (1) { output_high(PIN_A1); delay_us(500); output_low(PIN_A1); delay_us(500); } Bye
I need to use both wdt and the timer 0 compiling with ccs. I need to set the timer0 prescaler to 1:256, and I have no problem with WDT time (18ms or .......). If is possible, which is the right manner to implement that. Other question is Can I simulate the wdt into proteus 6.3 sp1. Thanks a lot in advance.
if You use C for programming Your project, ccs is automaticaly set INTM on interrupt handler entrance. If You want to use irq priority resource? You mast need enable global IRQ. interrupt void pdpinta(void) {asm(" clrc INTM "); ..... return; } Interrupt priority system is described in spru286.pdf chapter2 University instruction
Get the PCW tutorial from ccs website and work through the RS232 and timer example. You should have no problem. You never post your source code and schematic, there ain't much for us to help. Check that the hardware is working properly. Measure RS232 TX and RX pins of the pin to see if the id
Hi. I thing you don't have to clear timer interrupt ( clear_interrupt(INT_timer0); - ccs clear if need it) And try to turn off Brounout.(#fuses NOWDT,INTRC_IO, NOCPD, NOPROTECT, NOMCLR, PUT, NOBROWNOUT). Best Regards.
I use ccs C Compiler, it's has more resource and wizard that make this work more easy. The manual of Mikro C informs that SFR are defined automatic and you can use this, without you to specify the memory address of them. First you have to configure your timer (timer 1 for example, to generate a 200Hz frequency) as below: void (...)
Hi! Can anybody help how to measure a pulse width in ccsC? Signal normally high and I want to meaure the duration of a low signal before it goes high again(i.e. a negative pulse in the millisecond range) Please show two methods: 1. Using interrupt 2. Without using an interrupt. Thanks
Hi If you are using ccs, you can do the following: #use delay(clock=4000000) // Define the crystal speed here then you can use: Delay_Us(100); or Delay_Ms(10); For example... Good luck
it is as simple as below code (ccs C language used)...the code can b understand easily... wth basic knowledge on programming however one prob is tht the software delay (delay_ms or delay_us) in this high level language is not really accurate, as each line of C code is not actually a line of assembly code (it might b few lines of assembly code)..
Just a suggestion: Use Port B & Port D for 8x8 matrix key (8x8), 64 keys Use Port A.0-A.5 with Port C.0-C.5 for 6x6 matrix keypad, 36 keys Addup to 100 keys as required by your spec 10x10. Use software keypad module provided by ccs or matrix key module by Jean J. Labrosse's book Embedded System Building Blocks for scanning the keypads.
Hi, thank you for your answer I used ccs with the driver for the ds1307
Sir, I am new to Micro chip microcontroller environment.I am about to select a compiler(for 12/14/16/17/18 series PIC mcu) for our project.We have to select between Hitech Pic C and ccs Pic C compiler.But price difference is huge. Can anybody help me to choose one of them and why? And what should be the compiler evaluation factors based on
Here is the simple circuit for PIC16f877A that I design , I check the hardware very carefully but when I embed my charged PIC into the circuit, just to test output high and low, it not work ??? I also wonder why the crystal measured by oscillatior has no signal, try to replace another crystal but still the same, do you think that I have to check so
Can anyone pls tell me how to generate square wave using timers rather than delay in PIC microcontrollers (16F876). Im using ccs COMPILER. Regards.
I'm using a 16F727 and I have to do cap sensing.Now my doubt is that there is a timer 1 Gate Interrupt Flag but the interrupt is not specified in my ccs my doubt is whether the Gate Interrupt triggers the Normal timer1 Overflow Interrupt Flag
also you can use software delay functions provided by MikroC, C18 or ccs compilers if you are not familiar with timer interrupts.
if in ccs u have a problem resolving he global interrupt u can disble it at runtime using the timer config modeules please check not sure about this
I just can't see an end to such questions! Go over to the ccs forum, download the PWMWizard (or even here) and copy paste into ccs IDE and you will be set.
Which compiler you are using for programming. If you are using ccs compiler then you can find lot of examples how to interface keypad and lcd with microcontroller at . You can use timer to generate interrupt after every 1sec, then increament your variable let say Sec,when sec will be greater than 59,then increament min and
it is restart_wdt(); at ccs c, if you look at the manual of your compiler, "ClrWdt" should be the instruction. You can reach the manual from here: