久芯网

关于FOC库5.4的启动revup

avatar 是谁事实上 提问时间: 2023-07-26 17:49:39 / 已解决
亲们:
       FOC5.4的库里面启动这块的这个函数:__weak bool RUC_Exec( RevUpCtrl_Handle_t * pHandle )
里面的操作
      /*Set the next phases parameter pointer.*/
      pHandle->pCurrentPhaseParams = pHandle->pCurrentPhaseParams->pNext;
这里的pCurrentPhaseParams 定义到的结构体是这样的:
typedef struct
{
  uint16_t hDurationms;        
  int16_t hFinalMecSpeedUnit;   
  int16_t hFinalTorque;        
  void * pNext;               
} RevUpCtrl_PhaseParams_t;

那这个操作是啥意思呢?如下:
/*Set the next phases parameter pointer.*/
      pHandle->pCurrentPhaseParams = pHandle->pCurrentPhaseParams->pNext;

谢谢各位大神能指导一下下
2个回答
  • avatar 弗兰克
    最佳答案
    回答时间: 2023-07-26 18:19:19

    uint16_t hDurationms; //当前阶段的爬坡时间 int16_t hFinalMecSpeedUnit; //当前阶段的目标转速 int16_t hFinalTorque; //当前阶段的目标转矩 void * pNext; //指向下一阶段的指针 也就是说开环的5个阶段,先执行第一个,然后依次执行

  • avatar 是谁事实上
    回答时间: 2023-07-26 18:37:15
    弗兰克 发表于 2022-6-27 12:18
    uint16_t hDurationms; //当前阶段的爬坡时间 int16_t hFinalMecSpeedUnit; //当前阶段的目标转 ...

    谢谢大哥,这里小弟明白了

会员中心 微信客服
客服
回到顶部