I would like to introduce you to Madhu Govindarajan from MathWorks who will be writing interesting blog posts for next several weeks. Thanks Madhu!
Hi everyone! Madhu here - I thought for today’s post I will share the answer to a frequently asked question during the recent Autonomous Fighting Robots Challenge (AFRC).
Flexibility to build and expand existing solutions is one of key aspects fueling the Maker movement. I want to share how Simulink in essence supports the same thought process. For example, look at this fun video from the robotics contest where the autonomous robots were designed completely using the Simulink support package for Arduino and custom-developed blocks based on S-function builder.
Although there are several ways to bring in external C code from the open-source libraries into Simulink environment, S-function Builder provides a User Interface that helps understand and simplify the process.
Here's a link to a set of files authored by my colleague Giampiero, which contains a step-by-step tutorial to create your own Device drivers using S-function Builder. This file not only inspired the Encoder blocks (used to measure the speed of the fighting robots) and Serial communication blocks (used to control their on/off switch) but also others mentioned in the Acknowledgement section on the link. So in essence Simulink has ways to accommodate existing external libraries, hence allowing makers to feel more empowered than just using MATLAB, Simulink and the support packages.
After all, software is nothing but pencil in the hands of the creator.