能解释下取模的函数吗?
void powerMag(long nfill, char* strPara)
{
int32_t lX,lY;
uint32_t i;
for (i=0; i < nfill; i++)
{
lX= (lBUFOUT<<16)>>16; /* sine_cosine --> cos */
lY= (lBUFOUT >> 16); /* sine_cosine --> sin */
{
float X= 64*((float)lX)/32768;
float Y = 64*((float)lY)/32768;
float Mag = sqrt(X*X+ Y*Y)/nfill;
lBUFMAG = (uint32_t)(Mag*65536);
}
}
if (strPara == "1SIDED") onesided(nfill);
} |