-
Notifications
You must be signed in to change notification settings - Fork 373
Dev_PostBuildEvents
Since the com.siemens.ros-sharp
Unity package contains the complete ROS# .NET solution, we decided to write a post-build event script for both Windows (powershell) and Linux (bash) to automatically update the Unity package after each successful Visual Studio build. The script basically finds all the .cs files from the .NET solution directory, removes unnecessary Visual Studio related files that Unity doesn't like, and copies them to the Unity package. In this way, the ROS# core can be modified and tested in Unity at the same time without any additional automation overhead. If you are not modifying the core ROS# .NET scripts while testing/working with the Unity package, there is no need to worry.
To enable the scripts, the Visual Studio project's `Post-build event' must be modified as follows:
- For
RosBridgeClient
project only. Build order does not matter, butMessageGenerationConsoleTool
depends onMessageGeneration
,RosBridgeClientTest
depends onRosBridgeClient
andUrdfTest
depends onUrdf
. - Head to
Project
>Project Properties
>Build
>Events
>Post-build event
- Paste the following event:
cd .. cd .. if "$(OS)" == "Windows_NT" ( powershell.exe -ExecutionPolicy Bypass -File .\Libraries\PostBuildEvents\UpdateUPM_Win.ps1 ) else ( ./Libraries/PostBuildEvents/UpdateUPM_NonWin.sh )
Important: Script needs to be called from the ros-sharp repo root folder.
© Siemens AG, 2017-2024
-
- 1.3.1 R2D2 Setup
- 1.3.2 Gazebo Setup on VM
- 1.3.3 TurtleBot Setup (Optional for ROS2)
-
- 2.1 Quick Start
- 2.2 Transfer a URDF from ROS to Unity
- 2.3 Transfer a URDF from Unity to ROS
- 2.4 Unity Simulation Scene Example
- 2.5 Gazebo Simulation Scene Example
- 2.6 Fibonacci Action Client
- 2.7 Fibonacci Action Server
- 3.1 Import a URDF on Windows
- 3.2 Create, Modify and Export a URDF Model
- 3.3 Animate a Robot Model in Unity
- Message Handling: Readers & Writers
- Thread Safety for Message Reception
- File Server Package
- ROS-Unity Coordinate System Conversions
- Post Build Events
- Preprocessor Directives in ROS#
- Adding New Message Types
- RosBridgeClient Protocols
- RosBridgeClient Serializers
- Action Server State Machine Model
© Siemens AG, 2017-2024