Respondida
Simulink StateFlow Variable assign
The code gets executed when entering the "Modes" state and every simulation step while the Modes state is active. To understand...

casi 9 años hace | 0

Respondida
How to define a 16 bit storage in simulink?
You could try using a <https://www.mathworks.com/help/simulink/slref/datastorememory.html?searchHighlight=data%2520store%2520mem...

casi 9 años hace | 0

| aceptada

Respondida
Custom sensor library: Execute setup block before others
do you need to execute the configuration block each time "read value" block executes? If so, I use function -call trigger and t...

casi 9 años hace | 0

Respondida
How to process CMEX S-Function blocks with variable steps until no signal changes? (Model is interacting with TwinCAT 3)
In your design, the s-function blocks will run only once each time a pulse occurs. If you want the s-function blocks to run N t...

casi 9 años hace | 0

Respondida
How to determine a sim. model is being run by itself or as a referencede model?
On the "Data Import/Export" tab of the configuration settings, specify "Input" values for all input ports in the "Load from wor...

casi 9 años hace | 0

| aceptada

Respondida
Level 2 C++ S-function not showing multiple input output ports
code looks OK. In your Simulink S-Function block, did you create a mask with 207 parameters and pass all 207 parameters in the ...

alrededor de 9 años hace | 0

| aceptada

Respondida
How to declare and use local variable in level 2 s-function?
You will need to set up a "DWork" variable that gets assigned a value in the mdlStart() function and can then be used in the mdl...

alrededor de 9 años hace | 1

Respondida
Loading model into older version of Simulink
Yes, these warnings are due to a version mismatch. You can eliminate these warnings by opening the model in R2015b and then usi...

alrededor de 9 años hace | 0

Respondida
Connection between two PCs with Simulink
The solution depends on whether you need real-time performance. If real-time performance is not needed, then you can run Simuli...

alrededor de 9 años hace | 0

| aceptada

Respondida
Stateflow code generation - how to generate void instead of static void functions?
You could try re-architecting your Stateflow code to use graphical functions. This <https://www.mathworks.com/help/stateflow/ug...

alrededor de 9 años hace | 0

Respondida
How to fix gmake error 43?
Although part of the error text is not readable, it looks like problem is related to parameters used in the model. It looks lik...

alrededor de 9 años hace | 0

Respondida
Problem using field of structure parameter as constant block value.
You didn't state this, but I assume that RTIP_Param is a Simulink.Parameter? If so, try using RTIP_Param.Gain1. In this case, ...

alrededor de 9 años hace | 0

Respondida
How to generate static keyword on local functions
It is currently not possible to do this in Embedded Coder.

alrededor de 9 años hace | 0

Respondida
Return Array Pointer with ceval
As described in the <https://www.mathworks.com/help/simulink/slref/coder.ceval.html help> , coder.ceval() can only return a scal...

alrededor de 9 años hace | 1

Respondida
Using DDS with Simulink/MATLAB that isn't in the defualt installation location
Hi Eric, Currently the DDS Blockset is set up to use the same DDS libraries for both simulation and code generation, which is o...

más de 9 años hace | 0

Respondida
Simulink: dynamic link library initialization routine failed
Simulink gives this error if any depdendent DLL's cant be found at runtime. Make sure canlib32 is on the windows path.

más de 9 años hace | 0

Respondida
Create test harness automatically for SIL testing of a model (Embedded Coder)
Yes, test harnesses can be created from referenced models. If you have an SL V&V or SLDV license, you can use slvnvmakeharness...

más de 9 años hace | 0

Respondida
StateFlow symbol could resolve to multiple data?
I am guessing that the duplicate symbol error is from the argument you are using for the MATLAB Function. Try changing the argu...

más de 9 años hace | 0

Respondida
How can I multiply each bus element with a constant?
This can be done easily with a ML Function block. Code in ML Fcn Block: y = u; elemNames = fieldnames(u); for i=1:numel(el...

más de 9 años hace | 0

Respondida
Inserting a space when printing characters using fprintf
You must have stripped out the spaces in m20 before printing. Either add spaces back into m20 before printing or change print st...

alrededor de 10 años hace | 2

Respondida
Help needed!!!The function accepts two years and returns the number of days within that interval
function days = days_between_years( firstYear, lastYear ) days = 0; for i=firstYear:lastYear for j=1:...

alrededor de 10 años hace | 0

| aceptada

Resuelto


Wind Chill Computation
On a windy day, a temperature of 15 degrees may feel colder, perhaps 7 degrees. The formula below calculates the "wind chill," i...

alrededor de 10 años hace

Resuelto


Find all elements less than 0 or greater than 10 and replace them with NaN
Given an input vector x, find all elements of x less than 0 or greater than 10 and replace them with NaN. Example: Input ...

alrededor de 10 años hace

Resuelto


Determine if input is odd
Given the input n, return true if n is odd or false if n is even.

alrededor de 10 años hace

Respondida
Finding period T from a square signal in Simulink
Feed signal into triggered subsystem. Configure triggered subsystem to active on rising edge. In triggered subsystem, use a Dig...

alrededor de 10 años hace | 0

| aceptada

Respondida
S-functions with Legacy Code Tool (LCT) in SIL and PIL
Yes the else branch will be used for code generation, which includes SIL and PIL

más de 10 años hace | 0

Respondida
Error calling char variable from C code by function block of Simulink
Coder.feval can be used for simulation and code generation. The problem is that your function is supposed to return a single cha...

más de 10 años hace | 0

Respondida
In what format does Simulink export signals?
Since the data type of the signal is double, Simulink would send 8 bytes (64 bits) representing the number in IEEE 754 format. ...

más de 10 años hace | 0

Respondida
How do I get the SFunction builder to create an SFunction that uses a signed 64 bit integer as input/output?
If you can't migrate to 16a, then here is how you can work around it. It will require you to manually change your .c file and ....

más de 10 años hace | 0

Respondida
How do I get the SFunction builder to create an SFunction that uses a signed 64 bit integer as input/output?
Hi Chris, It appears that there is an error in s-function builder in 15b. I was able to reproduce your problem in 15b but then...

más de 10 años hace | 0

Cargar más