39 lines
1.0 KiB
C
39 lines
1.0 KiB
C
|
||
#ifndef INKJETBASE_RUANYICTRL_H_
|
||
#define INKJETBASE_RUANYICTRL_H_
|
||
|
||
#include "config.h"
|
||
#if (BUSCTRL_MOTO == RUANYI)
|
||
|
||
#define BITMOVEADDR 9216 //动作命令地址
|
||
#define BITTOPOSADDR 9218 //位置命令1,到对应位置
|
||
|
||
#define BITSTOPCMD 0x0000
|
||
#define BITTOZEROCMD 0x0001
|
||
#define BITJOGPCMD 0x0002
|
||
#define BITJOGNCMD 0x0004
|
||
#define BITSETCPOSZEROCMD 0x0040
|
||
#define BITSETZEROCMD 0x0100
|
||
|
||
#define BITTOPOS0 0x0001 //到对应位置0
|
||
#define BITTOPOS1 0x0002 //到对应位置1
|
||
#define BITTOPOS2 0x0004 //到对应位置2
|
||
#define BITTOPOS3 0x0008 //到对应位置3
|
||
|
||
void InitRuanyiCom(void);
|
||
|
||
int MoveRyiToRelativePos(u8 devIdx, s16 pos, u16 spd);
|
||
int MoveRyiToAbsolutePos(u8 devIdx, s16 pos, u16 spd);
|
||
int MoveRyiJOGP(u8 devIdx, u16 spd);
|
||
int MoveRyiJOGN(u8 devIdx, u16 spd);
|
||
int RyiMotoStop(u8 devIdx);
|
||
int SetRyiCurPos(u8 devIdx, s16 pos);
|
||
int RyiMotoSetCurPosZero(u8 devIdx);
|
||
int GetCurPusPos(u8 devIdx, s16 * puspos);
|
||
int GetCurStatus(u8 devIdx, int * statuflg);
|
||
int RyiMotoToPos(u8 devIdx, u16 pos);
|
||
#endif
|
||
|
||
|
||
#endif /* INKJETBASE_RUANYICTRL_H_ */
|