Set certain value of signal when it goes above threshold.
7 views (last 30 days)
Show older comments
Hello, recently I have been trying to simulate this action in Simulink :
I have a velocity signal, I would like to make it control my valve in Simscape.
When value of velocity goes above set threshold, I want it to create a signal that has specific value and it last for specyfic peroid of time.
I have already tried several methods I have found on internet, but none of them seems working. I also have tried to make it by MATLAb function, but the only thing I have achived are detected peaks of signal.
Do you have any ideas how can I make it
0 Comments
Answers (1)
Fangjun Jiang
on 14 Apr 2021
Use the Relational Operator block to compare the signal against the threshhold value. The output is a true or false signal. Use this signal to trig (either edge or level) or enable an Enabled/Triggered subsystem. Inside the subsystem, provide the desiged signal. Some signal has the ability to specify duration.
2 Comments
Fangjun Jiang
on 14 Apr 2021
Not clear what is the problem based on your comments. Based on your original question, the solution is to let the trigger (the comparison aginst the threshold) determine the timing of the signal, and let your signal source inside the subsystem determine the "duration" of the signal.
See Also
Categories
Find more on General Applications in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!