06-03-2014 12:01 PM
Hi ,
I want to convert my simulink model to a VI
I have attached the .mdl file
Please help me in the conversion
I am not able to find the substitute for a clock function which is acting as an input as u[1]...it is a unit step signal , increasing linearly with time
06-03-2014 12:03 PM
the .mdl file is here:
06-04-2014 12:37 PM
Could you describe a bit more about what you are trying to program in LabVIEW? If you need a step function, you can find the Step Function.vi under Functions >> Mathematics >> Elementary & Special Functions >> Gating Functions >> Step Function.vi, on the functions palette on the block diagram.
I hope this helps. If you need something more specific then that, a detailed description would make it easier to find the necessary VIs.
06-04-2014 04:03 PM
Hi,
Thanks for responding.
Actually I am working on a Simulink project which is to be converted in a Labview VI
The block that I want to replace in Labview is a Clock signal (which is in the .mdl file attached)
The clock signal, which is used from the Simulink Library is having the trend of linear increasing value with time elsapsed with the decimation value as 10.
All the clock signals in the Labview are related to the clock staring from 1904.
The trend of the clock is attached .
the x-axis value is changing wrt every second since the simulation has started . Y-value is X-value.
06-04-2014
04:45 PM
- last edited on
04-26-2025
06:08 PM
by
Content Cleaner
In addition, if you have the LabVIEW Control Design and Simulation Module, it has a feature that allow you to Convert models from other vendors into LabVIEW.
http://www.ni.com/white-paper/11281/en/
06-04-2014 05:58 PM
Hey ,
I tried this but no success !!!
06-05-2014
02:03 PM
- last edited on
04-26-2025
06:09 PM
by
Content Cleaner
If you want to just call your model from LabVIEW you can try the Model Interface Toolkit. If you just want a clock signal as you've described it, it looks like you just need a loop running at 1 second per iteration and an indicator coming from its iteration terminal. Another option is using the tick count VIs if you want the actual time elapsed instead of just a count. I've coded both in the example below. Is this what you were looking for?
06-06-2014 12:25 AM
Thanks for the reply
Things are working, I had to modify the thing accordingly.
Anyways, I want to transfer the value of iteration count from while loop to control simulation loop.
How do I achieve this as I can't connect through loop tunnel.
06-06-2014 04:51 PM
You should be able to just use a local variable for this. You can right click the indicator on your block diagram and select Create >> Local Variable. You can then access the value in your local variable from your control and simulation loop.
06-06-2014 05:11 PM
Hello Miles,
Thanks for your quick response,
I id as you said but only one value is latched in control simulation loop, ie the startin value , while the output in while loop is continuosly running
I have attached my .iv