cancel
Showing results for 
Search instead for 
Did you mean: 

Question about HALL_CalcAvrgElSpeedDpp function

hankui zhang
Associate II
Posted on January 09, 2017 at 04:53

I notice  wAux = pDVars_str->wPseudoFreqConv

/pDVars_str->SensorPeriod[pDVars_str->bSpeedFIFOGetIdx].wPeriod;

hAvrgElSpeed = (int16_t)(wAux);

hAvrgElSpeed *= pDVars_str->SensorPeriod[pDVars_str->bSpeedFIFOGetIdx].bDirection;

and 

wPseudoFreqConv = ((pDParams_str->wTIMClockFreq / 6u) / (pParams_str->hMeasurementFrequency)) * 65536u;

I can't understand why need to divide hMeasurementFrequency,  wPeriod*6 is counts of one electric angle. 

Unit time divide wPeriod*6 should be the ElSpeed ,anyone can help me explain it, please.

Thank you all.

#calcavrgelspeeddpp #hall
0 REPLIES 0