Skip to content

Commit

Permalink
feat: add vehicle_launch package (#168)
Browse files Browse the repository at this point in the history
* release v0.4.0

* Modify to change calib param for each vehicle (#51)

* add vehicle id to change parameter of each vehicle

Signed-off-by: Yukihiro Saito <yukky.saito@gmail.com>

* add vehicle id to change param for each vehicle

Signed-off-by: Yukihiro Saito <yukky.saito@gmail.com>

* add some dependencies (#54)

* Add some scenario-simulation specifiec parameters as arguments (#57)

* Add some scenario-simulation specifiec parameters as arguments

* Update arg to pass 'initial_engage_state' to simple_planning_simulator

* Add new optional argument 'rviz_args'

* Rename some roslaunch arguments

* Remove unneeded arguments

* removed ROS1 package

Signed-off-by: mitsudome-r <ryohsuke.mitsudome@tier4.jp>

* Revert "removed ROS1 package"

This reverts commit 561686456a78d767c1de9e976ef451b340d65343.

* add COLCON_IGNORE file to all ROS1 packages

Signed-off-by: mitsudome-r <ryohsuke.mitsudome@tier4.jp>

* rename *.launch files to *.launch.xml

Signed-off-by: mitsudome-r <ryohsuke.mitsudome@tier4.jp>

* port vehicle_launch

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* Add linters (#30)

* Ros2 v0.8.0 vehicle launch (#55)

* restore file name

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* Add default config of aip_x1 (#141)

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Pass all args to vehicle_interface.launch (#147)

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Revert "restore file name"

This reverts commit 3e28661e8ba1a44cc570ca19b7b4759ba0bf0941.

* fix vehicle_interface.launch arg

Signed-off-by: Takamasa Horibe <horibe.takamasa@gmail.com>

* [vehicle_launch]: Remove pass_all_args

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

Co-authored-by: Kenji Miyake <31987104+kenji-miyake@users.noreply.github.com>
Co-authored-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Ros2 v0.8.0 fix packages (#64)

* add vehicle_param_file to simple planning simulator

* add vehicle_param_file to lane change planner

* Move individual params to a separate package (#100)

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* add use_sim-time option (#99)

* Sync public repo (#185)

* add tier4 usbcam (#104)

* add tier4 usbcam

* change version

* tier4/ros2

* Ros2 vehicle info param server (#96)

* add vehicle info param server

* delete vehicle param file

Co-authored-by: taikitanaka <ttatcoder@outlook.jp>

* Ros2 fix topic name part2 (#89)

* Fix topic name for traffic_light_classifier

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix topic name for traffic_light_visualization

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

* Fix topic name for traffic_light_ssd_fine_detector

Signed-off-by: Takagi, Isamu <isamu.takagi@tier4.jp>

Co-authored-by: taikitanaka3 <65527974+taikitanaka3@users.noreply.github.com>
Co-authored-by: tkimura4 <tomoya.kimura@tier4.jp>
Co-authored-by: taikitanaka <ttatcoder@outlook.jp>
Co-authored-by: Takagi, Isamu <43976882+isamu-takagi@users.noreply.github.com>

* add group (#195)

* Use set_parameter for use_sim_time (#198)

* Use set_parameter for use_sim_time

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Add default parameter for scenario simulator

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* add param for psim v2 (#197)

* add param for psim v2

Signed-off-by: kosuke murakami <kosuke.murakami@tier4.jp>

* Update to pass var 'scenario_simulation' to dummy_perception_publisher

* Update dummy_perception_publisher's arg-name

Co-authored-by: yamacir-kit <httperror@404-notfound.jp>

* Add vehicle info launch for setting vehicle info param (#199)

* Add vehicle info launch for setting vehicle info param

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Add comment for global parameters section

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

* Fix year and apply format

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Remove ready vehicle info param

Signed-off-by: wep21 <border_goldenmarket@yahoo.co.jp>

Co-authored-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix CI build depends (#261)

* Fix CI build depends

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Remove xacro find package

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Move global_params.launch.py and vehicle_info.launch.py to autoware_global_parameter_loader (#282)

* Move global_params.launch.py and vehicle_info.launch.py to autoware_global_parameter_loader

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Add exec_depend

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* add description for vehicle_launch (#337)

* add description

* delete duplicate

* delete slash

* fix sentence

* add README.md and svg files (#328)

* add md and svg

* fix typo

* fix typo

* fix word

* fix typo

* add lack of things

* Update README

* fix depending packages

* fix word

* Fix pre-commit (#407)

* Fix pre-commit errors

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Fix package.xml

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Move simple_planning_simulator to simulator_launch (#462)

* move simple_planning_simulator

* add simulation arg to logging_simulator.launch

* delete unused argument

* add arguments for logging simulation

* change default value

* update README

* add default value to simulator arg

* restore vehicle_simulation arg

* Fix/revert initial engage state (#484)

* Fix args

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Add initial_engage_state to vehicle.launch.xml

Signed-off-by: Kenji Miyake <kenji.miyake@tier4.jp>

* Update vehicle.launch.xml

* Change formatter to black (#488)

* Update pre-commit settings

* Apply Black

* Replace ament_lint_common with autoware_lint_common

* Update build_depends.repos

* Fix build_depends

* add build depend

Signed-off-by: tomoya.kimura <tomoya.kimura@tier4.jp>

* ci(pre-commit): autofix

* remove depends

* update readme

Co-authored-by: mitsudome-r <ryohsuke.mitsudome@tier4.jp>
Co-authored-by: Yukihiro Saito <yukky.saito@gmail.com>
Co-authored-by: hiroyuki obinata <58019445+obi-t4@users.noreply.github.com>
Co-authored-by: Yamasaki Tatsuya <httperror@404-notfound.jp>
Co-authored-by: Takamasa Horibe <horibe.takamasa@gmail.com>
Co-authored-by: Jilada Eccleston <jilada.eccleston@tier4.jp>
Co-authored-by: Kenji Miyake <31987104+kenji-miyake@users.noreply.github.com>
Co-authored-by: wep21 <border_goldenmarket@yahoo.co.jp>
Co-authored-by: Ryohsuke Mitsudome <43976834+mitsudome-r@users.noreply.github.com>
Co-authored-by: taikitanaka3 <65527974+taikitanaka3@users.noreply.github.com>
Co-authored-by: taikitanaka <ttatcoder@outlook.jp>
Co-authored-by: Takagi, Isamu <43976882+isamu-takagi@users.noreply.github.com>
Co-authored-by: Daisuke Nishimatsu <42202095+wep21@users.noreply.github.com>
Co-authored-by: Kosuke Murakami <kosuke.murakami@tier4.jp>
Co-authored-by: Kenji Miyake <kenji.miyake@tier4.jp>
Co-authored-by: Hiroki OTA <hiroki.ota@tier4.jp>
Co-authored-by: Keisuke Shima <19993104+KeisukeShima@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Takeshi Miura <57553950+1222-takeshi@users.noreply.github.com>
  • Loading branch information
20 people authored Dec 14, 2021
1 parent 1f98799 commit 7b23bdf
Show file tree
Hide file tree
Showing 7 changed files with 166 additions and 0 deletions.
18 changes: 18 additions & 0 deletions launch/vehicle_launch/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
cmake_minimum_required(VERSION 3.5)
project(vehicle_launch)

add_compile_options(-std=c++14)

find_package(ament_cmake_auto REQUIRED)

ament_auto_find_build_dependencies()

if(BUILD_TESTING)
find_package(ament_lint_auto REQUIRED)
ament_lint_auto_find_test_dependencies()
endif()

ament_auto_package(INSTALL_TO_SHARE
launch
urdf
)
63 changes: 63 additions & 0 deletions launch/vehicle_launch/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
# vehicle_launch

## Structure

![vehicle_launch](./vehicle_launch.drawio.svg)

## Package Dependencies

Please see `<exec_depend>` in `package.xml`.

## Usage

You can include as follows in `*.launch.xml` to use `vehicle.launch.xml`.

```xml
<arg name="vehicle_model" default="lexus" description="vehicle model name"/>
<arg name="sensor_model" default="aip_xx1" description="sensor model name"/>

<include file="$(find-pkg-share vehicle_launch)/launch/vehicle.launch.xml">
<arg name="vehicle_model" value="$(var vehicle_model)"/>
<arg name="sensor_model" value="$(var sensor_model)"/>
</include>
```

## Notes

This package finds some external packages and settings with variables and package names.

ex.)

```xml
<let name="vehicle_model_pkg" value="$(find-pkg-share $(var vehicle_model)_description)"/>
```

<https://github.com/tier4/autoware_launcher/blob/d880474/vehicle_launch/launch/vehicle_description.launch.xml#L11>

```xml
<arg name="config_dir" default="$(find-pkg-share individual_params)/config/$(var vehicle_id)/$(var sensor_model)"/>
```

## vehicle.xacro

### Arguments

| Name | Type | Description | Default |
| ------------- | ------ | ------------------ | ------- |
| sensor_model | String | sensor model name | "" |
| vehicle_model | String | vehicle model name | "" |

### Usage

You can write as follows in `*.launch.xml`.

```xml
<arg name="vehicle_model" default="lexus" description="vehicle model name"/>
<arg name="sensor_model" default="aip_xx1" description="sensor model name"/>
<arg name="model" default="$(find-pkg-share vehicle_launch)/urdf/vehicle.xacro"/>

<node name="robot_state_publisher" pkg="robot_state_publisher" exec="robot_state_publisher">
<param name="robot_description" value="$(command 'xacro $(var model) vehicle_model:=$(var vehicle_model) sensor_model:=$(var sensor_model)')"/>
</node>

```
28 changes: 28 additions & 0 deletions launch/vehicle_launch/launch/vehicle.launch.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
<?xml version="1.0" encoding="UTF-8"?>
<launch>
<arg name="vehicle_model" description="vehicle model name"/>
<arg name="sensor_model" description="sensor model name"/>
<arg name="vehicle_id" default="$(env VEHICLE_ID default)" description="vehicle specific ID"/>
<arg name="simulation" default="false" description="use simulation"/>
<arg name="initial_engage_state" default="false" description="/vehicle/engage state after starting Autoware"/>

<let name="vehicle_model_pkg" value="$(find-pkg-share $(var vehicle_model)_description)"/>


<!-- vehicle description -->
<group>
<include file="$(find-pkg-share vehicle_launch)/launch/vehicle_description.launch.xml">
<arg name="vehicle_model" value="$(var vehicle_model)"/>
<arg name="sensor_model" value="$(var sensor_model)"/>
<arg name="vehicle_id" value="$(var vehicle_id)"/>
</include>
</group>

<!-- vehicle interface -->
<group unless="$(var simulation)">
<include file="$(var vehicle_model_pkg)/launch/vehicle_interface.launch.xml">
<arg name="vehicle_id" value="$(var vehicle_id)"/>
<arg name="initial_engage_state" value="$(var initial_engage_state)"/>
</include>
</group>
</launch>
15 changes: 15 additions & 0 deletions launch/vehicle_launch/launch/vehicle_description.launch.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?xml version="1.0" encoding="UTF-8"?>
<launch>
<arg name="vehicle_model" description="vehicle model name"/>
<arg name="sensor_model" description="sensor model name"/>
<arg name="vehicle_id" description="vehicle specific ID"/>


<!-- tf publisher -->
<arg name="model" default="$(find-pkg-share vehicle_launch)/urdf/vehicle.xacro" description="path to the file of model settings (*.xacro)"/>
<arg name="config_dir" default="$(find-pkg-share individual_params)/config/$(var vehicle_id)/$(var sensor_model)" description="path to the directory of calibration parameters"/>
<node name="robot_state_publisher" pkg="robot_state_publisher" exec="robot_state_publisher">
<param name="robot_description" value="$(command 'xacro $(var model) vehicle_model:=$(var vehicle_model) sensor_model:=$(var sensor_model) config_dir:=$(var config_dir)')"/>
</node>

</launch>
22 changes: 22 additions & 0 deletions launch/vehicle_launch/package.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
<?xml version="1.0"?>
<package format="2">
<name>vehicle_launch</name>
<version>0.1.0</version>
<description>The vehicle_launch package</description>

<maintainer email="yukihiro.saito@tier4.jp">Yukihiro Saito</maintainer>
<license>Apache License 2.0</license>


<buildtool_depend>ament_cmake_auto</buildtool_depend>

<exec_depend>robot_state_publisher</exec_depend>
<exec_depend>xacro</exec_depend>

<test_depend>ament_lint_auto</test_depend>
<test_depend>autoware_lint_common</test_depend>

<export>
<build_type>ament_cmake</build_type>
</export>
</package>
16 changes: 16 additions & 0 deletions launch/vehicle_launch/urdf/vehicle.xacro
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<?xml version="1.0"?>
<robot name="vehicle"
xmlns:xacro="http://ros.org/wiki/xacro">

<xacro:arg name="vehicle_model" default=""/>
<xacro:arg name="sensor_model" default=""/>

<!-- vehicle -->
<xacro:property name="vehicle_model_property" value="$(arg vehicle_model)"/>
<xacro:include filename="$(find ${vehicle_model_property}_description)/urdf/vehicle.xacro"/>

<!-- sensors -->
<xacro:property name="sensor_model_property" value="$(arg sensor_model)"/>
<xacro:include filename="$(find ${sensor_model_property}_description)/urdf/sensors.xacro"/>

</robot>
4 changes: 4 additions & 0 deletions launch/vehicle_launch/vehicle_launch.drawio.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 7b23bdf

Please sign in to comment.