Paparazzi UAS  v7.0_unstable
Paparazzi is a free software Unmanned Aircraft System.
actuators_hitl module

Sends commands or actuators for Hardware In The Loop simulation

No detailed description...

Example for airframe file

Add to your firmware section: This example contains all possible configuration options, not all of them are mandatory!

<module name="actuators_hitl">
b'<configure name="HITL_PORT" value="UARTX|UDPX|usb_serial" />\n '
b'<configure name="HITL_BAUD" value="B230400" />\n '
</module>

Module configuration options

Configure Options

  • name: HITL_PORT value: UARTX|UDPX|usb_serial
    Description: Select port for extra datalink
  • name: HITL_BAUD value: B230400
    Description: Baudrate for extra datalink if link device is UART

Module functions

Init Functions

These initialization functions are called once on startup.

Periodic Functions

These functions are called periodically at the specified frequency from the module periodic loop.

  • actuators_hitl_periodic()
    • Running at maximum module frequency.
    • Autorun: LOCK
      Periodic function automatically starts after init and can't be stopped.

Files

Header Files

The following headers are automatically included in modules.h

Source Files

Raw actuators_hitl.xml file:

<!DOCTYPE module SYSTEM "module.dtd">
<module name="actuators_hitl" dir="actuators" task="actuators">
<doc>
<description>
Sends commands or actuators for Hardware In The Loop simulation
</description>
<configure name="HITL_PORT" value="UARTX|UDPX|usb_serial" description="Select port for extra datalink"/>
<configure name="HITL_BAUD" value="B230400" description="Baudrate for extra datalink if link device is UART"/>
</doc>
<dep>
<provides>actuators</provides>
</dep>
<header>
<file name="actuators_hitl.h"/>
</header>
<init fun="actuators_hitl_init()"/>
<periodic fun="actuators_hitl_periodic()"/>
<makefile target="ap">
<configure name="HITL_PORT" case="upper|lower"/>
<configure name="HITL_BAUD" default="B230400"/>
<define name="HITL_DEVICE" value="$(HITL_PORT_LOWER)"/>
<define name="USE_$(HITL_PORT_UPPER)"/>
<define name="$(HITL_PORT_UPPER)_BAUD" value="$(HITL_BAUD)"/>
<file name="actuators_hitl.c"/>
<test>
<define name="HITL_DEVICE" value="usb_serial"/>
<define name="USE_USB_SERIAL"/>
</test>
</makefile>
</module>