Skip to main content
OGisl.1
Associate
February 24, 2020
Solved

How can I configure Simulink to compile for the SPC58-4B?

  • February 24, 2020
  • 2 replies
  • 1659 views

I have a SPC584B-DIS discovery board, and I can see that on the Matlab website it's listed as being supported hardware for Simulink.

I have been trying to understand how exactly it should work though. I can see that most (all?)of the Simulink blocks are for STM32, and require an .ioc file generated with STM32Cube in order to link the hardware correctly. I understand that STM32Cube doesnt have anything for the SPC5 chips, and so I am wondering if there is a different method for working with them, or if they are not really supported as advertised by Mathworks?

https://de.mathworks.com/hardware-support/stmicroelectronics.html

This is the site im referring to. It does say "With the exception of the Nudeo and Discovery Boards, MathWorks does not offer an Embedded Coder Hardware Support Package for the devices listed on this page. " But again, I do have a discovery board and so I thought it would be covered. Can someone shed some light on how to approach this?

    This topic has been closed for replies.
    Best answer by Erwan YVIN

    Hello ,

    STM32Cube is not compliant for SPC5 family.

    Better to use SPC5Studio. (Eclipse based)

    https://www.st.com/en/development-tools/spc5-studio.html

    For your information , there a eclipse support from Embedded coder

    https://fr.mathworks.com/hardware-support/eclipse.html

    Best Regards

    Erwan

    2 replies

    Erwan YVIN
    Erwan YVINBest answer
    ST Employee
    February 26, 2020

    Hello ,

    STM32Cube is not compliant for SPC5 family.

    Better to use SPC5Studio. (Eclipse based)

    https://www.st.com/en/development-tools/spc5-studio.html

    For your information , there a eclipse support from Embedded coder

    https://fr.mathworks.com/hardware-support/eclipse.html

    Best Regards

    Erwan

    OGisl.1
    OGisl.1Author
    Associate
    February 26, 2020

    Hi Erwan, thanks for the reply!

    I had downloaded the SPC5 studio, but I didnt know about the eclipse support. Thanks for that, I will have a look.

    Is it possible, in that workflow to work entirely in matlab? I am hoping to be able to develop a process which does not require moving between matlab and another environment, because we will be working with students who have not so much background in IT. Or is it necessary to always compile the models, and then bring the code into SPC5Studio and then download the code to the board?

    Edit: Also, how are things like CAN bus then handled? In the STM32 there are blocks for communication.. does something similar exist for the SPC5 with the Eclipse Embedded Coder?

    Regards,

    Óttar

    Brian McKay
    Visitor II
    March 9, 2020

    The MathWorks Discovery Board support is only for 3 STM32 variants, not for SP5.

    Specifically: "Embedded Coder provides additional support for the STM32F746G, STM32F769I and STM32F4-Discovery boards that includes automated build and execution,"

    https://www.mathworks.com/hardware-support/st-discovery-board.html

    You can use MathWorks software to design, simulate, and generate code for your algorithms. To get the code on chip, you would import into an existing IDE project (probably in SPC5Studio), intergrate with drivers and other needed pieces of software there, there, and download and troubleshoot the code via the tools (SPC5Studio, etc).

    Cheers,

    -Brian