Paparazzi UAS v7.1_unstable
Paparazzi is a free software Unmanned Aircraft System.
Loading...
Searching...
No Matches
pump_control module

Pump control for IMAV2026

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="pump_control">
b'<configure name="PUMP_CONTROL_ADC" default="ADC_4" />\n '
</module>

Module configuration options

Configure Options

  • name: PUMP_CONTROL_ADC value: None

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.

Files

Header Files

The following headers are automatically included in modules.h

Source Files

Raw pump_control.xml file:

<!DOCTYPE module SYSTEM "module.dtd">
<module name="pump_control" dir="pump_control">
<doc>
<description>Pump control for IMAV2026</description>
<configure name="PUMP_CONTROL_ADC" default="ADC_4"/>
</doc>
<settings>
<dl_settings>
<dl_settings name="Water">
<dl_setting var="pump_ctrl_state" min="0" max="3" values="OFF|PUMP|VALVE" handler="handler" module="pump_control/pump_control">
<strip_button name="Pump ON" value="1" group="water"/>
<strip_button name="Valve ON" value="2" group="water"/>
<strip_button name="Pump OFF" value="0" group="water"/>
</dl_setting>
</dl_settings>
</dl_settings>
</settings>
<dep>
<depends>adc</depends>
</dep>
<header>
<file name="pump_control.h"/>
</header>
<init fun="pump_control_init()"/>
<periodic fun="pump_control_report()" freq="2" autorun="FALSE"/>
<makefile>
<file name="pump_control.c"/>
<configure name="PUMP_CONTROL_ADC" default="ADC_4"/>
<define name="PUMP_CONTROL_ADC" value="$(PUMP_CONTROL_ADC)"/>
<define name="USE_$(PUMP_CONTROL_ADC)" />
<test firmware="rotorcraft">
<define name="PUMP_CONTROL_ADC" value="ADC_4"/>
<define name="USE_ADC_4"/>
<define name="DOWNLINK_TRANSPORT" value="pprz_tp"/>
<define name="DOWNLINK_DEVICE" value="uart0"/>
<define name="USE_UART0"/>
</test>
</makefile>
</module>