Questions tagged [simulink]

Simulink® is an environment developed by The MathWorks for multidomain simulation and Model-Based Design for dynamic and embedded systems.

Simulink® is an environment developed by The MathWorks for multidomain simulation and Model-Based Design for dynamic and embedded systems. It provides an interactive graphical environment and a customizable set of block libraries that let you design, simulate, implement, and test a variety of time-varying systems, including communications, controls, signal processing, video processing, and image processing.

Some useful links:

2873 questions
0
votes
1 answer

Setting dimension of signal in Simulink/MATLAB function from workspace

Suppose I have a Simulink block that contains something like: function y = myFnc(x, par) y = zeros(1, par(1)) + x; I declare par as a Parameter in the model explorer and read its value from the workspace. Now, Simulink infers that y is a…
Rubi Shnol
  • 172
  • 9
0
votes
1 answer

Interaction XBOX Controller with Simulink Model

I'm working in a project where i have to control a Robot (I have it already as a Simulink Model) with an XBOX Controller. Until now I couldn't find a good Example or a good Idea to let these two interact. I want to change some variables (INPUTs)…
Slachcrash
  • 27
  • 1
  • 6
0
votes
1 answer

step and impulse function in simulink

How can I fix this error? K = [ 1 2 3 ]; for i = 1 : N numerator = [ K(i) 0 ]; denominator = [ 1 ]; sys = tf(numerator, denominator); step(sys, t); impulse(sys, t); end Error using DynamicSystem/step (line 95) Cannot simulate…
0
votes
1 answer

Error in All sample times for this block must be discrete. No continuous or constant sample times are allowed

I'm designing DSS System, the problems is when I execute it this error occurs: Error in 'DSS_System_withANFIS/Synchronization Unit/Acquisition/Integrate and Dump1': All sample times for this block must be discrete. No continuous or constant sample…
Rasool Ahmed
  • 175
  • 1
  • 4
  • 13
0
votes
0 answers

Is it possible to provide values from MATLAB function to Simulink in the real time?

I created a matlab function in a Simulink environment which gives 200 values. I would like to use those 200 values for 2 seconds. Basically mapping the time.
0
votes
2 answers

How can I store dynamically a vector in a For iterator Simulink Subsystem?

I have this simple system: The code in the function is: function a = fcn(iteration,a) a(1,iteration) = iteration; end The outside Simulink layer is the following (a is initialized as a = zeros(1,5)): The loop is: for i = 1:5 and I want to store…
0
votes
1 answer

Case Statement in Simulink

I am just not able to figure out how to proceed: I am trying to build a model: It would have 4 Inputs ( Boolean i/p) It would have 1 output (Signed: 8 bit) It would perform the following: Based on which input is 1, it would give a corresponding…
Kiran
  • 8,034
  • 36
  • 110
  • 176
0
votes
1 answer

How to connect current measurement?

I'm trying to run this DC simulation, but I cannot connect the current measurement block to the circuit! Thanks.
Balawi28
  • 119
  • 7
0
votes
1 answer

dSPACE ControlDesk error - No free memory available.[0.000]

When using a large sampling rate, no data could be measured (displayed yes but not plotted/stored) and I get the following error from the log file: ControlDesk NG Platform: Error 16:19:41 0,0:No free memory available.[0.000] (0xCA,1) dSPACE…
Simon Sultana
  • 235
  • 1
  • 2
  • 13
0
votes
1 answer

Extracting data specified in SIMULINK components to MATLAB

Good day, The issue is related to getting the data that specify the characteristics of components in SIMULINK. I have the solar module block in SIMULINK. When I double click on it, many parameters are displayed. These parameters can be changed by…
0
votes
0 answers

how to make a simulink process repeat on a loop?

I am a begginer at Simulink. Before running the simulink project I initialize this two variables: T = [0 1]; A = [0 3 4 5]; This is the simulink process And this is the matlab function [y,To] = fcn(u,t) y =[0 ; u+t]; To=[0 t+1]; As can be seen…
JPgiq
  • 74
  • 9
0
votes
1 answer

Unable to load a message catalog 'SimulinkCoderApp:codeperspective'. Please check the file location and format

I'm trying to use Simulink coder to generate C code from my models. I installed the add-on (and also the matlab coder one). Matlab coder generate without trouble the code for simple systems, but there's no way I can generate anything with Simulink…
Mdesp
  • 1
  • 1
0
votes
0 answers

Dymola-Simulink interface: Error in newDymolaGuiJava

I am working on a model in Dymola and use the Dymola S-block in Simulink to compile the model and then run the model in Simulink. After a few compilations, the interface stops working with the error in the Matlab workspace as Error using…
0
votes
0 answers

How to implement a time dependent exponential function in Simulink

This is the equation I am trying to implement. I am using Simulink integrator block and simple algebraic blocks for it. How can I implement the last part (t-tk) because I don't know how to use the simulation time(t) in simulink.
0
votes
1 answer

Is it possible to build a (1/a*s+b) subsystem block with individual blocks in simulink?

I'm trying to build a subsystem in simulink with 3 inputs and those would be 2 constants (a and b coefficients) and the input signal (a step, for example). And inside the block it should work as a transfer function (1/as+b). I've tried somethings…