MATLAB Answers

0

Is there a switch that turns on for a specific amount of time? That does not depend on the system's time.

Asked by Aggariyo Wanagiri on 15 May 2019
Latest activity Commented on by Aggariyo Wanagiri on 30 May 2019
Is there a switch in simulink that turns on for a specific amount of time then turns off?
For context, the orange signal runs for 1s and I want a switch that becomes closed when the orange signal < 0 and sends a yellow signal that runs for 0.5s.
Capture.PNG
Currently i am using a switch that is set at >= -0.00001 (when the signal goes down)
Captur22e.PNG
Any help is appreciated! Thank you!

  1 Comment

I need something like this. This is done manually with a pulse generator, but I need it to be conditioned by the orange signal.
Capture3.PNG

Sign in to comment.

Tags

Products

1 Answer

Answer by Shivam Sardana on 23 May 2019

An Enabled Subsystem can be used for your requirement. Whenever orange signal is less than 0, an enabler can be set to 1 and send to Enabled Subsystem which runs yellow signal for 0.5 seconds. A Switch can be used whose output can be passed to Scope.

  1 Comment

How do I run the yellow signal for o.5 seconds or 5 seconds? I see no time setting in the enabled subsystem.

Sign in to comment.