RobotHardware-UESTC/Hardware/银星机器人底盘/PiRobot-YH_Firmware v1.1/STM32/Lib/Joystick/joystick.h

22 lines
427 B
C++

#ifndef PIBOT_JOYSTICK_H_
#define PIBOT_JOYSTICK_H_
#include "pstwo.h" //for v1.6
class Joystick
{
public:
Joystick();
bool init();
void test();
bool check(short& liner_x, short liner_y, short& angular_z);
private:
bool holonomic_check(short& liner_x, short liner_y, short& angular_z);
bool nonholonomic_check(short& liner_x, short liner_y, short& angular_z);
private:
int error;
};
#endif