mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-05-02 05:04:08 +08:00
- generate PWM_MAIN 1-14
- generate PWM_AUX 1-8
- generate PWM_EXTRA 1-8
- px4io and pwm_out directly read configuration parameters
- only available and active physical outputs are actually shown for configuration
- overall saves flash despite adding many new parameters
48 lines
834 B
Bash
48 lines
834 B
Bash
#!/bin/sh
|
|
#
|
|
# CUAV X7Pro specific board defaults
|
|
#------------------------------------------------------------------------------
|
|
|
|
#
|
|
# Bootloader upgrade
|
|
#
|
|
set BL_FILE /etc/extras/cuav_x7pro_bootloader.bin
|
|
if [ -f $BL_FILE ]
|
|
then
|
|
if param compare SYS_BL_UPDATE 1
|
|
then
|
|
param set SYS_BL_UPDATE 0
|
|
param save
|
|
echo "BL update..."
|
|
bl_update $BL_FILE
|
|
echo "BL update done"
|
|
reboot
|
|
fi
|
|
fi
|
|
unset BL_FILE
|
|
|
|
if [ $AUTOCNF = yes ]
|
|
then
|
|
param set BAT_V_DIV 18
|
|
param set BAT1_V_DIV 18
|
|
param set BAT2_V_DIV 18
|
|
|
|
param set BAT_A_PER_V 24
|
|
param set BAT1_A_PER_V 24
|
|
param set BAT2_A_PER_V 24
|
|
|
|
# Multi-EKF
|
|
param set EKF2_MULTI_IMU 3
|
|
param set SENS_IMU_MODE 0
|
|
param set EKF2_MULTI_MAG 3
|
|
param set SENS_MAG_MODE 0
|
|
|
|
# Enable IMU thermal control
|
|
param set SENS_EN_THERMAL 1
|
|
fi
|
|
|
|
set LOGGER_BUF 64
|
|
|
|
rgbled_pwm start
|
|
safety_button start
|