Answered
Simulink Coder - Customizing stateflow generated code
Unit delay block just have a state variables which stores the previous value of input. Similarly in Stateflow, you can use a ...

13 years ago | 0

Answered
Relation between header and Simulin.bus objects
*Q:* why does LCT needs the redundant simulink.bus object in the workspace if this information is already contained in the heade...

13 years ago | 0

| accepted

Answered
how does work S-Function block in simulink?
See *<http://www.mathworks.in/help/simulink/sfg/maintaining-level-1-matlab-s-functions.html Level-1 MATLAB S-Functions>*.

13 years ago | 0

Answered
how to call the simulink values into the m.file?
Write your simulink outputs to matlab's base workspace using *<http://www.mathworks.in/help/simulink/slref/toworkspace.html To w...

13 years ago | 0

Answered
mex file error on mac, works on windows
mex files are compiled binary code which are platform dependent. A mex file compiled for windows platform will not work on other...

13 years ago | 0

Answered
Modelling in simulink to obtain a function taking one parameter after code generation
Use *<http://www.mathworks.in/help/simulink/slref/switchcase.html Switch case>* block.

13 years ago | 0

Answered
Simulink Coder-Customizing grt.tlc generated source code.
There are very few code customization options are available with *GRT* target. AFAIK, there is no option in *grt* to remove the ...

13 years ago | 1

| accepted

Answered
How to call structure value in simulink?
Simply put *Test_Structure.a* or *Test_Structure.b* in constant block to use their values.

13 years ago | 0

| accepted

Answered
How to import the array format values in simulink one by one?
You can use *Signal Routing/Index Vector* block to select the elements of array.

13 years ago | 0

| accepted

Answered
Show image of variable Simulink model in Matlab GUI
If you want to display the image of simulink model in your GUI then you can follow the below steps * Suppose your model is *M...

13 years ago | 1

| accepted

Answered
Is it possible to give a hex input to stateflow chart from simulink?
What do you mean by hex input? If you mean hex represented number (like 0x5A), then it is just a representation of number. Yo...

13 years ago | 0

| accepted

Answered
How to obtain a header file with customized name on code generation from an enum defined in a script(.m) file in matlab?
You can generated the enum definitions in the separate header file using *HeaderFile* and *DataScope* properties during the defi...

13 years ago | 0

| accepted

Answered
I/O operations How to delete a file if exist?
You can open the file directly in write mode fh = fopen('ResultFile.txt','w'); If file already exists, this will over-wr...

13 years ago | 7

| accepted

Answered
Why can't I restore disabled links from a model StopFcn callback?
It could be because executing *StopFcn* is also part of simulation. And you can not modify the library link of a block during th...

13 years ago | 0

| accepted

Answered
How to put informations in a Simulink model?
You can write commands to generate your data inside model's *PreLoadFcn* <http://www.mathworks.in/help/simulink/ug/using-callbac...

13 years ago | 0

Answered
I was told to press a green button to accept an answer. But where is the green button?
Open your question (If you are reading this, then you have already opened a question). At the top of each answer to your ques...

13 years ago | 1

Answered
How to configure S-Function Builder from command line?
See *<http://www.mathworks.in/support/solutions/en/data/1-AWIVV1/index.html?product=ML&solution=1-AWIVV1 this solution>* on how ...

13 years ago | 2

| accepted

Answered
simulation control in m-file
set_param('ModelName', 'SimulationCommand', 'start') set_param('ModelName', 'SimulationCommand', 'stop') set_param('Mode...

13 years ago | 0

| accepted

Answered
How to choose the values from matrix
Do you mean something like this... Data = [1 2 3 4 5; 10 5 6 7 9; 20 8 47 9 6; 30 4 7 ...

13 years ago | 0

| accepted

Answered
what does mean : C:\Documents and Settings\Albert\errorbar.m
It means that you have written a script *errorbar*. Scripts never accepts or return argument.... And you are calling this script...

13 years ago | 0

| accepted

Answered
problem with working IF Block
Double click output ports in your if action subsystem and set *Output when disabled* property to *held*.

13 years ago | 0

| accepted

Answered
Using Simulink from code
First of all, purpose of simulink is to model the behavior of a dynamic system (mathematical and logical modelling). Making a in...

13 years ago | 0

Answered
How to use y1 y2 y3... variables in for loop?
Y = {y1;y2;y3;y4;y5;y6;y7;y8}; for j=1:8, subplot(1,8,j);bar3(Y{j});view(-90,0); end

13 years ago | 0

| accepted

Answered
Read strings from a text file and pass it to variables
fid = fopen('file.txt'); % Read all lines & collect in cell array txt = textscan(fid,'%s','delimiter','\n'); % C...

13 years ago | 1

Answered
What is xout variable?
*[Updated 1]* *xout* is the logged data variable contains state value of the model. * Goto Configuration Parameters > Data...

13 years ago | 0

| accepted

Answered
Problem with non tunable parameters of embedded matlab function
I tried same thing and found that it is working properly. Refer *<http://www.mathworks.in/help/simulink/examples/migration-to...

13 years ago | 0

Answered
How to change C-coder settings to create static variables in the "Model step function"?
There is no configuration option available to change the storage class specifier of variables in generated step function. Ins...

13 years ago | 1

Answered
creating .mat files with variables
a=10; b=rand(100,128); c=rand(116,128); d=rand(1,128); save('myfile.mat','a','b','c','d');

13 years ago | 0

| accepted

Answered
How do i pause simulink for a moment ?
Instead of puasing the simulation to collect data, use run time data access methods of simulink. Using these methods data can be...

13 years ago | 1

Answered
is it possible to generate multithread code from simulink model?
Find the below page on your simulink coder documentation Simulink Coder >> User's Guide >> Model Architecture and Design >>...

13 years ago | 0

Load more