forked from eborghi10/create_autonomy
-
-
Notifications
You must be signed in to change notification settings - Fork 38
Lucas S. files for the April tags environment #107
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
LucasJSch
wants to merge
10
commits into
RoboticaUtnFrba:kinetic-devel
Choose a base branch
from
LucasJSch:LucasJS-world
base: kinetic-devel
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 3 commits
Commits
Show all changes
10 commits
Select commit
Hold shift + click to select a range
f970b60
Added April tags environment files.
LucasJSch f6e7a5e
Modified create_base.xacro for spawning the April Tag on the robot.
LucasJSch 07abfeb
Addressed some changes for better visualizing April tags.
LucasJSch 6e050da
Addressed some of the requested changes.
LucasJSch 1d40759
Deleted unncessary lights from world file.
LucasJSch 1e4a6f0
Addressed some requested changes.
LucasJSch 4455664
Addressed requested changes.
LucasJSch c198d4c
Reduced environment size and adjusted camera rotation.
LucasJSch 3ed9810
Addressed requested changes.
LucasJSch 6e19b46
Merge branch 'kinetic-devel' into LucasJS-world
LucasJSch File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
<?xml version="1.0" ?> | ||
<robot xmlns:xacro="http://ros.org/wiki/xacro"> | ||
|
||
<xacro:macro name="april_tag"> | ||
|
||
<xacro:property name="april_tag_z_offset" value="0.3"/> | ||
|
||
<link name="april_tag_link"> | ||
<visual> | ||
<origin xyz=" 0 0 ${april_tag_z_offset}" rpy="0 0 0" /> | ||
LucasJSch marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
<geometry> | ||
<box size="0.5 0.5 0.05" /> | ||
</geometry> | ||
</visual> | ||
</link> | ||
|
||
<joint name="april_tag_joint" type="fixed"> | ||
<parent link="base_link" /> | ||
LucasJSch marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
<child link="april_tag_link"/> | ||
</joint> | ||
|
||
<gazebo reference="april_tag_link"> | ||
<visual> | ||
<material> | ||
<script> | ||
<uri>model://create_april_tags/materials/scripts </uri> | ||
<uri>model://create_april_tags/materials/textures </uri> | ||
<name>AprilTag5</name> | ||
</script> | ||
</material> | ||
</visual> | ||
</gazebo> | ||
|
||
</xacro:macro> | ||
|
||
</robot> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
<launch> | ||
<arg name="env" default="april_tags"/> | ||
<param name="create1/amcl/initial_pose_x" value="0"/> | ||
LucasJSch marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
<param name="create1/amcl/initial_pose_y" value="0"/> | ||
<param name="create1/amcl/initial_pose_a" value="0"/> | ||
|
||
<param name="create2/amcl/initial_pose_x" value="0"/> | ||
<param name="create2/amcl/initial_pose_y" value="0"/> | ||
<param name="create2/amcl/initial_pose_a" value="0"/> | ||
|
||
<arg name="paused" value="$(optenv PAUSED false)"/> | ||
<arg name="gui" value="$(optenv GUI true)"/> | ||
<arg name="debug" value="$(optenv DEBUG false)"/> | ||
|
||
<env name="GAZEBO_MODEL_PATH" value="$(find ca_gazebo)/models"/> | ||
LucasJSch marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
||
<!-- Launch Gazebo world --> | ||
LucasJSch marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
<include file="$(find gazebo_ros)/launch/empty_world.launch"> | ||
<arg name="debug" value="$(arg debug)" /> | ||
<arg name="gui" value="$(arg gui)" /> | ||
<arg name="paused" value="$(arg paused)"/> | ||
<arg name="use_sim_time" value="true"/> | ||
<arg name="verbose" value="true"/> | ||
<arg name="world_name" value="$(find ca_gazebo)/worlds/$(arg env).world"/> | ||
</include> | ||
|
||
<!-- Spawn robot/s --> | ||
<include file="$(find ca_gazebo)/launch/spawn_multirobot.launch"/> | ||
|
||
<!-- map_server --> | ||
<include file="$(find ca_move_base)/launch/map_server.launch"> | ||
<arg name="env" value="$(arg env)"/> | ||
</include> | ||
|
||
<!-- publish the image --> | ||
LucasJSch marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
||
</launch> |
107 changes: 107 additions & 0 deletions
107
ca_gazebo/models/create_april_tags/materials/scripts/apriltag.material
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,107 @@ | ||
material AprilTag0 | ||
{ | ||
technique | ||
{ | ||
pass | ||
{ | ||
ambient 1.0 1.0 1.0 1.0 | ||
diffuse 1.0 1.0 1.0 1.0 | ||
specular 1.0 1.0 1.0 1.0 12.5 | ||
|
||
texture_unit | ||
{ | ||
texture apriltag0.png | ||
} | ||
} | ||
} | ||
} | ||
|
||
material AprilTag1 | ||
{ | ||
technique | ||
{ | ||
pass | ||
{ | ||
ambient 1.0 1.0 1.0 1.0 | ||
diffuse 1.0 1.0 1.0 1.0 | ||
specular 1.0 1.0 1.0 1.0 12.5 | ||
|
||
texture_unit | ||
{ | ||
texture apriltag1.png | ||
} | ||
} | ||
} | ||
} | ||
|
||
material AprilTag2 | ||
{ | ||
technique | ||
{ | ||
pass | ||
{ | ||
ambient 1.0 1.0 1.0 1.0 | ||
diffuse 1.0 1.0 1.0 1.0 | ||
specular 1.0 1.0 1.0 1.0 12.5 | ||
|
||
texture_unit | ||
{ | ||
texture apriltag2.png | ||
} | ||
} | ||
} | ||
} | ||
|
||
material AprilTag3 | ||
{ | ||
technique | ||
{ | ||
pass | ||
{ | ||
ambient 1.0 1.0 1.0 1.0 | ||
diffuse 1.0 1.0 1.0 1.0 | ||
specular 1.0 1.0 1.0 1.0 12.5 | ||
|
||
texture_unit | ||
{ | ||
texture apriltag3.png | ||
} | ||
} | ||
} | ||
} | ||
|
||
material AprilTag4 | ||
{ | ||
technique | ||
{ | ||
pass | ||
{ | ||
ambient 1.0 1.0 1.0 1.0 | ||
diffuse 1.0 1.0 1.0 1.0 | ||
specular 1.0 1.0 1.0 1.0 12.5 | ||
|
||
texture_unit | ||
{ | ||
texture apriltag4.png | ||
} | ||
} | ||
} | ||
} | ||
|
||
material AprilTag5 | ||
{ | ||
technique | ||
{ | ||
pass | ||
{ | ||
ambient 1.0 1.0 1.0 1.0 | ||
diffuse 1.0 1.0 1.0 1.0 | ||
specular 1.0 1.0 1.0 1.0 12.5 | ||
|
||
texture_unit | ||
{ | ||
texture apriltag5.png | ||
} | ||
} | ||
} | ||
} |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
<?xml version="1.0" ?> | ||
<model> | ||
<name>Lucas S. april tags assignment house</name> | ||
<version>1.0</version> | ||
<sdf version="1.6">model.sdf</sdf> | ||
<description></description> | ||
<models> | ||
<uri>model://create_april_tags</uri> | ||
</models> | ||
</model> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,98 @@ | ||
<?xml version='1.0'?> | ||
<sdf version='1.6'> | ||
<model name='create_april_tags'> | ||
<static>1</static> | ||
|
||
<link name='AprilTag1'> | ||
<pose frame=''>9.0 9.0 -1.2 0 0 0</pose> | ||
LucasJSch marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
<self_collide>0</self_collide> | ||
<kinematic>0</kinematic> | ||
<visual name='AprilTag1_Visual'> | ||
<pose frame=''>0 0 1.25 0 -0 0</pose> | ||
<geometry> | ||
<box> | ||
<size>0.5 0.5 0.05 </size> | ||
</box> | ||
</geometry> | ||
<material> | ||
<script> | ||
<uri>model://create_april_tags/materials/scripts </uri> | ||
<uri>model://create_april_tags/materials/textures </uri> | ||
<name>AprilTag1</name> | ||
</script> | ||
</material> | ||
<cast_shadows>1</cast_shadows> | ||
<transparency>0</transparency> | ||
</visual> | ||
</link> | ||
|
||
<link name='AprilTag2'> | ||
<pose frame=''>-9.0 -9.0 -1.2 0 0 0</pose> | ||
<self_collide>0</self_collide> | ||
<kinematic>0</kinematic> | ||
<visual name='AprilTag2_Visual'> | ||
<pose frame=''>0 0 1.25 0 -0 0</pose> | ||
<geometry> | ||
<box> | ||
<size>0.5 0.5 0.05 </size> | ||
</box> | ||
</geometry> | ||
<material> | ||
<script> | ||
<uri>model://create_april_tags/materials/scripts/apriltag.material </uri> | ||
<name>AprilTag2</name> | ||
</script> | ||
</material> | ||
<cast_shadows>1</cast_shadows> | ||
<transparency>0</transparency> | ||
</visual> | ||
</link> | ||
|
||
<link name='AprilTag3'> | ||
<pose frame=''>-9.0 9.0 -1.2 0 0 0</pose> | ||
<self_collide>0</self_collide> | ||
<kinematic>0</kinematic> | ||
<visual name='AprilTag3_Visual'> | ||
<pose frame=''>0 0 1.25 0 -0 0</pose> | ||
<geometry> | ||
<box> | ||
<size>0.5 0.5 0.05 </size> | ||
</box> | ||
</geometry> | ||
<material> | ||
<script> | ||
<uri>model://create_april_tags/materials/scripts </uri> | ||
<uri>model://create_april_tags/materials/textures </uri> | ||
<name>AprilTag3</name> | ||
</script> | ||
</material> | ||
<cast_shadows>1</cast_shadows> | ||
<transparency>0</transparency> | ||
</visual> | ||
</link> | ||
|
||
<link name='AprilTag4'> | ||
LucasJSch marked this conversation as resolved.
Show resolved
Hide resolved
|
||
<pose frame=''>9.0 -9.0 -1.2 0 0 0</pose> | ||
<self_collide>0</self_collide> | ||
<kinematic>0</kinematic> | ||
<visual name='AprilTag4_Visual'> | ||
<pose frame=''>0 0 1.25 0 -0 0</pose> | ||
<geometry> | ||
<box> | ||
<size>0.5 0.5 0.05 </size> | ||
</box> | ||
</geometry> | ||
<material> | ||
<script> | ||
<uri>model://create_april_tags/materials/scripts </uri> | ||
<uri>model://create_april_tags/materials/textures </uri> | ||
<name>AprilTag4</name> | ||
</script> | ||
</material> | ||
<cast_shadows>1</cast_shadows> | ||
<transparency>0</transparency> | ||
</visual> | ||
</link> | ||
|
||
</model> | ||
</sdf> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
<?xml version="1.0" ?> | ||
<model> | ||
<name>Lucas S. camera</name> | ||
<version>1.0</version> | ||
<sdf version="1.6">model.sdf</sdf> | ||
<description></description> | ||
<models> | ||
<uri>model://camera</uri> | ||
</models> | ||
</model> | ||
LucasJSch marked this conversation as resolved.
Show resolved
Hide resolved
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
<?xml version='1.0'?> | ||
<sdf version='1.6'> | ||
<model name='camera'> | ||
<static>true</static> | ||
<link name='link'> | ||
<visual name='visual'> | ||
<geometry> | ||
<box> | ||
<size>0.1 0.1 0.1</size> | ||
</box> | ||
</geometry> | ||
</visual> | ||
<sensor name='apriltag_camera' type='camera'> | ||
<camera> | ||
<save enabled="false"> | ||
LucasJSch marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
<path>/tmp/camera_save_tutorial</path> | ||
LucasJSch marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
</save> | ||
<horizontal_fov>1.047</horizontal_fov> | ||
<image> | ||
<width>5760</width> | ||
LucasJSch marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
<height>3240</height> | ||
</image> | ||
<clip> | ||
<near>0.1</near> | ||
<far>500</far> | ||
</clip> | ||
</camera> | ||
<always_on>1</always_on> | ||
<update_rate>50</update_rate> | ||
<plugin name="camera_controller" filename="libgazebo_ros_camera.so"> | ||
<alwaysOn>true</alwaysOn> | ||
<updateRate>0.0</updateRate> | ||
LucasJSch marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
<cameraName>/apriltag_camera</cameraName> | ||
<imageTopicName>image_raw</imageTopicName> | ||
LucasJSch marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
<cameraInfoTopicName>camera_info</cameraInfoTopicName> | ||
<frameName>camera_link</frameName> | ||
LucasJSch marked this conversation as resolved.
Show resolved
Hide resolved
|
||
<hackBaseline>0.07</hackBaseline> | ||
<distortionK1>0.0</distortionK1> | ||
<distortionK2>0.0</distortionK2> | ||
<distortionK3>0.0</distortionK3> | ||
<distortionT1>0.0</distortionT1> | ||
<distortionT2>0.0</distortionT2> | ||
</plugin> | ||
</sensor> | ||
</link> | ||
</model> | ||
|
||
|
||
</sdf> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
<?xml version="1.0" ?> | ||
<model> | ||
<name>Lucas S. four walls</name> | ||
<version>1.0</version> | ||
<sdf version="1.6">model.sdf</sdf> | ||
<description></description> | ||
<models> | ||
<uri>model://create_four_walls</uri> | ||
</models> | ||
</model> |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I just realized about this. Is the visual tag mandatory? Since you only want to apply a texture, do you need to create this visual block?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If I delete this, the Apriltag doesn't appear. This xacro corresponds to the Apriltag of the robot.
How can a texture be applied if there is no visual object to apply it to?