⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 motor_drv_wrapper.h

📁 简单双马达玩具车驱动 包装~
💻 H
字号:
/**********************************************************************
**
**          Copyright (c) 2008 -- Michael.All right received.
**
**          PROJECT: Tangtang's Graduation Design
**
**          PURPOSE: Head file for motor_drv_wrapper.c.
**
**          DATE : 05/18/2008
**
**          AUTHOR: Michael
**
**          SCHOOL: CUIT
**
**          FILENAME: motor_drv_wrapper.h
**
**********************************************************************/

#ifndef MOTOR_DRIVER_WRAPPER_H
#define MOTOR_DRIVER_WRAPPER_H

#ifdef __cplusplus
extern "C"
{
#endif /* __cplusplus */


/* Include files. */

#include "typedef.h"
#include "main.h"

/* Macro constant definitions. */


/* Type definitions. */

#define MOVE_FOREVER -1

typedef enum
{
    E_MOTOR_LEFT,
    E_MOTOR_RIGHT,
} eMotor;

typedef enum
{
    E_MOTOR_RUN_TYPE_MOVE_FORWARD,
    E_MOTOR_RUN_TYPE_MOVE_BACKWARD,
} eMotorRunType;

typedef enum
{
    E_MOTOR_OPT_TYPE_DISTANCE,
    E_MOTOR_OPT_TYPE_TIME,
} eMotorOptType;


/* External function declarations. */

eOsReturn MotorRun(eMotor moter, eMotorOptType optType,
  eMotorRunType runType, int32 arg);
eOsReturn MotorStop(eMotor moter);

/* Macro API definitions. */


/* Global variable declarations. */



#ifdef __cplusplus
} /* extern "C" */
#endif /* __cplusplus */

#endif /* MOTOR_DRIVER_WRAPPER_H */

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -