O'Reilly logo

Control Software for Mechanical Systems: Object-Oriented Design in a Real-Time World by J. R. Ridgely, J. D. Ringgenberg, D. M. Auslander

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 5Software Realization In C++

If C or C++ is to be the target language, it makes sense to do the simulation in one of those languages also. Most of the template for direct simulation in C++ is very similar to the Matlab template. Unlike Matlab, some external mathematical library function for approximate integration must be added if there is a continuous-time element of the simulation for the target system. The results must be written to a file since C++ does not have any equivalent to the Matlab “workspace” to leave the result in.

5.1 Simulation in C++

Two software implementations are presented for C++. They differ in how they handle task implementations and to what extent the state transition model is embedded in the base software or ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required