In order to improve the readability of the ArduPilot code and help new
users pick up the code quickly please use the following styles.

Note

Some parts of the code may not conform due to historic reasons but
new additions should!

astyle is our tool of choice for formatting the code. Whilst we
aren’t doing it automatically at the moment in the Tools/CodeStyle
directory there is an astylerc file that can be used to format the code
automatically according to the guidelines below.

astyle--options=Tools/CodeStyle/astylerc<filename>

Remember any formatting changes to a file should be done as a separate
commit.