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.

关28069 执行 float 条件判断时跑飞

Other Parts Discussed in Thread: MOTORWARE

  如下段代码,  在单步执行  if(s>(float_t)5.0)  时,为什么会跑飞,无法单步执行 if(s>(float_t)5.0)  以后的代码??????????????????

float s=(float_t)5.2/(float_t)9.5;
  if(s>(float_t)5.0)
  {
      USER_setParams(&gUserParams);
  }
  gMotorVars.UserErrorCode = USER_getErrorCode(&gUserParams);