You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
171 lines
4.1 KiB
C++
171 lines
4.1 KiB
C++
#pragma once
|
|
#include <string>
|
|
|
|
static const int COM_BUF_LEN = 128; //串口通信buf 的长度
|
|
|
|
static int SCRIPT_X_RUN_TO_MAPPING_POS_INDEX = 71;
|
|
static int SCRIPT_MAPPING_INDEX = 61;
|
|
static int SCRIPT_BANK_INDEX = 3;
|
|
static int SCRIPT_CASS_START_INDEX = 11;
|
|
static int SCRIPT_SLOT_START_INDEX = 21;
|
|
static int SCRIPT_X_MOVE_INDEX = 71;
|
|
|
|
enum DevicePosDefine {
|
|
POS_CASS_LEFT = 1, //开始解键合前料盒
|
|
POS_CASS_CENTER, //解键合成功放回料盒
|
|
POS_CASS_RIGHT, //解键合失败放回料盒
|
|
POS_ALIGN_TOP, //带铁环
|
|
POS_ALIGN_BOTTOM, //盖泽准直器
|
|
POS_PLATFORM,
|
|
POS_SAPARATE,
|
|
POS_CLEANING,
|
|
|
|
POS_UPEER_ARM, //带铁环,
|
|
POS_LOWER_ARM, //不带铁环
|
|
|
|
//下面是虚拟位置
|
|
POS_ERROR,
|
|
POS_NONE,
|
|
};
|
|
|
|
enum eBankIndex {
|
|
BANK_RING = 0, //上手臂
|
|
BANK_WAFER, //下手臂
|
|
};
|
|
|
|
enum JudgeCassMappingType {
|
|
CASS_MAPPING_TYPE_RING = 0, //另外代表上手臂
|
|
CASS_MAPPING_TYPE_WAFER, //另外代表下手臂
|
|
CASS_MAPPING_TYPE_NONE,
|
|
CASS_MAPPING_TYPE_ERROR
|
|
};
|
|
|
|
enum eTransferType
|
|
{
|
|
_Transfer_Null = 0,
|
|
_Transfer_Init,
|
|
_Transfer_Scan, //料盒扫描
|
|
_Transfer_Grab_Wafer, //取料
|
|
_Transfer_Arm1ToAlign_Wafer, //准直
|
|
_Transfer_Aligner_Wafer, //准直
|
|
_Transfer_AlignToArm2_Wafer,
|
|
_Transfer_ToPlat_Wafer, //到平台
|
|
_Transfer_PlatToArm2_Wafer,
|
|
_Transfer_Arm2ToAligner_Wafer,
|
|
_Transfer_Aligner2_Wafer,//平台到准直
|
|
_Transfer_AlignToArm1_Wafer,
|
|
_Transfer_Upper_Wafer, //上料
|
|
_Transfer_ReadRfd, //读取Rfd
|
|
};
|
|
|
|
//cmd 的发送类型
|
|
enum eRobotCmdSendType
|
|
{
|
|
_RobotCmdSendType_SendOnly = 0,//只发送
|
|
_RobotCmdSendType_WaitFeedback,//发送后只等待反馈<
|
|
_RobotCmdSendType_WaitCmdEnd,//等待cmd执行完成(反馈< 加上cmd 相同str)
|
|
_RobotCmdSendType_ImmediateReadFeedback,//立即读取反馈(同步)
|
|
};
|
|
|
|
//发送给robot 的指令类型(顺序无所谓)
|
|
enum eRobotCmdType
|
|
{
|
|
_RobotCmd_TransferWafer = 0,//传送wafer
|
|
_RobotCmd_ToWaitPos,//移动到等待位置
|
|
_RobotCmd_Org,//重置错误,并且回原点
|
|
_RobotCmd_ResetErr,//重置错误
|
|
_RobotCmd_QueryState,//查询状态
|
|
_RobotCmd_QueryCoord1,//查询轴坐标位置1
|
|
_RobotCmd_QueryCoord2,//查询轴坐标位置2
|
|
_RobotCmd_QueryCoord3,//查询轴坐标位置3
|
|
_RobotCmd_Sevon,//激磁
|
|
_RobotCmd_Arm1VacOff,//arm1放真空
|
|
_RobotCmd_Arm2VacOff,//arm2放真空
|
|
_RobotCmd_Arm1Arm2MergePos,//Arm1和Arm2合并位置
|
|
_RobotCmd_AlignerExt,//准直执行
|
|
_RobotCmd_AlignerOrg,//准直org
|
|
_RobotCmd_AlignerTakeStation,//取料位置
|
|
_RobotCmd_AlignerVacOn,
|
|
_RobotCmd_AlignerVacOff,
|
|
_RobotCmd_AlignerSetPar,//设置角度
|
|
_RobotCmd_Arm1VacOn,//arm1开真空
|
|
_RobotCmd_Arm2VacOn,//arm2开真空
|
|
_RobotCmd_InitSet,//初始化设置
|
|
_RobotCmd_Port1Org,//org
|
|
_RobotCmd_Port2Org,//org
|
|
_RobotCmd_AdsVacOn,//吸附开
|
|
_RobotCmd_AdsVacOff,//吸附关
|
|
_RobotCmd_Arm_Check,//检测手臂是否有片
|
|
|
|
|
|
|
|
_RobotCmd_Init_Align,
|
|
_RobotCmd_Do_align,
|
|
_RObotCmd_Switch_bank,
|
|
_RobotCmd_Check_ARM_EXIST_WAFER,
|
|
|
|
_RObotCmd_RotateToWaferIdPos,
|
|
|
|
_RobotCmd_RunToCassMappingPoint,
|
|
_RobotCmd_Mapping,
|
|
_RobotCmd_ReadMappingData,
|
|
|
|
_RobotCmd_SelectCass,
|
|
_RobotCmd_SelectSlot,
|
|
_RobotCmd_X_Move,
|
|
_RobotCmd_TakeWafer,
|
|
};
|
|
|
|
enum eWaferPosType
|
|
{
|
|
_WaferPos_Null = 0,
|
|
_WaferPos_Arm1,
|
|
_WaferPos_Arm2,
|
|
_WaferPos_Cassette,
|
|
_WaferPos_Aligner,
|
|
_WaferPos_HotPlate,
|
|
_WaferPos_WaitPos,
|
|
_WaferPos_Special,
|
|
_WaferPos_AnnealExt,
|
|
_WaferPos_Max,
|
|
};
|
|
|
|
enum eDealWaferType
|
|
{
|
|
DEAL_WAFER_TAKE,
|
|
DEAL_WAFER_RETURN,
|
|
};
|
|
|
|
|
|
|
|
class _declspec(dllexport) CRobotCmdInfo
|
|
{
|
|
public:
|
|
CRobotCmdInfo()
|
|
{
|
|
m_WaitCmdTime = 1;//等待cmd 时间s
|
|
m_RobotCmdSendType = _RobotCmdSendType_SendOnly;
|
|
};
|
|
public:
|
|
eRobotCmdType m_RobotCmdType;//robot 的指令类型
|
|
|
|
//_RobotCmd_TransferWafer 类型使用的参数
|
|
eWaferPosType m_FromPos;//移动的起始位置
|
|
eWaferPosType m_ToPos;//移动的终点位置
|
|
|
|
int m_cassIndex;
|
|
int m_Slot;//移动wafer 的slot (操作cassette 才需要)
|
|
|
|
std::string m_armPos;//"up"上手指 "down"下手指
|
|
std::string m_SendCmdStr;//指令字符串
|
|
std::string m_ErrStr;//错误信息
|
|
std::string m_RevStr;//读取的反馈字符串
|
|
int m_WaitCmdTime;//等待cmd 时间s
|
|
|
|
int LoadportId = 0;
|
|
|
|
eRobotCmdSendType m_RobotCmdSendType;//cmd 的发送类型
|
|
|
|
int m_bankIndex = -1;
|
|
eDealWaferType m_dealWaferType; //从料盒取走 还是放回去
|
|
}; |