The invention discloses a two-dimensional code positioning and grabbing robot system algorithm based on visual recognition, which includes the following steps: s1. identifying the grabbed object with two-dimensional code; s2. extracting the position and attitude information of the geometric center of the two-dimensional code; s3. setting the target value of the relative position and attitude of the two-dimensional code at rest; calculating the deviation between the two-dimensional code position and the set position and attitude target at the current time, and If the deviation exceeds the threshold value, the deviation information is converted into velocity information by using the PID algorithm, and the speed information is used to control the wheelbarrel platform to move to the position and posture target, and then to keep the wheelbarrel platform still if the deviation does not exceed the threshold value. s4. Using the two-dimensional code position and posture information, the inverse kinematics of the manipulator is solved, so that the end of the manipulator can be achieved. The center clamping position of the end manipulator reaches the two-dimensional code center; the angle of the driving motor of the manipulator is solved by coordinate transformation; the angle of the driving motor is output to drive the end actuator of the manipulator to move to the grasped object to complete the clamping action.
【技术实现步骤摘要】
基于视觉识别的二维码定位抓取机器人系统算法
本专利技术涉及多自由度机器人控制算法领域,特别涉及一种基于视觉识别二维码的全向移动平台的移动定位与四自由度机械臂抓取算法。
技术介绍
基于视觉的移动机器人自主导航是指移动机器人平台的图像采集系统获取机器人当前状态下的环境信息,通过对环境图像分析确定环境对象和机器人在环境中的位置。由于图像有较高分辨率,环境信息完整,符合人类的认知习惯,因此,近些年来,基于视觉的移动机器人自主导航被得到广泛关注和认可,并且在理论和实践方面已取得相当多的成果。现有技术中,已经存在有基于二维码实现移动小车定位的算法,用于控制移动小车向目标二维码移动。另外,在现有技术中,研究者将机器视觉和机械臂结合起来,为机械臂增加了智能的“眼睛”,可以大大增加机械臂的环境感知能力和智能决策能力,使机械臂可以轻松实现物品的抓取和放置等动作。但是目前未发现有将机械臂与移动平台相结合的视觉识别抓取算法;因此,需要一种基于视觉识别的二维码定位抓取机器人系统算法,该算法结合PID算法的移动平台定位算法和机械臂逆运动学求解,提升了机械臂逆解的求解效率,较传统基座固定的机械臂,结合使用机械臂与移动平台,增加机械臂的操作范围和动作灵活性,采用二维码定位,提升抓取成功率。
技术实现思路
有鉴于此,本专利技术针对现有技术的缺陷,提供了一种基于视觉识别的二维码定位抓取机器人系统算法,该算法实现基于视觉识别二维码的移动定位抓取动作,得以快速完成远处目标的抓取,增大传统基座固定机械臂的抓取范围,提升机器人的灵活性。本专利技术的基于视觉识别的二维码定位抓取机器人系统算法,包括以下步骤 ...
【技术保护点】
1.一种基于视觉识别的二维码定位抓取机器人系统算法,其特征在于,包括以下步骤:s1.识别设有二维码的被抓取物体;s2.提取所述二维码几何中心的位姿信息;s3.设定到所述二维码相对位姿静止的目标值;计算当前时刻二维码位姿与设定的位姿目标之间的偏差,并将该偏差与设定的阈值做比较;若偏差超过阈值,则结合PID算法,将偏差信息转化为速度信息,并根据该速度信息控制麦轮平台运动到位姿目标后静止;若偏差未超过阈值,则保持麦轮平台静止;s4.利用所述二维码位姿信息进行机械臂的逆运动学求解,使机械臂末端机械手的中心夹持位置达到二维码中心;经过坐标变换,求解出机械臂驱动电机的转角;驱动电机输出该转角带动机械臂末端执行器运动到被抓取物体后完成夹持动作。
【技术特征摘要】
1.一种基于视觉识别的二维码定位抓取机器人系统算法,其特征在于,包括以下步骤:s1.识别设有二维码的被抓取物体;s2.提取所述二维码几何中心的位姿信息;s3.设定到所述二维码相对位姿静止的目标值;计算当前时刻二维码位姿与设定的位姿目标之间的偏差,并将该偏差与设定的阈值做比较;若偏差超过阈值,则结合PID算法,将偏差信息转化为速度信息,并根据该速度信息控制麦轮平台运动到位姿目标后静止;若偏差未超过阈值,则保持麦轮平台静止;s4.利用所述二维码位姿信息进行机械臂的逆运动学求解,使机械臂末端机械手的中心夹持位置达到二维码中心;经过坐标变换,求解出机械臂驱动电机的转角;驱动电机输出该转角带动机械臂末端执行器运动到被抓取物体后完成夹持动作。2.根据权利要求1所述的基于视觉识别的二维码定位抓取机器人系统算法,其特征在于:步骤s2中,采用开源二维码识别算法软件包ar_track_alvar或visp,提取二维码几何中心的位姿信息[xcurrentycurrentzcurrent]T以及四元素[qxcurrentqycurrentqzcurrentqwcurrent]T。3.根据权利要求2所述的基于视觉识别的二维码定位抓取机器人系统算法,其特征在于,步骤s3包括:s31.通过所述四元素[qxcurrentqycurrentqzcurrentqwcurrent]T得到二维码几何中心的偏航角yawcurrent,s32.设定[xgoalygoalyawgoal]T为相机与二维码之间的目标位姿;设定[xthresholdythresholdyawthreshold]T为当前二维码位姿与设定的目标位姿之间的差值临界阈值;设定[xoffsetyoffsetyawoffset]T(t)为当前时刻二维码位姿与设定的目标位姿之间的偏差;设定[vxvywz]T(t)为相机坐标系OcameraXYZ下,当前时刻麦轮移动平台几何中心的速度;s33.计算当前时刻二维码位姿与设定的目标位姿之间的偏差[xoffsetyoffsetyawoffset]T(t),其计算公式为:s34.若当前时刻二维码位姿与设定的目标位姿之间的偏差[xoffsetyoffsetyawoffset]T(t)超过所述阈值[xof...
【专利技术属性】
技术研发人员:柏龙,黄志鹏,李鑫,陈晓红,
申请(专利权)人:重庆大学,
类型:发明
国别省市:重庆,50
还没有人留言评论。发表了对其他浏览者有用的留言会获得科技券。