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.

28035 CCS5 IQMATH调用

我在用CCS5中调用IQMATH函数时发现以下小问题:

下面是我的代码:

_iq30 in2, out2 ;

in2 =_IQ10(0.333*PI/(2*PI));
out2 =_IQ10sinPU(in2);
temp = _IQ10toF(out2);

in2 =_IQ30(0.333*PI/(2*PI));
out2 =_IQ30cosPU(in2);
temp = _IQ30toF(out2);

最终结果基本正确,但在技术手册中例程时这样的

in2 =_IQ30(0.25*PI/PI);
out2 =_IQ30cosPU(in2);

按照例程却得不到正确的结果,难道例程出现问题还是其他别的原因,还请解答一下。。。

ps  // in1  = in2  = (0.25 x PI)/(2PI) x 2^30 = 0x08000000这是手册中的注释,跟例程也有些出入啊