Dear
My customer measure the execution timing for below 8 C code about 1.2us. However from assemble code as below picture, there should be only 3 assemble code for each C code and each assemble code should be 1 cycle timing, and the code is running in RAM base on 60Mhz clock, so we think the total timing for below 8 C code should be 3 x 8 x 16.6ns = 398ns. We are confuse why measurement is 1.2us?
We use GPIO toggle to measure the execution timing, in order to eliminate the GPIO operation timing, we try to measure the timing with below code at first as A period, then remove the below code to measure again as B period, and finally get the below code execution timing = A - B = 1.2us.
EPwm1Regs.AQCTLA.bit.CAU = AQ_CLEAR;
EPwm1Regs.AQCTLA.bit.CAD = AQ_SET;
EPwm1Regs.AQCTLB.bit.CAU = AQ_CLEAR;
EPwm1Regs.AQCTLB.bit.CAD = AQ_SET;
EPwm2Regs.AQCTLA.bit.CAU = AQ_CLEAR;
EPwm2Regs.AQCTLA.bit.CAD = AQ_SET;
EPwm2Regs.AQCTLB.bit.CAU = AQ_CLEAR;
EPwm2Regs.AQCTLB.bit.CAD = AQ_SET;
