Files
BC1C-firmware/app/by_motion.h

32 lines
764 B
C
Raw Normal View History

#ifndef _BY_MOTION_H__
#define _BY_MOTION_H__
#include "at32f403a_407.h"
typedef struct motion_speed_type {
float v_x;
float v_y;
float v_w;
} motion_speed_type;
typedef struct motion_time_type {
uint32_t t_x;
uint32_t t_y;
uint32_t t_w;
} motion_time_type;
extern void by_motion_init(void);
extern void by_motion_update_speed(void);
extern void by_motion_loop(void);
extern void by_motion_set_mode(uint8_t mode);
extern void by_motion_timer_handle(void);
// extern void by_motion_set_mode(uint8_t mode);
extern void by_motion_set_mode_x(uint8_t mode);
extern void by_motion_set_mode_y(uint8_t mode);
extern void by_motion_set_mode_w(uint8_t mode);
extern motion_speed_type motion_speed_struct;
extern motion_time_type motion_time_struct;
#endif