mirror of
https://github.com/paparazzi/paparazzi.git
synced 2026-05-10 06:59:54 +08:00
42 lines
1.5 KiB
XML
42 lines
1.5 KiB
XML
<!DOCTYPE module SYSTEM "module.dtd">
|
|
|
|
<module name="servo_switch">
|
|
<doc>
|
|
<description>Servo switch</description>
|
|
<define name="SERVO_SWITCH_ON_VALUE" value="pwm" description="servo value in usec"/>
|
|
<define name="SERVO_SWITCH_OFF_VALUE" value="pwm" description="servo value in usec"/>
|
|
<define name="SERVO_SWITCH_SERVO" value="nb" description="Id of the servo (default: SWITCH)"/>
|
|
</doc>
|
|
<settings>
|
|
<dl_settings NAME="Servo switch control">
|
|
<dl_settings NAME="SWITCH">
|
|
<dl_setting var="servo_switch_on" min="0" step="1" max="1" module="servo_switch/servo_switch" values="Off|On">
|
|
<strip_button name="ON" value="1" group="servo_switch"/>
|
|
<strip_button name="OFF" value="0" group="servo_switch"/>
|
|
</dl_setting>
|
|
</dl_settings>
|
|
</dl_settings>
|
|
</settings>
|
|
<header>
|
|
<file name="servo_switch.h"/>
|
|
</header>
|
|
<init fun="servo_switch_init()"/>
|
|
<periodic fun="servo_switch_periodic()" freq="10."/>
|
|
<makefile target="ap|sim|jsbsim|nps">
|
|
|
|
<!-- these parameters should be set for that module in the airframe file unless you want the defaults
|
|
Servo value in usec
|
|
<load name="servo_switch.xml">
|
|
<define name="SERVO_SWITCH_ON_VALUE" value="2000"/>
|
|
<define name="SERVO_SWITCH_OFF_VALUE" value="1000"/>
|
|
<define name="SERVO_SWITCH_SERVO" value="SWITCH"/>
|
|
</load>
|
|
|
|
The servo will not exceed the min and max positions defined in the servo section
|
|
-->
|
|
|
|
<file name="servo_switch.c"/>
|
|
</makefile>
|
|
</module>
|
|
|