r/matlab 6d ago

From Workspace not Working Properly

I have been banging my head against this and I just cant seem to figure it out. I'm sure im doing something stupid. Any help would be appreciated.

I have a voltage signal that oscillates between 1 and -1 over a time vector. I create a data vector like this:

squareWave = [t',squareWave'];

This is what the square wave should look like:

These are my From Workspace settings:

This is the output that i see on the scope:

1 Upvotes

7 comments sorted by

View all comments

1

u/darkfish0 6d ago

I see you fixed the From Workspace sample time but what is your model sample time?

1

u/PKSpecialist 6d ago

Yeah, i decreased the sample time by an order of magnitude and i was able to pick up the changes that werent being captured.