mirror of
https://github.com/paparazzi/paparazzi.git
synced 2026-06-05 23:49:00 +08:00
remove adc_generic subsystem, is a module now
This commit is contained in:
@@ -13,7 +13,6 @@
|
|||||||
<firmware name="fixedwing">
|
<firmware name="fixedwing">
|
||||||
<target name="ap" board="twog_1.0">
|
<target name="ap" board="twog_1.0">
|
||||||
<define name="UBX_EXTERNAL"/>
|
<define name="UBX_EXTERNAL"/>
|
||||||
<define name="USE_ADC_GENERIC"/>
|
|
||||||
</target>
|
</target>
|
||||||
|
|
||||||
<target name="sim" board="pc"/>
|
<target name="sim" board="pc"/>
|
||||||
@@ -22,11 +21,6 @@
|
|||||||
<define name="ALT_KALMAN"/>
|
<define name="ALT_KALMAN"/>
|
||||||
<define name="AGR_CLIMB"/>
|
<define name="AGR_CLIMB"/>
|
||||||
|
|
||||||
<subsystem name="adc" type="generic">
|
|
||||||
<param name="ADC_GENERIC1" value="ADC_3"/>
|
|
||||||
<param name="ADC_GENERIC2" value="ADC_5"/>
|
|
||||||
</subsystem>
|
|
||||||
|
|
||||||
<subsystem name="radio_control" type="ppm"/>
|
<subsystem name="radio_control" type="ppm"/>
|
||||||
<subsystem name="telemetry" type="transparent"/>
|
<subsystem name="telemetry" type="transparent"/>
|
||||||
<subsystem name="control"/>
|
<subsystem name="control"/>
|
||||||
@@ -44,6 +38,12 @@
|
|||||||
|
|
||||||
<modules>
|
<modules>
|
||||||
<load name="twog_extra_dl.xml"/>
|
<load name="twog_extra_dl.xml"/>
|
||||||
|
<load name="adc_generic.xml">
|
||||||
|
<flag name="ADC_CHANNEL_GENERIC1" value="ADC_3"/>
|
||||||
|
<flag name="ADC_CHANNEL_GENERIC2" value="ADC_5"/>
|
||||||
|
<flag name="USE_ADC_3"/>
|
||||||
|
<flag name="USE_ADC_5"/>
|
||||||
|
</load>
|
||||||
</modules>
|
</modules>
|
||||||
|
|
||||||
<servos>
|
<servos>
|
||||||
|
|||||||
@@ -1,30 +0,0 @@
|
|||||||
# generic ADC
|
|
||||||
|
|
||||||
#
|
|
||||||
# default values for tiny and twog are:
|
|
||||||
# ADC_GENERIC_NB_SAMPLES = 16
|
|
||||||
#
|
|
||||||
# to change just redefine before including this file
|
|
||||||
#
|
|
||||||
# you have to set the params of the ADCs to use, eg.
|
|
||||||
# <subsystem name"adc" type="generic">
|
|
||||||
# <param name="ADC_GENERIC1" value="ADC_3"/>
|
|
||||||
# <param name="ADC_GENERIC2" value="ADC_4"/>
|
|
||||||
# </subsystem>
|
|
||||||
#
|
|
||||||
# if you only set one parameter only that one will be used
|
|
||||||
|
|
||||||
ifdef ADC_GENERIC1
|
|
||||||
ap.CFLAGS += -DUSE_ADC_GENERIC -DADC_CHANNEL_GENERIC_NB_SAMPLES=$(ADC_GENERIC_NB_SAMPLES)
|
|
||||||
ap.CFLAGS += -DADC_CHANNEL_GENERIC1=$(ADC_GENERIC1) -DUSE_$(ADC_GENERIC1)
|
|
||||||
ifdef ADC_GENERIC2
|
|
||||||
ap.CFLAGS += -DADC_CHANNEL_GENERIC2=$(ADC_GENERIC2) -DUSE_$(ADC_GENERIC2)
|
|
||||||
endif
|
|
||||||
ap.srcs += $(SRC_FIXEDWING)/adc_generic.c
|
|
||||||
else
|
|
||||||
ifdef ADC_GENERIC2
|
|
||||||
ap.CFLAGS += -DUSE_ADC_GENERIC -DADC_CHANNEL_GENERIC_NB_SAMPLES=$(ADC_GENERIC_NB_SAMPLES)
|
|
||||||
ap.CFLAGS += -DADC_CHANNEL_GENERIC2=$(ADC_GENERIC1) -DUSE_$(ADC_GENERIC2)
|
|
||||||
ap.srcs += $(SRC_FIXEDWING)/adc_generic.c
|
|
||||||
endif
|
|
||||||
endif
|
|
||||||
Reference in New Issue
Block a user