??? 05/20/11 20:44 Read: times |
#182313 - PCA 8051 issue |
Hi Guys, I have been having a problem with the PCA on my 8051 and was wondering whether someone could offer any advice...
I have my PCA set up to detect edge transitions on a pin and this works fine, my interrupt triggers every 10ms as I am measuring the zero crossing of an AC wave. However the interrupt triggers more than this due to some other factor that is calling it. I know this to be the case, because I put some code in the interrupt routine that only runs when CCF4 bit is set, this bit corresponds to the PCA channel I am interested in. ECCF4 bit is set in CCAPM4, but all other interrupt bits are disabled. Initially I thought it was the timer overflow that was triggering the interrupt but i have disabled the ECF bit in the CMOD register and so presumably the overflow should not now trigger an overflow. The triggering wouldnt be an issue normally, but it executes so often that the main code has no chance of running. I hope someone can be of some assistance. |
Topic | Author | Date |
PCA 8051 issue | 01/01/70 00:00 | |
CCF4 Bit | 01/01/70 00:00 | |
CCF4 bit | 01/01/70 00:00 | |
run_mode?? | 01/01/70 00:00 | |
interrupt vectors | 01/01/70 00:00 | |
interrupt vectors | 01/01/70 00:00 | |
run_mode | 01/01/70 00:00 | |
Now seems like.... | 01/01/70 00:00 | |
Goes for all languages/platforms | 01/01/70 00:00 | |
my code | 01/01/70 00:00 | |
No.... | 01/01/70 00:00 | |
just a thought | 01/01/70 00:00 | |
Another Thought...![]() | 01/01/70 00:00 |