feat: 完成控制代码编写
This commit is contained in:
23
app/main.c
23
app/main.c
@@ -25,8 +25,6 @@
|
||||
#include "page.h"
|
||||
#include "page_ui_widget.h"
|
||||
|
||||
#include "gl_headfile.h"
|
||||
|
||||
#include "jj_param.h"
|
||||
#include "jj_motion.h"
|
||||
#include "jj_blueteeth.h"
|
||||
@@ -43,26 +41,31 @@ int main(void)
|
||||
system_delay_init();
|
||||
debug_init();
|
||||
|
||||
encoder_dir_init(TIM5_ENCOEDER, TIM5_ENCOEDER_MAP0_CH1_A0, TIM5_ENCOEDER_MAP0_CH2_A1);
|
||||
ips200_init(IPS200_TYPE_SPI);
|
||||
|
||||
while (imu660ra_init())
|
||||
;
|
||||
jj_param_eeprom_init();
|
||||
jj_bt_init();
|
||||
by_rb_init();
|
||||
by_pwm_init();
|
||||
by_buzzer_init();
|
||||
by_tiny_frame_init();
|
||||
// by_buzzer_init();
|
||||
|
||||
by_tiny_frame_init();
|
||||
Page_Init();
|
||||
sport_pid_init();
|
||||
|
||||
pit_ms_init(TIM6_PIT, 10); // 陀螺仪
|
||||
pit_ms_init(TIM1_PIT, 1); // 运动解算,bianmaqi
|
||||
|
||||
printf("ok\r\n");
|
||||
|
||||
while (1) {
|
||||
by_buzzer_run();
|
||||
Page_Run();
|
||||
|
||||
//by_buzzer_run();
|
||||
jj_bt_run();
|
||||
/** 测试完成后移除 **/
|
||||
by_tiny_frame_run();
|
||||
// by_tiny_frame_pack_send(&frame_now);
|
||||
system_delay_ms(10);
|
||||
by_tiny_frame_parse_timer_handle();
|
||||
/** 测试完成后移除 **/
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user