mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-07-18 21:30:36 +08:00
Updated F330 script, enabled amber led
This commit is contained in:
@@ -15,20 +15,19 @@ then
|
||||
# Set all params here, then disable autoconfig
|
||||
param set SYS_AUTOCONFIG 0
|
||||
|
||||
param set MC_ATTRATE_D 0.007
|
||||
param set MC_ATTRATE_D 0.005
|
||||
param set MC_ATTRATE_I 0.0
|
||||
param set MC_ATTRATE_P 0.13
|
||||
param set MC_ATTRATE_P 0.1
|
||||
param set MC_ATT_D 0.0
|
||||
param set MC_ATT_I 0.0
|
||||
param set MC_ATT_P 7.0
|
||||
param set MC_POS_P 0.1
|
||||
param set MC_ATT_P 4.5
|
||||
param set MC_RCLOSS_THR 0.0
|
||||
param set MC_YAWPOS_D 0.0
|
||||
param set MC_YAWPOS_I 0.5
|
||||
param set MC_YAWPOS_P 1.0
|
||||
param set MC_YAWPOS_I 0.3
|
||||
param set MC_YAWPOS_P 0.6
|
||||
param set MC_YAWRATE_D 0.0
|
||||
param set MC_YAWRATE_I 0.0
|
||||
param set MC_YAWRATE_P 0.2
|
||||
param set MC_YAWRATE_P 0.1
|
||||
|
||||
param save /fs/microsd/params
|
||||
fi
|
||||
@@ -128,7 +127,7 @@ multirotor_att_control start
|
||||
#
|
||||
# Start logging
|
||||
#
|
||||
sdlog2 start -r 20 -a -b 14
|
||||
sdlog2 start -r 20 -a -b 16
|
||||
|
||||
#
|
||||
# Start system state
|
||||
|
||||
@@ -193,8 +193,8 @@ __EXPORT int nsh_archinitialize(void)
|
||||
NULL);
|
||||
|
||||
/* initial LED state */
|
||||
//drv_led_start();
|
||||
up_ledoff(LED_AMBER);
|
||||
drv_led_start();
|
||||
led_off(LED_AMBER);
|
||||
|
||||
/* Configure SPI-based devices */
|
||||
|
||||
|
||||
@@ -68,7 +68,7 @@ __EXPORT void led_init()
|
||||
|
||||
__EXPORT void led_on(int led)
|
||||
{
|
||||
if (led == 0)
|
||||
if (led == 1)
|
||||
{
|
||||
/* Pull down to switch on */
|
||||
stm32_gpiowrite(GPIO_LED1, false);
|
||||
@@ -77,7 +77,7 @@ __EXPORT void led_on(int led)
|
||||
|
||||
__EXPORT void led_off(int led)
|
||||
{
|
||||
if (led == 0)
|
||||
if (led == 1)
|
||||
{
|
||||
/* Pull up to switch off */
|
||||
stm32_gpiowrite(GPIO_LED1, true);
|
||||
|
||||
Reference in New Issue
Block a user