In simulink, how to generate a square wave using an external source as frequency?
19 views (last 30 days)
Show older comments
I want to generate a square wave where frequency is coming from an external source. In simulink square wave block, frequency parameter is hard coded.
0 Comments
Accepted Answer
ES
on 3 Sep 2013
you can use a normal Pulse generator block in Simulink and use set_param command to set any of the parameters like Amplitude, Period, PulseWidth, PhaseDelay, SampleTime etc.
set_param('Pulse Generator Block','Period',12);
More Answers (0)
See Also
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!