Deploy C/C++ Code from Simulink to Arduino
37 次查看(过去 30 天)
显示 更早的评论
Hello all,
I have developed a fan controller in Simulink for an Arduino MEGA and operated the system in "external mode" (inputs: potentiometer-->speed setpoint, Hall signal-->speed actual value). This works wonderfully.
I would now like to pass the model on to a colleague who, however, does not use Matlab/Simulink. Is there a simple way to compile the "fan_controller" and integrate it in the Arduino IDE as fast and easy as possible?
I have searched here in the forum as well as in the web for solutions, however the information there did not help me, since I am a newcomer to the topic of Arduino and therefore need as "simple instructions" as possible.
I am grateful for any help!
Kind regards
Felix
0 个评论
采纳的回答
Ritish Sehgal
2022-7-1
It is my understanding that you want to deploy C/C++ code generated from a Simulink model to Arduino Mega target board.
You can use Simulink Support Package using which you can deploy your code on Arduino Mega board. Your model will run as standalone, i.e. independent of the Simulink environment on the board.
I have attached the link to the video which shows the installation of the Simulink Support Package in your system:
Below is a link to the documentation which gives an example of how to use Simulink Support Package with Arduino hardware:
If you wish to learn more about Arduino and its concepts you can refer to the link below which includes interactive Arduino projects:
Hope it helps!!
1 个评论
Azizhan
2023-9-7
Hi,
I think you didnt answer the his question. There is no explict information How we can use the Embedded coder to link and build for arduino devices. I have support package but I dont want to use, I want to pack all the artifacts and compile externaly using avrdude or equivalent compiler via comand propmt or visual stuido code. We are developping a real product and we need to use later on some certificated compiler. Could you give some example or clear instructions?
Thanks.
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Modeling 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!