mirror of
https://github.com/paparazzi/paparazzi.git
synced 2026-06-05 15:30:08 +08:00
Merge remote branch 'paparazzi/master'
This commit is contained in:
@@ -16,7 +16,9 @@
|
||||
<define name="GUIDANCE_H_USE_REF"/>
|
||||
|
||||
<subsystem name="radio_control" type="ppm"/>
|
||||
<subsystem name="actuators" type="mkk"/>
|
||||
<subsystem name="actuators" type="mkk">
|
||||
<configure name="MKK_I2C_SCL_TIME" value="150"/><!-- this is optional, 150 is default, e.g. use 50 for 8 motors-->
|
||||
</subsystem>
|
||||
<subsystem name="imu" type="b2_v1.0"/>
|
||||
<subsystem name="gps" type="ublox"/>
|
||||
<subsystem name="ahrs" type="cmpl"/>
|
||||
@@ -38,13 +40,6 @@
|
||||
<!--load name="sonar_maxbotix_booz.xml"/-->
|
||||
</modules>
|
||||
|
||||
<servos min="0" neutral="0" max="0xff">
|
||||
<servo name="FRONT" no="0" min="0" neutral="0" max="255" />
|
||||
<servo name="BACK" no="1" min="0" neutral="0" max="255" />
|
||||
<servo name="RIGHT" no="2" min="0" neutral="0" max="255" />
|
||||
<servo name="LEFT" no="3" min="0" neutral="0" max="255" />
|
||||
</servos>
|
||||
|
||||
<commands>
|
||||
<axis name="PITCH" failsafe_value="0" />
|
||||
<axis name="ROLL" failsafe_value="0" />
|
||||
@@ -84,10 +79,6 @@
|
||||
<define name="GYRO_Q_SENS" value="1.1360802599" integer="16" />
|
||||
<define name="GYRO_R_SENS" value="1.1249874614" integer="16" />
|
||||
|
||||
<define name="ACCEL_X_CHAN" value="3" />
|
||||
<define name="ACCEL_Y_CHAN" value="5" />
|
||||
<define name="ACCEL_Z_CHAN" value="6" />
|
||||
|
||||
<define name="ACCEL_X_SENS" value="2.45932966" integer="16"/>
|
||||
<define name="ACCEL_Y_SENS" value="2.45106376" integer="16"/>
|
||||
<define name="ACCEL_Z_SENS" value="2.47825717" integer="16"/>
|
||||
|
||||
@@ -1,8 +1,15 @@
|
||||
#
|
||||
# Booz Mikrokopter Actuators
|
||||
# Mikrokopter Actuators
|
||||
#
|
||||
# enable the subsystem for your firmware:
|
||||
# <firmware name="rotorcraft">
|
||||
# ...
|
||||
# <subsystem name="actuators" type="mkk">
|
||||
# <configure name="MKK_I2C_SCL_TIME" value="50"/> <!-- this is optional, 150 is default, use 50 for 8 motors-->
|
||||
# </firmware>
|
||||
#
|
||||
#
|
||||
# required xml:
|
||||
# required xml configuration:
|
||||
# <section name="ACTUATORS_MKK" prefix="ACTUATORS_MKK_">
|
||||
# <define name="NB" value="4"/>
|
||||
# <define name="ADDR" value="{ 0x52, 0x54, 0x56, 0x58 }"/>
|
||||
@@ -24,8 +31,11 @@
|
||||
#
|
||||
#
|
||||
|
||||
# set default i2c timing if not already configured
|
||||
ifeq ($(MKK_I2C_SCL_TIME), )
|
||||
MKK_I2C_SCL_TIME=150
|
||||
endif
|
||||
|
||||
#
|
||||
ap.srcs += $(SRC_FIRMWARE)/actuators/supervision.c
|
||||
ap.srcs += $(SRC_FIRMWARE)/actuators/actuators_mkk.c
|
||||
ap.srcs += mcu_periph/i2c.c
|
||||
@@ -33,7 +43,7 @@ ap.srcs += $(SRC_ARCH)/mcu_periph/i2c_arch.c
|
||||
|
||||
ifeq ($(ARCH), lpc21)
|
||||
ap.CFLAGS += -DACTUATORS_MKK_DEVICE=i2c0
|
||||
ap.CFLAGS += -DUSE_I2C0 -DI2C0_SCLL=150 -DI2C0_SCLH=150 -DI2C0_VIC_SLOT=10
|
||||
ap.CFLAGS += -DUSE_I2C0 -DI2C0_SCLL=$(MKK_I2C_SCL_TIME) -DI2C0_SCLH=$(MKK_I2C_SCL_TIME) -DI2C0_VIC_SLOT=10
|
||||
else ifeq ($(ARCH), stm32)
|
||||
ap.CFLAGS += -DACTUATORS_MKK_DEVICE=i2c1
|
||||
ap.CFLAGS += -DUSE_I2C1
|
||||
@@ -42,6 +52,6 @@ endif
|
||||
# Simulator
|
||||
sim.srcs += $(SRC_FIRMWARE)/actuators/supervision.c
|
||||
sim.srcs += $(SRC_FIRMWARE)/actuators/actuators_mkk.c
|
||||
sim.CFLAGS += -DUSE_I2C0 -DI2C0_SCLL=150 -DI2C0_SCLH=150 -DI2C0_VIC_SLOT=10 -DACTUATORS_MKK_DEVICE=i2c1
|
||||
sim.CFLAGS += -DUSE_I2C0 -DI2C0_SCLL=$(MKK_I2C_SCL_TIME) -DI2C0_SCLH=$(MKK_I2C_SCL_TIME) -DI2C0_VIC_SLOT=10 -DACTUATORS_MKK_DEVICE=i2c1
|
||||
sim.srcs += mcu_periph/i2c.c
|
||||
sim.srcs += $(SRC_ARCH)/mcu_periph/i2c_arch.c
|
||||
|
||||
+1
-1
@@ -36,7 +36,7 @@
|
||||
#if defined USE_UART0 || defined USE_UART1 || defined USE_UART2 || defined USE_UART3 || defined USE_UART4 || defined USE_UART5
|
||||
#include "mcu_periph/uart.h"
|
||||
#endif
|
||||
#if defined USE_I2C0 || defined USE_I2C1 || defined USE_I2C2
|
||||
#if defined USE_I2C0 || defined USE_I2C1 || defined USE_I2C2
|
||||
#include "mcu_periph/i2c.h"
|
||||
#endif
|
||||
#if defined USE_ADC
|
||||
|
||||
Reference in New Issue
Block a user