I'm working in Setting the base development environment for a DC/DC power converter.
This converter will be based on a interleave topology and them we need to control 3 half bridges basically working at 120º phase shift.
I’m using 1.4.0 MBD toolbox version with the R2022B matlab release.
I’m also using the NXP Configuration tool instead of the Tresos one.
As we need to keep in control the Phase shift we would like to work with the eMios channels configured in the OPWMCB mode. The idea is to implement the following scheme.
I started from one of your sample projects (S32K344_pwm_center_aligned_ebt) modifying it and its configuration in order to adapt it to our requirements.
I this process I’m facing two different problems.
The problem is that for the first of the channels updated, the Duty Cycle is no updated and its output is frozen to its default value (The one configured in the config tool). This happens always with the first channel that is written in the model. As you can see, I first wrote to the channel 1 and detect the problem in this channel. Then I configure a 4th channel to see is there was a problem with the number of configured channels, and everything works in the same way (channel 1 frozen to its default value and the three other channels changing its DutyCycle). The last test was to comment the write to the first channel. In this scenario, the problem appears on the second channel instead of the first one.
Could you give some clue on these problems?
I solved the first problem.
It was my fault as I hadn't configured the LCU input multiplexer in the right way.
The second problem is still there. The first pwm eMios channel is hook to its default value despite the generate code is writing to it the new value.
Now I will procced to export the code to DS and procced to debug it.
Hello,
I have met the same problem with your first problem. Could you explain in some detail about your fault? What's wrong with your configuration exactly?
Hello @RegulusCheng
First, I would recommend you to start by checking our s32k344_pwm_trgmux_lcu_adc_ctu_ebt example which can be found in the following path: <toolbox_root>/S32K3_Examples/pwm\s32k344_pwm_trgmux_lcu_adc_ctu_ebt.
The application demonstrates how LCU is configured to output 3 phases based on EMIOS signals sent via TRGMUX, and I think it would be a good starting point for investigating your problem, as the model and its associated configuration project, provide the necessary information on what functions should be called inside the application, and what are the required components configurations for enabling the LCU outputs.
In case this application does not provide the necessary information, please let us know more details on your use case so we could provide further guidance.
Thanks,
Irina