Top 1% contributor
I tried fread() and it gives the 18.6KB size.
Answered 5 months ago
Thanks. It works, but there is still a problem with size matching. An JPEG file has the following parameters: 18.6KB, 242x379, b...
is it possible to convert an JPEG file into an array in Matlab? What about the reverse conversion?
Asked 5 months ago
What about with Simulink?
Answered 2 years ago
I've made it with an Embedded Matlab Function. For the sample time for each element I use the Repeating Sequence Stair block. Th...
Answered 3 years ago
With my configuration the string "variable1" is showed in the block dialogue. When I input the number 10 in the parameter field ...
can anyone show me how to convert a 10x1 vector into 10 scalars with an Embedded Matlab Function?
I just don't know...
Asked 3 years ago
I think I have found the reason. The CRC-32 which I want to use is according to the following statement:
_The payload FCS is ...
The problem is solved. The error is because the Random Number Generator block generates frame based data. A Buffer block of leng...
My goal is, simulate a model with 'sim()' in an m file, but the variable 'simout' seems not to be defined in the m file, which i...
It works but now I want to trigger the generation with a rising edge, so the code
With your advice I write the following code:
I tried following code in a Embedded MATLAB Function block.
function y = fcn(n)
i1 = 0;
var = isnan(n);
len = leng...
All non-NaN elements come before NaN elements, but the number of non-NaN elements can be variant. The output lengt...
Thank you you both.
I must add that the vectors come one after another, which means, my model shall process only one vector a...
Could you please recommend some implemetations in this direction? I’ve read some articles about the s function template sfuntm...
3 years ago
Hi, I have a Simulink model, which outputs its frame based data into a variable ‘simout’ in workspace. ‘simout’ is then a colum...
3 years ago
Yes, I tried this option, but frame based data is not supported by this option.
Thank you, but I don't intend to set parameters during simulation, but before any simulation. In fact I must set the parameters ...
Is it possible to control parameters of a simulink block with another block? Say create a block which controls the 'seed'...
I have a special work for Simulink with which Simulink is maybe overloaded.
Many vectors of length 10 shall be process...
I would appreciate it if you can explain something, not just say something that doesn't help. That’s what this place is for. Ow...
2 years ago
Hi, In the AWGN block there are two parameters: “Signal to noise ratio” and “Input signal power, referenced to 1 ohm (watts)”. ...
2 years ago
I want to write an Embedded Matlab function to store the ramdom number of the Random Generator block into a vector, somet...
I have created a variable 'simout' with the To Workspace block in Simulink. Now I have to use this in a m file, but an er...
I try to understand the methods Update and Outputs in S function. Please tell me if my understanding is correct. Thank yo...
I’d like to control the sample time of output so that this output under some conditions comes out only once. Now there ar...
Is it possible to realize the following with Level 2 S function?
The input is a binary data, that is, every time only ...
I want to write an Embedded Matlab function with 2 inputs and 1 output.
Input1: an integer
Input2: a trigger
Join the conversation