Hello,
I am using S32K396-BGA-DC1 board, with Simulink in matlab2024a. I am working on the S32K396_MBDT_BASED_MC_0_9_0 Motor Control Example Project.
In my setup I have the nxp connected with a HIL-RT hardware emulating the power stage and a motor.
I would like to change the sampling & switching frequency relationship. I found that the Fsam = 0.5 Fsw. So when I change the period on the pwm channel - Fsw (fig 1), Fsam change in the same way.
Where can I set up this? I would like to be able to do Fsam = Fsw and Fsam = 2Fsw
Moreover, modifying this, should I change the configuration somewhere for the resolver also?
Thanks, Agustin.
已解决! 转到解答。
Hi Agustin,
In the demo, the MasterReload signal of the FlexPWM is used as the ADC trigger. For your requirement, please change the following item:
For more details please refer to the Reference Manual, Chapter eFlexPWM, register Submodule a Control(SM0_CTRL-SM3_CTRL).
Thanks,
Vincent
Hi Agustin,
In the demo, the MasterReload signal of the FlexPWM is used as the ADC trigger. For your requirement, please change the following item:
For more details please refer to the Reference Manual, Chapter eFlexPWM, register Submodule a Control(SM0_CTRL-SM3_CTRL).
Thanks,
Vincent