Author |
Message |
Topic: efficient code for multiple PWM signals? |
bmoore
Replies: 5
Views: 5600
|
Forum: General CCS C Discussion Posted: Mon Feb 15, 2010 10:51 am Subject: efficient code for multiple PWM signals? |
I like at least eight PWM signals
PWM frequency probably needs to be around 100 Hz
Resolution will vary from 1/32 to 1/64 (length of a "tick" will remain the same, but number of ticks ... |
Topic: efficient code for multiple PWM signals? |
bmoore
Replies: 5
Views: 5600
|
Forum: General CCS C Discussion Posted: Tue Feb 09, 2010 1:56 pm Subject: efficient code for multiple PWM signals? |
I'm trying to implement multiple PWM outputs in software with a different period and duty cycle for each signal, but am having trouble getting the code to run fast enough. I have the values for the p ... |
Topic: interrupting other interrupt routines |
bmoore
Replies: 1
Views: 3037
|
Forum: General CCS C Discussion Posted: Tue Dec 15, 2009 9:07 am Subject: interrupting other interrupt routines |
Chip used: 16F887
I'm doing some PWM in software using TIMER0 and would like a TIMER0 overflow to interrupt everything, include other interrupt routines. According to the CCS compiler manual: &quo ... |
Topic: "Out of ROM of" error when only 1/4 of ROM used |
bmoore
Replies: 3
Views: 6814
|
Forum: General CCS C Discussion Posted: Thu May 08, 2008 9:42 pm Subject: "Out of ROM of" error when only 1/4 of ROM used |
Yes, it came with a PICKit 2 Debug Express package... That stinks. |
Topic: "Out of ROM of" error when only 1/4 of ROM used |
bmoore
Replies: 3
Views: 6814
|
Forum: General CCS C Discussion Posted: Thu May 08, 2008 9:32 pm Subject: "Out of ROM of" error when only 1/4 of ROM used |
CCS PCM C Compiler, Version 4.020b
I'm getting an Error 71- Out of ROM when trying to compile a program for a PIC16F887. When I remove some code in order to get it to compile, it says ROM usage is ... |
Topic: how to disable C2OUT on pin RA5 with CCS C code? (PIC16F887) |
bmoore
Replies: 6
Views: 10561
|
Forum: General CCS C Discussion Posted: Sun Feb 24, 2008 4:46 pm Subject: how to disable C2OUT on pin RA5 with CCS C code? (PIC16F887) |
I used
#BYTE CM2CON0=0x108
and
CM2CON0 &= 0x11011111;
to set C2OE low, and pin RA5 now works fine as an output. I'm still left wondering why direct manipulation of the CM2CON0 registe ... |
Topic: how to disable C2OUT on pin RA5 with CCS C code? (PIC16F887) |
bmoore
Replies: 6
Views: 10561
|
Forum: General CCS C Discussion Posted: Sun Feb 24, 2008 4:17 pm Subject: how to disable C2OUT on pin RA5 with CCS C code? (PIC16F887) |
My bad.
CCS PCM C Compiler, Version 4.020b |
Topic: how to disable C2OUT on pin RA5 with CCS C code? (PIC16F887) |
bmoore
Replies: 6
Views: 10561
|
Forum: General CCS C Discussion Posted: Sun Feb 24, 2008 4:05 pm Subject: how to disable C2OUT on pin RA5 with CCS C code? (PIC16F887) |
Post your compiler version. (always do this)
PCMDB2k 2.22.01.15 |
Topic: how to disable C2OUT on pin RA5 with CCS C code? (PIC16F887) |
bmoore
Replies: 6
Views: 10561
|
Forum: General CCS C Discussion Posted: Sun Feb 24, 2008 3:56 pm Subject: how to disable C2OUT on pin RA5 with CCS C code? (PIC16F887) |
On a PIC16F887 I want to use RA5 as an output, but I can't figure out how to either disable Comparator 2 or stop the routing of C2OUT to the same pin as RA5. I know I need to to set C2OE to zero in t ... |
Topic: problem with TIMER1 when using internal LP oscillator |
bmoore
Replies: 7
Views: 10914
|
Forum: General CCS C Discussion Posted: Mon Feb 11, 2008 1:12 pm Subject: problem with TIMER1 when using internal LP oscillator |
Look at the block diagrams for the main oscillators and for Timer1
in the data sheet.
Timer1 can be clocked by:
1. An external 32.768 KHz watch crystal, using the T1OSC.
2. An external clock i ... |
Topic: problem with TIMER1 when using internal LP oscillator |
bmoore
Replies: 7
Views: 10914
|
Forum: General CCS C Discussion Posted: Mon Feb 11, 2008 12:24 pm Subject: problem with TIMER1 when using internal LP oscillator |
There is no internal 'crystal' in the PIC.
There is a 31 KHz internal oscillator. This is activated with the INTRC
or INTRC_IO fuses. This oscillator can run the entire PIC.
Timer1 has an ... |
Topic: problem with TIMER1 when using internal LP oscillator |
bmoore
Replies: 7
Views: 10914
|
Forum: General CCS C Discussion Posted: Mon Feb 11, 2008 11:42 am Subject: problem with TIMER1 when using internal LP oscillator |
Can you explain this a little more ? You only get two interrupts, but
during what time period ?
At intervals of two seconds (as near as I can tell), so within about four seconds from power up ... |
Topic: problem with TIMER1 when using internal LP oscillator |
bmoore
Replies: 7
Views: 10914
|
Forum: General CCS C Discussion Posted: Mon Feb 11, 2008 1:38 am Subject: problem with TIMER1 when using internal LP oscillator |
I'm trying to run a simple program on my PICKit 2 44-pin Demo Board
(PIC16F887) that keeps track of the overflows on TIMER1 when it is
clocked by the internal 32kHz crystal (see C code below for the ... |
|