ni.com is currently undergoing scheduled maintenance.

Some services may be unavailable at this time. Please contact us for help or try again later.

VeriStand

cancel
Showing results for 
Search instead for 
Did you mean: 

model parameter initial value

Hi all,

I'm a newbie in VeriStand 2010, and I'm struggling to solve this issue

 

How can I set the startup values of my model's parameters?

 

I'm able to export them in Simulink, and i see them in VeriStand.

But I'd like to modify at startup of simulation.

 

How can I do?

Can I write a "Procedure" which calls a Calibration (.m) file at simulation startup?

 

thanks

R

0 Kudos
Message 1 of 7
(7,796 Views)

Hi,

 

You can try to visit this page:

 

http://forums.ni.com/t5/NI-VeriStand/How-do-I-create-a-startup-procedure-in-Veristand/m-p/1219694?re...

 

Have  a great weekEnd!

 

Clod

0 Kudos
Message 2 of 7
(7,780 Views)
A procedure can't load an m file, however, when you add the model to the system definition you can specify that it starts paused. Then by the time you get the workspace up after deployment, you can use the model parameter manager to load an M file, and then use a model control to start the model. There is also a way to automate this with the API if you're interested.
Stephen B
0 Kudos
Message 3 of 7
(7,773 Views)

Thanks for response!

It's a good idea to start the simulation paused... but I'm becoming greedy to idea of using API.

 

How can I use them?

Need I to have VeriStand running to use them?

Can I integrate executable/ironpython in VeriStand Workspace?

 

Thanks!

R.

0 Kudos
Message 4 of 7
(7,767 Views)

Hi Primusucks.

 

The way that worked best for me was not to use parameters but define the parameter values as inputs. Then I mapped some User Channels to these inputs.

I am not sure if you can do that with Simulink models. With LabVIEW models it works.

With this solution undefinded or zero-value parameters can be avoided.

 

Is that fine for you?

0 Kudos
Message 5 of 7
(7,737 Views)

Thanks for response,

but I'm forced to modify parameters because I cannot modify Model's DLL....

 

Bye!

0 Kudos
Message 6 of 7
(7,729 Views)

Hi,

 

VeriStand has the Off-line API that allows you to change the Inports and Outport default values. With this I was able to define the model´s input values while it is in pause always you deploy the SDF.

 

You can write a LabVIEW code to write new values to parameters or inports any time after deploy (I believe that is this that you want) using VeriStand API.

 

We use both approaches in our application.

 

Cheers,

 

 

 

CHCastro
0 Kudos
Message 7 of 7
(7,447 Views)