티스토리 뷰
자율시스템설계 중간 정리
3-4문제
🔷URDF
- Unified Robotics Description Format
로봇 모델을 표현하기 위한 xml 파일로, link와 joint 등의 조합으로 로봇을 표현한다.
예시
더보기
<robot name="testbot">
<!-- 로봇 본체 -->
<link name="base_link">
<visual>
<geometry>
<box size="0.5 0.4 0.1"/>
</geometry>
<origin xyz="0 0 0.05"/>
<material>
<color rgba="0.5 0.5 0.5 1.0"/>
</material>
</visual>
<collision>
<origin xyz="0 0 0.05"/>
<geometry>
<box size="0.5 0.4 0.1"/>
</geometry>
</collision>
<inertial>
<mass value="5.0"/>
<origin xyz="0 0 0.05"/>
<inertia ixx="0.1" ixy="0" ixz="0" iyy="0.1" iyz="0" izz="0.1"/>
</inertial>
</link>
<!-- 바퀴 4개 -->
<link name="wheel_front_left">
<visual>
<geometry>
<cylinder radius="0.05" length="0.02"/>
</geometry>
<origin xyz="0 0 0" rpy="1.5708 0 0"/>
<material>
<color rgba="0 0 0 1"/>
</material>
</visual>
<collision>
<origin xyz="0 0 0" rpy="1.5708 0 0"/>
<geometry>
<cylinder radius="0.05" length="0.02"/>
</geometry>
</collision>
<inertial>
<mass value="0.5"/>
<origin xyz="0 0 0"/>
<inertia ixx="0.001" ixy="0.0" ixz="0.0"
iyy="0.001" iyz="0.0"
izz="0.001"/>
</inertial>
</link>
<link name="wheel_front_right">
<visual>
<geometry>
<cylinder radius="0.05" length="0.02"/>
</geometry>
<origin xyz="0 0 0" rpy="1.5708 0 0"/>
<material>
<color rgba="0 0 0 1"/>
</material>
</visual>
<collision>
<origin xyz="0 0 0" rpy="1.5708 0 0"/>
<geometry>
<cylinder radius="0.05" length="0.02"/>
</geometry>
</collision>
<inertial>
<mass value="0.5"/>
<origin xyz="0 0 0"/>
<inertia ixx="0.001" ixy="0.0" ixz="0.0"
iyy="0.001" iyz="0.0"
izz="0.001"/>
</inertial>
</link>
<link name="wheel_back_left">
<visual>
<geometry>
<cylinder radius="0.05" length="0.02"/>
</geometry>
<origin xyz="0 0 0" rpy="1.5708 0 0"/>
<material>
<color rgba="0 0 0 1"/>
</material>
</visual>
<collision>
<origin xyz="0 0 0" rpy="1.5708 0 0"/>
<geometry>
<cylinder radius="0.05" length="0.02"/>
</geometry>
</collision>
<inertial>
<mass value="0.5"/>
<origin xyz="0 0 0"/>
<inertia ixx="0.001" ixy="0.0" ixz="0.0"
iyy="0.001" iyz="0.0"
izz="0.001"/>
</inertial>
</link>
<link name="wheel_back_right">
<visual>
<geometry>
<cylinder radius="0.05" length="0.02"/>
</geometry>
<origin xyz="0 0 0" rpy="1.5708 0 0"/>
<material>
<color rgba="0 0 0 1"/>
</material>
</visual>
<collision>
<origin xyz="0 0 0" rpy="1.5708 0 0"/>
<geometry>
<cylinder radius="0.05" length="0.02"/>
</geometry>
</collision>
<inertial>
<mass value="0.5"/>
<origin xyz="0 0 0"/>
<inertia ixx="0.001" ixy="0.0" ixz="0.0"
iyy="0.001" iyz="0.0"
izz="0.001"/>
</inertial>
</link>
<!-- 조인트 -->
<joint name="front_left_wheel_joint" type="continuous">
<parent link="base_link"/>
<child link="wheel_front_left"/>
<origin xyz="0.2 0.15 0.025" rpy="0 0 0"/>
<axis xyz="0 1 0"/>
</joint>
<joint name="front_right_wheel_joint" type="continuous">
<parent link="base_link"/>
<child link="wheel_front_right"/>
<origin xyz="0.2 -0.15 0.025" rpy="0 0 0"/>
<axis xyz="0 1 0"/>
</joint>
<joint name="back_left_wheel_joint" type="continuous">
<parent link="base_link"/>
<child link="wheel_back_left"/>
<origin xyz="-0.2 0.15 0.025" rpy="0 0 0"/>
<axis xyz="0 1 0"/>
</joint>
<joint name="back_right_wheel_joint" type="continuous">
<parent link="base_link"/>
<child link="wheel_back_right"/>
<origin xyz="-0.2 -0.15 0.025" rpy="0 0 0"/>
<axis xyz="0 1 0"/>
</joint>
<!-- Gazebo 플러그인 -->
<gazebo>
<plugin name="diff_drive_controller" filename="libgazebo_ros_diff_drive.so">
<ros>
<namespace>/</namespace>
<remapping>cmd_vel:=/cmd_vel</remapping>
</ros>
<updateRate>30.0</updateRate>
<leftJoint>front_left_wheel_joint</leftJoint>
<rightJoint>front_right_wheel_joint</rightJoint>
<wheelSeparation>0.3</wheelSeparation>
<wheelDiameter>0.1</wheelDiameter>
<wheelAcceleration>1.0</wheelAcceleration>
<wheelTorque>5.0</wheelTorque>
<robotBaseFrame>base_link</robotBaseFrame>
</plugin>
</gazebo>
</robot>
구성: link, joint, visual, collision, inertial, transmission 등
Link
- collision 충돌 정의를 위한 형상 구성
- joint로 관절 연결
- visual(외관)
- geometry, material, origin,
- inertial: 질량 설정
Joint
- 두 링크(parent, child)를 이어주는 역할
- 직선, 회전 등등 joint 정의 가능
- DoF: 움직이는 축... 수?
정의 요소
- <origin> 이전 joint에 대한 상대 좌표로 origin 지정?
- <axis> 관절의 축 표현, 어떤 방향으로 움직일지 지정
- <limit> limit 관절의 최대 힘, 구동범위, 최대 속도 지정
꼭나오는 문제 Robot Kinematics
🔷Forward Kinematics
주관심사: end effector의 위치(좌표)
task 공간에서 end-effector의 pose를 찾는 것
관절의 각도로부터 좌표를 얻음
$$(x,y)=f(\theta_{1},\theta_{2})$$
rotation matrix + translation matrix (4 x 4 matrix)
rotation과 translation 각 3DoF
방법
- 회전 matrix 찾기(각 축 단위 벡터가 어떻게 됐는지)
- 단위벡터이기에 정규화 필요(길이 1로 맞추기)
- 평행이동 시키기 (translation matrix 추가)
여러 관절에의 적용
base부터 $T_{1}, T_{2}, T_{3} \cdots$ 이면 $T_{3}T_{2}T_{1}$
rotation은 순서가 매우 중요함
🔷Inverse Kinematics
주관심사: 관절의 각도
end effector 혹은 관절의 좌표로부터 각도를 얻음
각 관절까지 ?
T1T2T3
'Computer Science > RO' 카테고리의 다른 글
라즈베리파이 와이파이 연결 (학교 공용 와이파이 eduroam) (0) | 2025.02.23 |
---|---|
터틀봇3 라즈베리파이 부팅 오류 검은색 cmd (0) | 2025.02.20 |
ROS (0) | 2025.02.17 |
ROS 파이썬 opencv 적용해보기 (1) | 2024.11.19 |
ROS2 서비스 서버, 클라이언트 만들기 (0) | 2024.11.17 |
ROS2 서비스 정의 만들기 (1) | 2024.11.16 |
ROS2 rqt로 토픽 발행하기, log 구현하고 rqt로 확인하기 (1) | 2024.11.15 |
ROS2 여러 토픽 구독, 발행하기 (1) | 2024.11.14 |
반응형
공지사항
최근에 올라온 글
최근에 달린 댓글
- Total
- Today
- Yesterday
링크
TAG
- 밀리머신
- Liiv M
- 배송기간
- 맛집
- f-94w
- 할인
- a모바일
- 메쉬 밴드
- 카카오페이
- 알리익스프레스
- 파스타
- 리브모바일
- 문서 스캔
- 알뜰폰요금제
- 네이버페이
- 10만포인트
- 티스토리챌린지
- 시계 줄
- 알뜰 요금제
- 북문
- 경북대
- 무어머신
- 방향장
- 오블완
- 계산방법
- f-91w
- 리브엠
- mealy
- 카시오
- 교체
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | ||||
4 | 5 | 6 | 7 | 8 | 9 | 10 |
11 | 12 | 13 | 14 | 15 | 16 | 17 |
18 | 19 | 20 | 21 | 22 | 23 | 24 |
25 | 26 | 27 | 28 | 29 | 30 | 31 |
글 보관함