public static void checkInputStatus() { ulong axisStatus; while (started) { Thread.Sleep(100); if (mServoIo.check_flag != 0) { return; } //X轴 axisStatus = RFIDControl.dmc_axis_io_status(0, 0);//读取轴的状态 mServoIo.servo1_alm = (int)getStatus(axisStatus, (int)AxisStatus.MOTOR_ALM); mServoIo.servo1_el_b = (int)getStatus(axisStatus, (int)AxisStatus.MOTOR_EL_B); mServoIo.servo1_el_f = (int)getStatus(axisStatus, (int)AxisStatus.MOTOR_EL_F); mServoIo.servo1_emg = (int)getStatus(axisStatus, (int)AxisStatus.MOTOR_EMG); mServoIo.servo1_org = (int)getStatus(axisStatus, (int)AxisStatus.MOTOR_ORG); mServoIo.servo1_ez = (int)getStatus(axisStatus, (int)AxisStatus.MOTOR_EZ); mServoIo.servo1_inp = (int)getStatus(axisStatus, (int)AxisStatus.MOTOR_INP); mServoIo.servo1_rdy = (int)getStatus(axisStatus, (int)AxisStatus.MOTOR_RDY); mServoIo.servo1_home_flag = mAxis[0].m_home_flag; //原点状态 //Y轴 axisStatus = RFIDControl.dmc_axis_io_status(0, 1); //读取轴的状态 mServoIo.servo2_alm = (int)getStatus(axisStatus, (int)AxisStatus.MOTOR_ALM); mServoIo.servo2_el_b = (int)getStatus(axisStatus, (int)AxisStatus.MOTOR_EL_B); mServoIo.servo2_el_f = (int)getStatus(axisStatus, (int)AxisStatus.MOTOR_EL_F); mServoIo.servo2_emg = (int)getStatus(axisStatus, (int)AxisStatus.MOTOR_EMG); mServoIo.servo2_org = (int)getStatus(axisStatus, (int)AxisStatus.MOTOR_ORG); mServoIo.servo2_ez = (int)getStatus(axisStatus, (int)AxisStatus.MOTOR_EZ); mServoIo.servo2_inp = (int)getStatus(axisStatus, (int)AxisStatus.MOTOR_INP); mServoIo.servo2_rdy = (int)getStatus(axisStatus, (int)AxisStatus.MOTOR_RDY); mServoIo.servo2_home_flag = mAxis[1].m_home_flag;//原点状态 //not exist z axis //Z轴 //各个轴的运动状态 mAxis[0].m_run_status = (ushort)RFIDControl.dmc_check_done(mAxis[0].m_card_num, mAxis[0].m_axis_num); mAxis[1].m_run_status = (ushort)RFIDControl.dmc_check_done(mAxis[1].m_card_num, mAxis[1].m_axis_num); mAxis[0].m_positon = RFIDControl.dmc_get_encoder(mAxis[0].m_card_num, mAxis[0].m_axis_num); mAxis[1].m_positon = RFIDControl.dmc_get_encoder(mAxis[1].m_card_num, mAxis[1].m_axis_num); mInpterplaType.run_flag = RFIDControl.dmc_check_done_multicoor(mInpterplaType.card_num, mInpterplaType.car_num); if ((RFIDControl.dmc_read_inbit(0, 0) == LOW) && (key_emg_press_flag == false)) { key_emg_press_flag = true; emgStop(); } else { key_emg_press_flag = false; } } }