GeBalanceBot/GeBalanceBot_Firmware v1.0 .../HARDWARE/MOTO/car.h

22 lines
434 B
C
Raw Normal View History

2024-01-18 01:55:04 +08:00
#ifndef __CAR_H__
#define __CAR_H__
#include "stm32f10x.h"
#include "bsp_sys.h"
#include "sys.h"
#define Middle_angle 0
int EXTI15_10_IRQHandler(void);
int Balance(float angle,float gyro);
int Velocity(int encoder_left,int encoder_right);
void Motor_SetPwm(int motor_left,int motor_right);
void Key(void);
int MotorPwmLimit(int IN,int max,int min);
u8 Turn_Off(float angle);
void Get_Angle(void);
int myabs(int a);
#endif