hall sensor sector

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

hall sensor sector

1,032 Views
sarwath
Contributor IV

Hello Community,

I am using MCSPTE1AK144 EVB. I want to run a motor by using the 6 step commutation. Currently I am able to run the motor with hall sensor feedback. Now I am facing issues When the motor starts from the Sector 2.

At initial stage, If the rotor starts from sector 2 it is not going to next sector , I have to push the motor little bit to next sector then the motor starts rotating properly.

If the motor starts from any other sector , it is working properly. My doubt is why in sector 2 the rotor not able to move.

I am attaching my project please have a look and help me to solve this.

 

Thanks in advance,

Sarwath

Tags (3)
0 Kudos
7 Replies

942 Views
marekmusak
NXP Employee
NXP Employee

Hello,

Alignment state is important for sensorless control of the BLDC Six-step.

Sensorless control with no position sensor requires to get rotor from unknown to known position.

Once you know where is your rotor position you can start-up the motor with maximum torque, because you can apply voltage vector/magnetic field perpendicular to rotor flux.

alignmentTimer is configurable parameter and it gives some time to rotor to be properly aligned with new required position. 

BLDC control with Hall sensor doesn't need this alignment process. It can be bypassed.

Regards,

Marek

0 Kudos

931 Views
sarwath
Contributor IV

Hello @marekmusak ,

Thanks for your response.

In MCSPTE1AK144_BLDC_6Step code both (sensor based/sensorless ) is using the alignmentTimer parameter. If I remove the alignmentTimer parameter (sensor based) motor is not rotating from particular sector (sector 2), then I added alignmentTimer. After adding it can able to rotate from all sector.

I attached my project in this same thread (without adding the alignmentTimer), Please have a look and let me know what I am doing wrong.

0 Kudos

838 Views
sarwath
Contributor IV

Hello @marekmusak ,

 

With the help of hall sensor feedback I got the actual rotor position.

During start up, I gave duty cycle to 90 % once the motor start the duty cycle is controlled by the potentiometer. In few sector I am not getting the smooth start if I increase the POT value the motor is not rotating it is cogging then I deceased the POT value again I started increasing now it is rotating . what I understood is it taking time in few sector. I don't know the reason. I have attached my test result (CW and CCW). Please have a look and let me know your thoughts.

sarwath_0-1666246927926.png

Note :  STATUS green for good start and red for bad start.

BR,

Sarwath

 

 

Tags (1)
0 Kudos

953 Views
marekmusak
NXP Employee
NXP Employee

Hello,

These two bit fields control OUTMASK and SWOCTRL of the Flextimer (FTM) in order to create complementary unipolar PWM (see AN12435 Figure 6).

Output Mask register (OUTMASK) provides a mask for corresponding FTM channel and Software Output Control register (SWOCTRL) actively force FTM channel to predefined value.

So for the 0 commutation sector we apply:

  • Mask 0x34 in hex format and 0011 0100 in binar format.
  • SW control 0x0808 in hex format and 1000 0000 1000 in binar format

So output of the FTM channels for 0 sector is:

  • FTM3_CH0  generates PWM
  • FTM3_CH1  generates PWM
  • FTM3_CH2  is masked (OFF)
  • FTM3_CH3 is actively controlled to high
  • FTM3_CH4 is masked (OFF)
  • FTM3_CH4 is masked (OFF)

marekmusak_0-1663929973391.png

See detailed description in application note AN12435.

Regards,

Marek

0 Kudos

951 Views
sarwath
Contributor IV

Hello @marekmusak ,

Thanks for your explanation.

what is alignment vector? why it is required in BLDC motor control.

In MCSPTE1AK144_BLDC_6Step code (sensor based), after the alignment vector initialized there is delay (alignmentTimer) it is decreasing from 20,000 to 0. why this delay is required.

/*******************************************************************************
*
* Function:     void AppStopToAlignment(void)
*
* Description:  BLDC application STOP to ALIGN state transition function
*
*******************************************************************************/
void AppStopToAlignment(void)
{
    driveStatus.B.Alignment = 1;
    driveStatus.B.EnableCMT = 0;
    driveStatus.B.CloseLoop = 0;
    driveStatus.B.Calib = 0;
    driveStatus.B.Sensorless = 0;
    driveStatus.B.NewZC = 0;

    alignmentTimer = mcat_alignDuration;
    duty_cycle = MLIB_Mul(MLIB_Div(mcat_alignVoltage, U_PH_NOM), 100.0F);

    // Update PWM duty cycle
    ACTUATE_SetDutycycle(duty_cycle, HW_INPUT_TRIG1);
    /* Apply PWM settings for motor alignment */
    ACTUATE_SetPwmMask(ui8FTM3OutmaskVal[0][6], ui16FTM3SwOctrlVal[0][6], HW_INPUT_TRIG1);

    appState = APP_ALIGNMENT;
}

/*******************************************************************************
*
* Function:     void AppAlignment(void)
*
* Description:  BLDC application ALIGN state function
*
*******************************************************************************/
void AppAlignment(void)
{

    if(alignmentTimer == 0)
        {
            AppAlignmentToStart();
        }
}
0 Kudos

1,013 Views
petervlna
NXP TechSupport
NXP TechSupport

Hello,

I have asked kit owner to have a look at your query.

But meantime you can start with checking reference software, to find out where you did mistake.

https://www.nxp.com/design/development-boards/automotive-motor-control-solutions/arm-based-solutions...

 

petervlna_0-1663145445098.png

Best regards,

Peter

0 Kudos

992 Views
sarwath
Contributor IV

Hello @petervlna ,

Once  the feedback from hall sensor the output mask control and software output control is set to generate the pwm. I want to knew the logic behind this i,e 0x34 and 0x0808 for sector 0. How it is predefined.

sarwath_0-1663571106436.png

sarwath_1-1663571121389.png

 

In sample code, after the alignment vector initialized there is delay (alignmentTimer) it is decreasing from 20,000 to 0. why this delay is required.

sarwath_2-1663571511140.png

 

Thanks in advance,

Sarwath

0 Kudos