Guy and Seth on Simulink

Results for: Code Generation

Tracing Requirements to Models, Tests, and Generated Code 2

Posted by Guy Rouleau,

Tracing Requirements to Models, Tests, and Generated Code When I wrote a post about the R2013b new features, Fraser replied in a comment that one of his favorite new feature is the requirements linking to MATLAB code. This made me realize that I never described on this blog how Simulink Verification and Validation allows the tracing of requirements to... read more >>

A Tweeting S-Function for the Raspberry Pi 7

Posted by Guy Rouleau,

A Tweeting S-Function for the Raspberry Pi I recently bought a Raspberry Pi. After trying a few of the demos included with the Simulink support package for Raspberry Pi, I began thinking about what I could do next. Just for fun, I thought... could I get a Simulink model deployed on the Raspberry Pi to send Tweets? Sending Tweets... read more >>

Creating Driver Blocks for Arduino, Lego, and other targets 2

Posted by Guy Rouleau,

Creating Driver Blocks for Arduino, Lego, and other targets As you may know, it is easy to run Simulink models on a set of supported target hardware. This has been possible since R2012a. Even if we add more targets and support more features for each target with every new release, it is still possible that you will need a driver... read more >>

To Latch or not to Latch?

Posted by Guy Rouleau,

To Latch or not to Latch? Yesterday I explained to a colleague the effect of the Inport block option Latch input for feedback signals of function-call subsystem outputs . I thought it would be interesting to share here. The Problem In the following model, inside the calib function-call subsystem, the Count signal is connected to a Unit Delay block. When... read more >>

Data Dependency Violation Errors and Subsystem Semantics 1

Posted by Guy Rouleau,

Data Dependency Violation Errors and Subsystem Semantics Did you ever receive a "data dependency violation" error message from a Simulink model? I will try to explain why this happens and what you need to do to avoid this error by introducing my favorite set of Simulink examples. Function-Call Subsystems To begin, let's explain how a Function-Call Subsystem is executed. In the... read more >>

Where is the Reverse Multi-port Switch Block? 2

Posted by Guy Rouleau,

Where is the Reverse Multi-port Switch Block? I recently noticed requests for a block implementing a behavior that might be called "Reverse Multiport Switch". You can find a few request like that on MATLAB Answers here and here. In my opinion, the difficulty for users to implement this behavior is in-part due to a problem with word selections.... read more >>

Model-Based Design Dilemma 15

Posted by Guy Rouleau,

Model-Based Design Dilemma I am currently working on a model and I have a dilemma. There are two ways I could model my system. I need you to tell me which approach is best and why. I need your help! The Goal I am building a model to drive a small robot made of Lego blocks.... read more >>

Generating Code for Real-Time Multicore Systems 2

Posted by Guy Rouleau,

Generating Code for Real-Time Multicore Systems Do you generate code to be executed on a multi-core processor? Wouldn't it be cool if you could decide which part of the model will execute on which core? Modeling Concurrent Execution This week, my friends Teresa and Tunc, will be introducing a new feature in R2011b designed especially for... read more >>

These postings are the author's and don't necessarily represent the opinions of MathWorks.