Part Number: TMS320F28069
Other Parts Discussed in Thread: CONTROLSUITE, C2000WARE
Hello All,
I've seen posts like:

And wanted to point out something I have found in the HRCAP examples that are included in C2000 Ware:
In the HRCAP2_Config() examples - the EDIS; statement is missing - and that can cause obvious problems at run-time; and I have to wonder if some of the posts asking about this are related - from one of the examples:
//
// HRCAP2_Config -
//
void
HRCAP2_Config(void)
{
EALLOW;
HRCap2Regs.HCCTL.bit.SOFTRESET = 1;
HRCap2Regs.HCCTL.bit.HCCAPCLKSEL = 1; // HCCAPCLK = PLL2CLK = SYSCLK2 x 2
#if RISETEST
//
// Enable Rising Edge Capture Event Interrupt
//
HRCap2Regs.HCCTL.bit.RISEINTE = 1;
//
// Disable Falling Edge Capture Event Interrupt
//
HRCap2Regs.HCCTL.bit.FALLINTE = 0;
#elif FALLTEST
//
// Enable Falling Edge Capture Event Interrupt
//
HRCap2Regs.HCCTL.bit.FALLINTE = 1;
//
// Disable Rising Edge Capture Event Interrupt
//
HRCap2Regs.HCCTL.bit.RISEINTE = 0;
#endif
//
// Enable Interrupt on 16-bit Counter Overflow Event
//
HRCap2Regs.HCCTL.bit.OVFINTE = 0;
}
I found this while running some of my code - I thought it was an oversight on my part - but when I looked at some other posts; I went back to the code that is posted in the examples published by TI and discovered the EDIS; command is missing.
Anyway, an easy fix but has been obviously overlooked. I looked at an example on one of the other parts that has the HRCAP module - that has HRCAP1_Config(); and the EDIS; statement is there - so maybe this is just on the TMS320F28069 code - but I imagine the entire code base should be checked.
Regards,
John W.