Saving modified variable values from a Simulink model running on Raspberry Pi
1 visualización (últimos 30 días)
Mostrar comentarios más antiguos
I have a Simulink model that runs on a Raspberry Pi which recieves values from a CAN bus, and then outputs some CAN messages. There are a number of values, I call them parameters, that are used to process the inputs and calculate the output values. Currently I set the values of these parameters in a .m file that is referenced by the model. I have made a way to change these values while the model is running on the Raspberry Pi, but is it possible for me to modify variable values while it is running and have it save those values, so that after the RPi is shut down and started again it will remember the last saved value of the parameters? This would be much better than having to rebuild the model everytime I change the value of a parameter like I have to do currently.
0 comentarios
Respuestas (1)
Rasmita
el 13 de Mzo. de 2023
Hi Asa,
It is my understanding that, you want to save the modified parameter values without stopping or rebuilding the running model.
For this, you can use External mode with Raspberry Pi support package.
The External mode feature of Simulink helps you speed up the parameter tuning process, by allowing you to modify some parameter values while the model is still running on Raspberry Pi hardware. When parameter values are adjusted inside of Simulink, the modified parameter values are immediately transmitted to Raspberry Pi hardware.
You can refer to the Communicating with Raspberry PiTM Hardware documentation page to learn about External mode.
Hope this helps!
Regards,
Rasmita
0 comentarios
Ver también
Categorías
Más información sobre Raspberry Pi Hardware en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!