2018-09-06 01:50 AM
Hello!
I'm experiencing difficulties using STM32-MAT-TARGET to generate code for STM32 controllers from Simulink models using the provided blocks for USART communication.
I'm using this setup:
The following pictures show my Simulink model:
Unfortunately, the program only does half the job. I observe that only one USART is actually receiving anything. The other just doesn't respond when I send it a byte. Either USART works if I have just one of them in my model. But with both USARTS in my model, one will work, the other won't. It seems to be whichever USART happens to get put into receptin mode first, will be the one that's working.
Can anyone help me with a solution to this problem? Is my setup correct? Does STM32-MAT-TARGET support this kind of operation?
Best regards
Roman
2018-09-06 05:22 AM
ask the supplier...
2019-12-02 02:23 AM
Hi @Roman Müller-Hainbach ,
Please keep in mind that the STM32-MAT/TARGET tool facilitates the development of the Simulink application and integrates it (sources of the model + customization of main()) into the final STM32CubeMX project.
You will notice that the initialization configured by STM32CubeMX is an integral part of the final project.
It is therefore normal for interrupts to be enabled if they are configured in this way in the STM32CubeMX project.
Hoping it highlights some details with the Simulink/STM32CubeMX collaboration to bring your applications.
Regards.
Cyril