HOW to change from left spindle to right spindle system

本文探讨了基于双轴系统的软件配置与故障诊断方法,包括主次轴位置计算、误用与障碍物检测,以及功率平衡算法。通过分析不同模块如SpindleBreakDetection_cfg.c和SwcApplPowerBalancer.c,揭示了系统如何处理电机电流限制和尾门电机状态。此外,还讨论了短路接地诊断在双轴系统中的应用。

1. project_cfg.h

#define LEFT_SPINDLE_DRIVEN (1u)
#define RIGHT_SPINDLE_DRIVEN (2u)
#define LEFT_OR_RIGHT_DRIVEN RIGHT_SPINDLE_DRIVEN

 

   

2. SensorPosition.c

Seems problem! but may only effect on Diagnosis

Spo_CalculatePosition

1. Calculate main position based of data from left spindle */

C_U8_CONFIG_NUMBER_OF_SPINDLES

E_SPO_SPINDLE_PRIMARY

E_SPO_SPINDLE_SECONDARY

 

 

3. MisuseDetection_cfg.c

#if(2u == NUMBER_OF_SPINDLES)
...

#endif

4. ObstacleDetection_cfg.c

5. SlamDetection_cfg.c 

/* primary side - dual sided and single systems */
    SCI_Read_HallSensor_Rpm(&(Sld_ms_PrimarySpindleData.u16_Rpm), E_SHA_HALL_PRIMARY  );

    #if(2u == NUMBER_OF_SPINDLES)
        /* secondary side - only dual sided systems */
        SCI_Read_HallSensor_Rpm(&(Sld_ms_SecondarySpindleData.u16_Rpm), E_SHA_HALL_SECONDARY  );
    #endif

6. SpindleBreakDetection_cfg.c

7. SwcApplPIDCtrlPwm_A.c

  /* Set/reset over current flag depending on spindle current and limit value */
 if ((Inputs->u16_MotorCurrentA < lu16_CalculatedCurrentLimit)
#if NUMBER_OF_SPINDLES > 1
   && (Inputs->u16_MotorCurrentB < lu16_CalculatedCurrentLimit)
#endif

8. SwcActuatorSpindleMotor.c

typedef enum{
#if NUMBER_OF_SPINDLES > 1
 TlgtMot_Right = 1, /* right Tailgate motor */
#endif
 TlgtMot_Left  = 0 /* left  Tailgate motor */
} TlgtMotT;

9. SwcApplPowerBalancer.c

 

/* primary side - dual sided and single systems */
    Sbd_ms_PrimarySpindleData.u16_PreviousRpm = Sbd_ms_PrimarySpindleData.u16_Rpm;
 SCI_Read_HallSensor_Rpm(&(Sbd_ms_PrimarySpindleData.u16_Rpm), E_SHA_HALL_PRIMARY  );
...
    Sbd_ms_PrimarySpindleData.b_TailgatePositionValid = lb_ReadBoolean;

    #if(2u == NUMBER_OF_SPINDLES)
        /* secondary side - only dual sided systems */

        Sbd_ms_SecondarySpindleData.b_TailgatePositionValid = lb_ReadBoolean;
    #endif

 Already Research:

2. Short to Gnd Dignosis

some investigation already done:

In Pmg_UpdateHCOMStableFlag() of PowerManager_cfg.c

from the comment

/* Hall Supply A and B shall behavior in the same way, not working independantly*/

this part only considered double spindle system.

the flag b_UHallStable is set here

转载于:https://www.cnblogs.com/dannykong/p/10873455.html

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值