Hello!!
I am making Serial-to-CAN convert module using NXP S32K144 evaluation kit.
System configuration is as below,
(There are two serial communications and 15 digital Inputs in my Serial-to-CAN convert module.)
The Serial-to-CAN convert module transmits and receives 32bytes data between S32K144 and Touch Panel as below,
In my project, a serial communication between S32K144 and Touch Panel is stable and good if using the FlexIO UART Blocks in model based design toolkit.
However, the problem is when I use two touch panels as below,
When I just Run above program, there is no error. However, when I try to build the program, an error happens as below,
Please, help me out!!
Thank you very much.
For your reference, I set the FlexIO UART blocks as below,
Instance is set to 0 in case of vehicle touch panel. Instance is set to 2 in case of Robot Arm touch panel.
Solved! Go to Solution.
Hello kmun61a@gmail.com,
Could you replace the following files I have provided in the .zip attached here?
{TOOLBOX_ROOT}\mbdtbx_s32k\blocks\flexio_uart\flexio_uart_s32k_receive_isr.tlc
{TOOLBOX_ROOT}\mbdtbx_s32k\blocks\flexio_uart\flexio_uart_s32k_transmit_isr.tlc
[added] {TOOLBOX_ROOT}\mbdtbx_s32k\blocks\flexio_uart\flexio_uart_s32k_config.tlc
You can just rename the existing files by adding something like _old at their name and then copy these new files.
Please let me know if you're still facing issues with your model.
Kind regards,
Razvan.
edit: Also added changes to the config block (last file).
Hello kmun61a@gmail.com,
Could you share the model you are using? You can remove any proprietary code from it, as long as the issue is replicated. Thank you.
Kind regards,
Razvan.
Dear Constantin Razvan Chivu,
Thank you for your prompt answer.
I attached my Simulink code as you asked.
I am looking forward to receiving good solution.
Best regards,
Mr. Hyoil Kim.
Just wanted to mention that you can use regular UART blocks for your application. FlexIO is an adaptable peripheral that can emulate protocols like UART. You can read more here - [FlexIO] Flex your muscles with the latest MBDToolbox release. If you already knew that, sorry for the spam - just wanted to make sure you are aware of the difference between the UART blocks and the flexIO UART blocks.
Kind regards,
Razvan.
Hello kmun61a@gmail.com,
Could you replace the following files I have provided in the .zip attached here?
{TOOLBOX_ROOT}\mbdtbx_s32k\blocks\flexio_uart\flexio_uart_s32k_receive_isr.tlc
{TOOLBOX_ROOT}\mbdtbx_s32k\blocks\flexio_uart\flexio_uart_s32k_transmit_isr.tlc
[added] {TOOLBOX_ROOT}\mbdtbx_s32k\blocks\flexio_uart\flexio_uart_s32k_config.tlc
You can just rename the existing files by adding something like _old at their name and then copy these new files.
Please let me know if you're still facing issues with your model.
Kind regards,
Razvan.
edit: Also added changes to the config block (last file).
kmun61a@gmail.com, you are welcome!
Thanks again for posting cool demos showing us what projects you are working on using our toolbox!
Kind regards,
Razvan.
Please note that I have updated the zip by adding 1 other file that has changed - flexio_uart_s32k_config.tlc.
Even if the model was successfully building, the application would have not executed the ISR you expected for flexIO UART - now that is also fixed.
Kind regards,
Razvan.
Hello!! Razvan,
Thanks to your answer, my problem was clearly solved.
But, I have one more question.
I will upload it as a new question.
Thank you so much!!
From Kim.
< Serial to CAN >
Hello kmun61a@gmail.com,
Thank you for the video! Really nice of you sharing it with us!
I will see you on the other thread once you post it.
Kind regards,
Razvan.
Hello Constantin Razvan Chivu,
I have done it as you advised by replacing two *.tlc files.
Build error was not happened any more. However, I guess serial communication (rx data) is not connected between NXP and touch panel.
Because, there is no change in the FreeMASTER.
In addition, if NXP receives the data from touch panel, the Interrupt happens and the Blue LED should be blinked.
However, the Blue LED turns on, which means that the interrupt is not occurred.
And then, I tried another test.
I put the "FlexIO UART Transmit ISR block" inside function call block to outside as below (also as attached Simulink file)
A Build error is happened again as below,
I am looking forward to your answer.
Thank you very much.
Best regards,
Mr. Hyoil Kim.