Paparazzi UAS  v5.15_devel-230-gc96ce27
Paparazzi is a free software Unmanned Aircraft System.
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
joystick module

Handle JOYSTICK_RAW messages

Each new message is parsed and stored into the joystick structure. An ABI message JOYSTICK is sent and can be used for control or payload depending on the application.

Example for airframe file

Add to your firmware section:

1 <module name="joystick"/>

Module functions

Init Functions

These initialization functions are called once on startup.

Datalink Functions

Whenever the specified datalink message is received, the corresponing handler function is called.

  • on message JOYSTICK_RAW call joystick_parse(buf)

Files

Header Files

The following headers are automatically included in modules.h

Source Files

Raw joystick.xml file:

<!DOCTYPE module SYSTEM "module.dtd">
<module name="joystick">
<doc>
<description>
Handle JOYSTICK_RAW messages
Each new message is parsed and stored into the joystick structure.
An ABI message JOYSTICK is sent and can be used for control or payload
depending on the application.
</description>
</doc>
<header>
<file name="joystick.h"/>
</header>
<init fun="joystick_init()"/>
<datalink message="JOYSTICK_RAW" fun="joystick_parse(buf)"/>
<makefile>
<file name="joystick.c"/>
</makefile>
</module>