Effacer les filtres
Effacer les filtres

Set constant value in a constant block from gui to simulink (working with f28335 target)

2 vues (au cours des 30 derniers jours)
Hi, I have a trouble using gui with simulink. It consists in the impossibility to send one constant value from gui to simulink usign one constant block and then send it to f28335 target througth SCI. The constant value (gui) is established in the constant block (simulink) correctly, but it is not sent to the target f28335 during the simulation. The value is sent only when I make a mouse click in the simulink window. Is there any matlab command to activate the constant block from gui? For example: simulating the "ok" button of the constant block.
Thank's
Best regards.

Réponses (1)

Andrew Schenk
Andrew Schenk le 17 Juin 2015
To update Simulation workspace variables while External mode is running, add the following code to your GUI callback function:
set_param(bdroot,'SimulationCommand','update')

Catégories

En savoir plus sur Block Libraries dans Help Center et File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by