frequency mesurement of a square wave
Show older comments
hi I want to to measure the frequency of a square wave with simulink , do anybody know how to do this? thanks
Accepted Answer
More Answers (1)
MoeIsKing
on 24 Jun 2018
Edited: Image Analyst
on 24 Jun 2018
If i run:
highSignals = signal > halfMaxValue
over my signal i get:
"Error using horzcat
Dimensions of arrays being concatenated are not consistent."
What did i wrong? My "highSignals" type is "2002x1 logical" after I run:
highSignals = volts > halfMaxValue ;
halfMaxValue is 12 and volts comes from a scope (light bar) and is imported as csv into "2002x1 double"
1 Comment
Image Analyst
on 24 Jun 2018
It looks OK to me. What I don't understand is how you could execute the line to create highSignals successfully as a 2002 by 1 vector, and yet still have an error thrown? In my experience if an error is thrown, you will not get the result put into the output variable. Can you explain that? Exactly what line of code are you executing when the error is thrown?
Categories
Find more on Simulink in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!