diff --git a/Varianten/AdapterFIDEROS/resources/input/.project b/Varianten/AdapterFIDEROS/resources/input/.project new file mode 100644 index 0000000000000000000000000000000000000000..51c04125a58701cd79e952c69e1c90f23aa39ee7 --- /dev/null +++ b/Varianten/AdapterFIDEROS/resources/input/.project @@ -0,0 +1,39 @@ +<?xml version="1.0" encoding="UTF-8"?> +<projectDescription> + <name>turtlebots</name> + <comment></comment> + <projects> + </projects> + <buildSpec> + <buildCommand> + <name>de.ovgu.featureide.core.extensibleFeatureProjectBuilder</name> + <arguments> + <dictionary> + <key>build</key> + <value>src</value> + </dictionary> + <dictionary> + <key>composer</key> + <value>de.ovgu.featureide.composer.ahead</value> + </dictionary> + <dictionary> + <key>equations</key> + <value>configs</value> + </dictionary> + <dictionary> + <key>source</key> + <value>features</value> + </dictionary> + </arguments> + </buildCommand> + <buildCommand> + <name>org.eclipse.jdt.core.javabuilder</name> + <arguments> + </arguments> + </buildCommand> + </buildSpec> + <natures> + <nature>org.eclipse.jdt.core.javanature</nature> + <nature>de.ovgu.featureide.core.featureProjectNature</nature> + </natures> +</projectDescription> diff --git a/build/sim/bot.gazebo.xacro b/build/sim/bot.gazebo.xacro index 357fa620e85482c9bce27129d63cd83c64fc46da..e681b1b9b95438290b6cf3eebac7df549b4b1dfa 100644 --- a/build/sim/bot.gazebo.xacro +++ b/build/sim/bot.gazebo.xacro @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8"?> -<robot xmlns:xacro="http://ros.org/wiki/xacro" name="turtlebot3_waffle_sim"> +<robot xmlns:xacro="http://ros.org/wiki/xacro" name="turtlebot3_waffle_pi_sim"> <xacro:arg name="laser_visual" default="false" /> <xacro:arg name="camera_visual" default="false" /> <xacro:arg name="imu_visual" default="false" /> @@ -44,15 +44,8 @@ <maxVel>1.0</maxVel> <material>Gazebo/FlatBlack</material> </gazebo> - <gazebo reference="imu_link"> - <sensor type="imu" name="imu"> - <always_on>true</always_on> - <visualize>$(arg imu_visual)</visualize> - </sensor> - <material>Gazebo/Grey</material> - </gazebo> <gazebo> - <plugin name="turtlebot3_waffle_controller" filename="libgazebo_ros_diff_drive.so"> + <plugin name="turtlebot3_waffle_pi_controller" filename="libgazebo_ros_diff_drive.so"> <commandTopic>cmd_vel</commandTopic> <odometryTopic>odom</odometryTopic> <odometryFrame>odom</odometryFrame> @@ -101,79 +94,5 @@ </imu> </plugin> </gazebo> - <gazebo reference="base_scan"> - <material>Gazebo/FlatBlack</material> - <sensor type="ray" name="lds_lfcd_sensor"> - <pose>0 0 0 0 0 0</pose> - <visualize>$(arg laser_visual)</visualize> - <update_rate>5</update_rate> - <ray> - <scan> - <horizontal> - <samples>360</samples> - <resolution>1</resolution> - <min_angle>0.0</min_angle> - <max_angle>6.28319</max_angle> - </horizontal> - </scan> - <range> - <min>0.120</min> - <max>3.5</max> - <resolution>0.015</resolution> - </range> - <noise> - <type>gaussian</type> - <mean>0.0</mean> - <stddev>0.01</stddev> - </noise> - </ray> - <plugin name="gazebo_ros_lds_lfcd_controller" filename="libgazebo_ros_laser.so"> - <topicName>scan</topicName> - <frameName>base_scan</frameName> - </plugin> - </sensor> - </gazebo> - <gazebo reference="camera_rgb_frame"> - <sensor type="depth" name="realsense_R200"> - <always_on>true</always_on> - <visualize>$(arg camera_visual)</visualize> - <camera> - <horizontal_fov>1.3439</horizontal_fov> - <image> - <width>1920</width> - <height>1080</height> - <format>R8G8B8</format> - </image> - <depth_camera /> - <clip> - <near>0.03</near> - <far>100</far> - </clip> - </camera> - <plugin name="camera_controller" filename="libgazebo_ros_openni_kinect.so"> - <baseline>0.2</baseline> - <alwaysOn>true</alwaysOn> - <updateRate>30.0</updateRate> - <cameraName>camera</cameraName> - <frameName>camera_rgb_optical_frame</frameName> - <imageTopicName>rgb/image_raw</imageTopicName> - <depthImageTopicName>depth/image_raw</depthImageTopicName> - <pointCloudTopicName>depth/points</pointCloudTopicName> - <cameraInfoTopicName>rgb/camera_info</cameraInfoTopicName> - <depthImageCameraInfoTopicName>depth/camera_info</depthImageCameraInfoTopicName> - <pointCloudCutoff>0.4</pointCloudCutoff> - <hackBaseline>0.07</hackBaseline> - <distortionK1>0.0</distortionK1> - <distortionK2>0.0</distortionK2> - <distortionK3>0.0</distortionK3> - <distortionT1>0.0</distortionT1> - <distortionT2>0.0</distortionT2> - <CxPrime>0.0</CxPrime> - <Cx>0.0</Cx> - <Cy>0.0</Cy> - <focalLength>0</focalLength> - <hackBaseline>0</hackBaseline> - </plugin> - </sensor> - </gazebo> + <!--link : https://www.raspberrypi.org/documentation/hardware/camera/--> </robot> diff --git a/build/sim/bot.urdf.xacro b/build/sim/bot.urdf.xacro index 0e9289f6c3bae4a5f2dfc9b2d173f0ffb5025daa..a268ae6cd2d2c2f5fc5f79efe38976a51b40ddbd 100644 --- a/build/sim/bot.urdf.xacro +++ b/build/sim/bot.urdf.xacro @@ -1,11 +1,7 @@ <?xml version="1.0" encoding="UTF-8"?> -<robot xmlns:xacro="http://ros.org/wiki/xacro" name="turtlebot3_waffle"> +<robot xmlns:xacro="http://ros.org/wiki/xacro" name="turtlebot3_waffle_pi"> <xacro:include filename="$(find turtlebot3_description)/urdf/common_properties.xacro" /> <xacro:include filename="$(find sim)/bot.gazebo.xacro" /> - <xacro:property name="r200_cam_rgb_px" value="0.005" /> - <xacro:property name="r200_cam_rgb_py" value="0.018" /> - <xacro:property name="r200_cam_rgb_pz" value="0.013" /> - <xacro:property name="r200_cam_depth_offset" value="0.01" /> <link name="base_footprint" /> <joint name="base_joint" type="fixed"> <parent link="base_footprint" /> @@ -16,7 +12,7 @@ <visual> <origin xyz="-0.064 0 0.0" rpy="0 0 0" /> <geometry> - <mesh filename="package://turtlebot3_description/meshes/bases/waffle_base.stl" scale="0.001 0.001 0.001" /> + <mesh filename="package://turtlebot3_description/meshes/bases/waffle_pi_base.stl" scale="0.001 0.001 0.001" /> </geometry> <material name="light_black" /> </visual> @@ -133,7 +129,7 @@ </joint> <link name="base_scan"> <visual> - <origin xyz="0 0 0" rpy="0 0 0" /> + <origin xyz="0 0 0.0" rpy="0 0 0" /> <geometry> <mesh filename="package://turtlebot3_description/meshes/sensors/lds.stl" scale="0.001 0.001 0.001" /> </geometry> @@ -152,34 +148,20 @@ </inertial> </link> <joint name="camera_joint" type="fixed"> - <origin xyz="0.064 -0.065 0.094" rpy="0 0 0" /> + <origin xyz="0.073 -0.011 0.084" rpy="0 0 0" /> <parent link="base_link" /> <child link="camera_link" /> </joint> <link name="camera_link"> - <visual> - <origin xyz="0 0 0" rpy="1.57 0 1.57" /> - <geometry> - <mesh filename="package://turtlebot3_description/meshes/sensors/r200.dae" /> - </geometry> - </visual> <collision> - <origin xyz="0.003 0.065 0.007" rpy="0 0 0" /> + <origin xyz="0.005 0.011 0.013" rpy="0 0 0" /> <geometry> - <box size="0.012 0.132 0.020" /> + <box size="0.015 0.030 0.027" /> </geometry> </collision> - <!-- This inertial field needs doesn't contain reliable data!! --> - <!-- <inertial> - <mass value="0.564" /> - <origin xyz="0 0 0" /> - <inertia ixx="0.003881243" ixy="0.0" ixz="0.0" - iyy="0.000498940" iyz="0.0" - izz="0.003879257" /> - </inertial>--> </link> <joint name="camera_rgb_joint" type="fixed"> - <origin xyz="${r200_cam_rgb_px} ${r200_cam_rgb_py} ${r200_cam_rgb_pz}" rpy="0 0 0" /> + <origin xyz="0.003 0.011 0.009" rpy="0 0 0" /> <parent link="camera_link" /> <child link="camera_rgb_frame" /> </joint> @@ -190,16 +172,4 @@ <child link="camera_rgb_optical_frame" /> </joint> <link name="camera_rgb_optical_frame" /> - <joint name="camera_depth_joint" type="fixed"> - <origin xyz="${r200_cam_rgb_px} ${r200_cam_rgb_py + r200_cam_depth_offset} ${r200_cam_rgb_pz}" rpy="0 0 0" /> - <parent link="camera_link" /> - <child link="camera_depth_frame" /> - </joint> - <link name="camera_depth_frame" /> - <joint name="camera_depth_optical_joint" type="fixed"> - <origin xyz="0 0 0" rpy="-1.57 0 -1.57" /> - <parent link="camera_depth_frame" /> - <child link="camera_depth_optical_frame" /> - </joint> - <link name="camera_depth_optical_frame" /> </robot> diff --git a/build/sim/botname.txt b/build/sim/botname.txt index 07bb3138a66f538ea0a699432c9312975b3b69c2..06115db6b4d48d5478a2d5abcc55375e585fffdc 100644 --- a/build/sim/botname.txt +++ b/build/sim/botname.txt @@ -1 +1 @@ -waffle \ No newline at end of file +waffle_pi \ No newline at end of file diff --git a/src/var/FeatureModelConfigurator/configs/test.xml b/src/var/FeatureModelConfigurator/configs/test.xml index 2346818cebe5c92c872f1136b7c1060e2f9d3646..3472dd56eb9cb7001d85127c2c602a27d34bb22e 100644 --- a/src/var/FeatureModelConfigurator/configs/test.xml +++ b/src/var/FeatureModelConfigurator/configs/test.xml @@ -5,13 +5,13 @@ <feature automatic="unselected" name="turtlebot3_burger"/> <feature automatic="unselected" name="turtlebot3_burger_for_autorace"/> <feature automatic="unselected" name="turtlebot3_burgertest1"/> - <feature manual="selected" name="turtlebot3_waffle"/> - <feature automatic="unselected" name="turtlebot3_waffle_pi"/> + <feature automatic="unselected" name="turtlebot3_waffle"/> + <feature manual="selected" name="turtlebot3_waffle_pi"/> <feature automatic="selected" name="Sensors"/> - <feature manual="selected" name="NO_CHANGE"/> - <feature automatic="unselected" name="Custom"/> - <feature automatic="unselected" name="Pi_Camera"/> - <feature automatic="unselected" name="imu"/> - <feature automatic="unselected" name="lds_lfcd_sensor"/> - <feature automatic="unselected" name="realsense_R200"/> + <feature automatic="unselected" name="NO_CHANGE"/> + <feature manual="selected" name="Custom"/> + <feature name="Pi_Camera"/> + <feature name="imu"/> + <feature name="lds_lfcd_sensor"/> + <feature name="realsense_R200"/> </configuration> diff --git a/src/var/FeatureModelConfigurator/features/ConfiguratorMain/Configurator.jak b/src/var/FeatureModelConfigurator/features/ConfiguratorMain/Configurator.jak index 9177edfaa6b8133c3ffe21c9c12f2bfa9a5b0125..8cf93aa009fac0e03cea9fb3e1585882e7566b27 100644 --- a/src/var/FeatureModelConfigurator/features/ConfiguratorMain/Configurator.jak +++ b/src/var/FeatureModelConfigurator/features/ConfiguratorMain/Configurator.jak @@ -89,7 +89,7 @@ public class Configurator { } } //check if the mode should be custom - if(bCustomSenors) + if(bCustomSenors||!oMode.hasAttributes()) oMode.setAttribute("param", "Custom"); } diff --git a/src/var/FeatureModelConfigurator/resources/output/featuremodel.xml b/src/var/FeatureModelConfigurator/resources/output/featuremodel.xml index a8bd65a9a6d9fe8504b9b3612797b34d8d128fff..5145399b09271131f9e156318751d0a0cedf8400 100644 --- a/src/var/FeatureModelConfigurator/resources/output/featuremodel.xml +++ b/src/var/FeatureModelConfigurator/resources/output/featuremodel.xml @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8"?> <specification> - <templates name="turtlebot3_waffle" /> + <templates name="turtlebot3_waffle_pi" /> <sensors> - <mode param="NO_CHANGE" /> + <mode param="Custom" /> </sensors> </specification> diff --git a/src/var/FeatureModelConfigurator/src/Configurator.jak b/src/var/FeatureModelConfigurator/src/Configurator.jak index 9c9d5addbf14c83218863d4eb59095a219ed5d44..a09c23337bce5607ade934cd52b603f8101c8d94 100644 --- a/src/var/FeatureModelConfigurator/src/Configurator.jak +++ b/src/var/FeatureModelConfigurator/src/Configurator.jak @@ -91,7 +91,7 @@ abstract class Configurator$$ConfiguratorMain { } } //check if the mode should be custom - if(bCustomSenors) + if(bCustomSenors||!oMode.hasAttributes()) oMode.setAttribute("param", "Custom"); } @@ -176,22 +176,12 @@ abstract class Configurator$$ConfiguratorMain { } } -SoUrCe turtlebot3_waffle "../features/turtlebot3_waffle/Configurator.jak";/** +SoUrCe turtlebot3_waffle_pi "../features/turtlebot3_waffle_pi/Configurator.jak";/** * TODO description */ -abstract class Configurator$$turtlebot3_waffle extends Configurator$$ConfiguratorMain { +public class Configurator extends Configurator$$ConfiguratorMain { public void save() { - Super().addToModuleList("turtlebot3_waffle"); - Super().save(); - } -} - -SoUrCe NO_CHANGE "../features/NO_CHANGE/Configurator.jak";/** - * TODO description - */ -public class Configurator extends Configurator$$turtlebot3_waffle { - public void save() { - Super().addToModuleList("NO_CHANGE"); + Super().addToModuleList("turtlebot3_waffle_pi"); Super().save(); } } \ No newline at end of file diff --git a/src/var/FeatureModelConfigurator/src/Configurator.java b/src/var/FeatureModelConfigurator/src/Configurator.java index 7301a67da17130a2830bf64b90f4de4a1c7f3327..3971d09b0eb66639750b2b006bbc50a8efa59a37 100644 --- a/src/var/FeatureModelConfigurator/src/Configurator.java +++ b/src/var/FeatureModelConfigurator/src/Configurator.java @@ -91,7 +91,7 @@ abstract class Configurator$$ConfiguratorMain { } } //check if the mode should be custom - if(bCustomSenors) + if(bCustomSenors||!oMode.hasAttributes()) oMode.setAttribute("param", "Custom"); } @@ -179,19 +179,9 @@ abstract class Configurator$$ConfiguratorMain { /** * TODO description */ -abstract class Configurator$$turtlebot3_waffle extends Configurator$$ConfiguratorMain { +public class Configurator extends Configurator$$ConfiguratorMain { public void save() { - super.addToModuleList("turtlebot3_waffle"); - super.save(); - } -} - -/** - * TODO description - */ -public class Configurator extends Configurator$$turtlebot3_waffle { - public void save() { - super.addToModuleList("NO_CHANGE"); + super.addToModuleList("turtlebot3_waffle_pi"); super.save(); } } \ No newline at end of file diff --git a/src/var/FeatureModelImplGenerator/template/Main.jak b/src/var/FeatureModelImplGenerator/template/Main.jak index 9177edfaa6b8133c3ffe21c9c12f2bfa9a5b0125..8cf93aa009fac0e03cea9fb3e1585882e7566b27 100644 --- a/src/var/FeatureModelImplGenerator/template/Main.jak +++ b/src/var/FeatureModelImplGenerator/template/Main.jak @@ -89,7 +89,7 @@ public class Configurator { } } //check if the mode should be custom - if(bCustomSenors) + if(bCustomSenors||!oMode.hasAttributes()) oMode.setAttribute("param", "Custom"); }