O'Reilly logo

Small Unmanned Aircraft by Timothy W. McLain, Randal W. Beard

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

APPENDIX C

Animations in Simulink

In the study of aircraft dynamics and control, it is essential to be able to visualize the motion of the airframe. In this section we describe how to create animations in Matlab/Simulink.

C.1 Handle Graphics in Matlab

When a graphics function like plot is called in Matlab, the function returns a handle to the plot. A graphics handle is similar to a pointer in C/C++ in the sense that all of the properties of the plot can be accessed through the handle. For example, the Matlab command

1    >> plot_handle=plot (t,sin(t))

returns a pointer, or handle, to the plot of sin(t). Properties of the plot can be changed by using the handle, rather than reissuing the plot command. For example, the Matlab command

1    >>set ...

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