pref: 上电复位到指定位置
This commit is contained in:
@@ -30,7 +30,7 @@
|
|||||||
"titleBar.activeBackground": "#1A4A07",
|
"titleBar.activeBackground": "#1A4A07",
|
||||||
"titleBar.activeForeground": "#F3FEEF"
|
"titleBar.activeForeground": "#F3FEEF"
|
||||||
},
|
},
|
||||||
"EIDE.OpenOCD.ExePath": "C:/toolchains/openocd-arterytek/bin/openocd.exe",
|
"EIDE.OpenOCD.ExePath": "D:/Program Files (x86)/at32_OpenOCD_V2.0.2/bin/openocd.exe",
|
||||||
"cortex-debug.variableUseNaturalFormat": true
|
"cortex-debug.variableUseNaturalFormat": true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -2,6 +2,7 @@
|
|||||||
|
|
||||||
#include "at32f415.h"
|
#include "at32f415.h"
|
||||||
#include "lwprintf.h"
|
#include "lwprintf.h"
|
||||||
|
#include "by_debug.h"
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief 设置云台摇臂
|
* @brief 设置云台摇臂
|
||||||
@@ -136,11 +137,12 @@ void by_servo_set_storage(int16_t angle)
|
|||||||
void by_servo_init(void)
|
void by_servo_init(void)
|
||||||
{
|
{
|
||||||
// 后续要不全初始化为空值,由主控按顺序初始化
|
// 后续要不全初始化为空值,由主控按顺序初始化
|
||||||
by_servo_set_claw_arm(220); // 36-220
|
|
||||||
by_servo_set_claw(25); // 25-90
|
by_servo_set_claw(25); // 25-90
|
||||||
by_servo_set_camera(45);
|
by_servo_set_camera(45);
|
||||||
by_servo_set_scoop(0);
|
by_servo_set_scoop(0);
|
||||||
by_servo_set_storage(0);
|
by_servo_set_storage(0);
|
||||||
|
delay_sec(4);
|
||||||
|
by_servo_set_claw_arm(220); // 36-220
|
||||||
}
|
}
|
||||||
|
|
||||||
void by_servo_can_handle(uint16_t stdd_id, const uint8_t *data, uint8_t len)
|
void by_servo_can_handle(uint16_t stdd_id, const uint8_t *data, uint8_t len)
|
||||||
|
|||||||
Reference in New Issue
Block a user