Skip to content

Commit

Permalink
Merge branch 'ezBot-ROS_ws' of https://github.com/Ensmasteel/ezBot in…
Browse files Browse the repository at this point in the history
…to ezBot-ROS_ws
  • Loading branch information
Thiefish committed Jan 29, 2024
2 parents cd23143 + 722cb62 commit 082a906
Show file tree
Hide file tree
Showing 16 changed files with 2,022 additions and 3 deletions.
18 changes: 18 additions & 0 deletions rpi-pico/src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,16 @@ int runCommand(){
Serial.print(arg3);
Serial.print(" ");
Serial.println(arg4);


//run the actual steppers
steppers[0]->setSpeed(arg1);
steppers[1]->setSpeed(arg2);
steppers[2]->setSpeed(arg3);
steppers[3]->setSpeed(arg4);



break;
default:
Serial.print("Unknown command: ");
Expand All @@ -111,6 +121,14 @@ int runCommand(){


void loop() {


//run speed each motor
for (int i = 0; i < 4; i++)
{
steppers[i]->runSpeed();
}

while(Serial2.available() > 0){
chr = Serial2.read();

Expand Down
2 changes: 1 addition & 1 deletion src/ezbot_descr_simul/description/lidar.xacro
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@

<sensor name="laser" type="ray">
<pose> 0.055 0 0.03 0 0 0 </pose>
<visualize>true</visualize>
<visualize>false</visualize>
<update_rate>10</update_rate>
<ray>
<scan>
Expand Down
28 changes: 28 additions & 0 deletions src/ezbot_descr_simul/description/robot_core.xacro
Original file line number Diff line number Diff line change
Expand Up @@ -393,4 +393,32 @@
</collision>
</gazebo>

<link name="renverseur_de_panneaux">
<visual>
<origin xyz="0.055 0.11 0.10"/>
<geometry>
<box size="0.05 0.20 0.05"/>
</geometry>
<material name="orange"/>
</visual>
<collision>
<origin xyz="0.055 0.11 0.10"/>
<geometry>
<box size="0.05 0.20 0.05"/>
</geometry>
</collision>
<xacro:inertial_box mass="0.5" x="0.05" y="0.15" z="0.05">
<origin xyz="0.055 0 0.10" rpy="0 0 0"/>
</xacro:inertial_box>
</link>

<joint name= "renverseur_de_panneaux_joint" type="fixed">
<parent link="chassis"/>
<child link="renverseur_de_panneaux"/>
</joint>

<gazebo reference="renverseur_de_panneaux">
<material>Gazebo/Purple</material>
</gazebo>

</robot>
2 changes: 1 addition & 1 deletion src/ezbot_descr_simul/launch/launch_sim.launch.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ def generate_launch_description():
DeclareLaunchArgument(
'world',
#default_value=[os.path.join('ezbot_gazebo','worlds','table2024.world'), ''],
default_value=[os.path.join(get_package_share_directory("ezbot_gazebo"), 'worlds', 'table2024Poteaux.world'), ''],
default_value=[os.path.join(get_package_share_directory("ezbot_gazebo"), 'worlds', 'table_with_panneaux.world'), ''],
description='SDF world file'),
rsp,
spawn_entity,
Expand Down
1 change: 1 addition & 0 deletions src/ezbot_descr_simul/package.xml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
<depend>stg_msgs</depend>
<depend>cv_bridge</depend>
<depend>image_transport</depend>
<depend>python3-opencv</depend>
<depend>rclpy</depend>

<test_depend>ament_lint_auto</test_depend>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
material solarPanelMat/Diffuse
{
receive_shaddows off
technique
{
pass
{
texture_unit
{
texture texture.png
}
}
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
11 changes: 11 additions & 0 deletions src/ezbot_gazebo/models/SolarPanel/model.config
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<?xml version="1.0" ?>
<model>
<name>SolarPanel</name>
<version>1.0</version>
<sdf version="1.7">model.sdf</sdf>
<author>
<name>Vincent Belpois</name>
<email>[email protected]</email>
</author>
<description>solar panel for the table for the 2024 Coupe de France de Robotique and EuroBot</description>
</model>
132 changes: 132 additions & 0 deletions src/ezbot_gazebo/models/SolarPanel/model.sdf
Original file line number Diff line number Diff line change
@@ -0,0 +1,132 @@
<?xml version='1.0'?>
<sdf version='1.7'>
<model name='SolarPanel'>



<link name="solar_panel_base_link">

<gravity>0</gravity>
<visual name="visual">
<geometry>
<mesh>
<uri>supportSolarPanel.dae</uri>
<scale>1 1 1</scale>
</mesh>
</geometry>
</visual>
</link>


<link name='solar_panel'>
<inertial>
<inertia>
<ixx>0.01</ixx>
<ixy>0</ixy>
<ixz>0</ixz>
<iyy>0.01</iyy>
<iyz>0</iyz>
<izz>0.01</izz>
</inertia>
</inertial>
<pose>0 0 0.055 0 0 3.141592</pose>
<visual name='visual'>
<pose>0 0 0 0 0 0</pose>
<geometry>
<mesh>
<uri>solarPanelTextured.dae</uri>
<scale>1 1 1</scale>
</mesh>
</geometry>
<material>
<lighting>1</lighting>
<script>
<uri>materials/scripts</uri>
<uri>materials/textures</uri>
<name>solarPanelMat/Diffuse</name>
<name>Gazebo/Grey</name>
</script>
<shader type='pixel'/>
</material>
<transparency>0</transparency>
<cast_shadows>1</cast_shadows>
</visual>
<collision name='collision'>
<laser_retro>0</laser_retro>
<max_contacts>10</max_contacts>
<pose>0 0 0 0 -0 0</pose>
<geometry>
<mesh>
<uri>solarPanelTextured.dae</uri>
<scale>1 1 1</scale>
</mesh>
</geometry>
<surface>
<friction>
<ode>
<mu>1</mu>
<mu2>1</mu2>
<fdir1>0 0 0</fdir1>
<slip1>0</slip1>
<slip2>0</slip2>
</ode>
<torsional>
<coefficient>1</coefficient>
<patch_radius>0</patch_radius>
<surface_radius>0</surface_radius>
<use_patch_radius>1</use_patch_radius>
<ode>
<slip>0</slip>
</ode>
</torsional>
</friction>
<bounce>
<restitution_coefficient>0</restitution_coefficient>
<threshold>1e+06</threshold>
</bounce>
<contact>
<collide_without_contact>0</collide_without_contact>
<collide_without_contact_bitmask>1</collide_without_contact_bitmask>
<collide_bitmask>1</collide_bitmask>
<ode>
<soft_cfm>0</soft_cfm>
<soft_erp>0.2</soft_erp>
<kp>1e+13</kp>
<kd>1</kd>
<max_vel>0.01</max_vel>
<min_depth>0.01</min_depth>
</ode>
<bullet>
<split_impulse>1</split_impulse>
<split_impulse_penetration_threshold>-0.01</split_impulse_penetration_threshold>
<soft_cfm>0</soft_cfm>
<soft_erp>0.2</soft_erp>
<kp>1e+13</kp>
<kd>1</kd>
</bullet>
</contact>
</surface>
</collision>
</link>
<allow_auto_disable>1</allow_auto_disable>

<joint name="revolution" type="revolute">
<parent>solar_panel_base_link</parent>
<child>solar_panel</child>
<axis>
<xyz>0 0 1</xyz>
<dynamics>
<friction>0.005</friction>
<damping>0.001</damping>
</dynamics>
</axis>
<pose>0 0 0 0 -0 0</pose>
</joint>


<joint name ='fix' type='fixed'>
<parent>world</parent>
<child>solar_panel_base_link</child>
</joint>
</model>
</sdf>
Binary file not shown.
Loading

0 comments on commit 082a906

Please sign in to comment.