This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
Hi Experts,
I am doing the OC protection, when I want to setup the current protection. And I use the CMPSS3_L to implement the one-shot PWM protection.
So the below code is my CMPSS configure, I also check the register about the CMPSS3, you can see the COMPLSTS.
CMPSS_enableModule(PUSH_PULL_OCP_CMPSS_BASE); //COMPDACE CMPSS_configLowComparator(PUSH_PULL_OCP_CMPSS_BASE,CMPSS_INSRC_DAC);// // Select positive input of CMPSSL to come from B2/C6/PGA3_OF (ILV_FB) ASysCtl_selectCMPLPMux(PUSH_PULL_OCP_CMPSS_ASYSCTRL_CMPLPMUX, PSFB_PCMC_OCP_CMPSS_ASYSCTRL_MUX_VALUE); // // VDDA-- CMPSS_configDAC(PUSH_PULL_OCP_CMPSS_BASE, CMPSS_DACVAL_SYSCLK | CMPSS_DACREF_VDDA | CMPSS_DACSRC_SHDW); // CMPSS_setDACValueLow(PUSH_PULL_OCP_CMPSS_BASE, PSFB_OCP_DAC_INIT); //OC-DACLVALS-3584 // CMPSS_setDACValueHigh(PUSH_PULL_OCP_CMPSS_BASE, PSFB_OCP_DAC_INIT); CMPSS_configFilterLow(PUSH_PULL_OCP_CMPSS_BASE, PSFB_OCP_SAMPLE_PRESCALE, PSFB_OCP_SAMPLE_WINDOW, PUSH_PULL_OCP_THRESHOLD); // // Initialize digital filter // CMPSS_initFilterLow(PUSH_PULL_OCP_CMPSS_BASE); //from B2/C6/PGA3_OF (ILV_FB) CMPSS_configOutputsLow(PUSH_PULL_OCP_CMPSS_BASE, CMPSS_TRIP_FILTER | CMPSS_TRIPOUT_FILTER); //Use CMPSS-2 L- DACL for OCP CMPSS_clearFilterLatchLow(PUSH_PULL_OCP_CMPSS_BASE);
The register about the CMPSS3 as below:
could you help me out from the CMPSS configuration?
Hi Shaoxing,
What is the error that you are seeing from the comparator?
Best Regards,
Marlyn
Hi Marlyn,
Maybe I found that the DAC value is setup too less, so that the protection no work. But one question is that I did not configure the register on the high side of CMPSS3_H, why does COMPSTS have a value?
Hi Shaoxing,
why does COMPSTS have a value?
In order to help figure this out, what is the output of your comparator? Is it what you are expecting?
Best Regards,
Marlyn