-
Notifications
You must be signed in to change notification settings - Fork 248
sunrise_project_setup
As you might know, to create and synchronize a Sunrise project onto the Sunrise Cabinet, you need to use Sunrise Workbench. That only officially works on Windows 7 😨, this part takes place in your favorite Windows 7 (virtual) machine and using Sunrise Workbench.
You will get Sunrise Workbench from KUKA with the installation media that come with the robot, you can get updated versions of it and the APIs asking KUKA.
We will not cover here how to install Sunrise Workbench and its modules, of which Servoing is required to install iiwa_stack
.
- Within Sunrise Workbench, create a Sunrise project or load an existing one from the controller (default IP: 172.31.1.147).
- Open the StationSetup.cat file
- Select the Software tab
- Enable the Servo Motion packages, this is how that page should look like (more or less) :
- Save and apply changes
Now you will need to add iiwa_stack
(more precisely the content of iiwa_ros_java
) to the Sunrise project.
You have two options:
-
The correct one, useful for developers, it will let you track your changes in
iiwa_stack
with git. -
The lazy one, good for users that do not plan to change anything within
iiwa_stack
.
From now on, for simplicity, we will use two pseudo shell variables:
IIWA_STACK_DIR: the path to the root of the iiwa_stack
project, you probably cloned it into this folder.
SUNRISE_PROJECT_DIR: the path to the root of your Sunrise project (somewhere in your file system under your Sunrise Workspace)
Remember, these are NOT real variables 😑, we use them just to shorten things, use the full path!
- Run the command prompt (cmd.exe) as an administrator (press the Windows key --> type cmd --> right click --> run as an administrator).
- type
cd $SUNRISE_PROJECT_DIR
- type
mklink /D ROSJavaLib $IIWA_STACK_DIR\iiwa_ros_java\ROSJavaLib
- type
cd src
- type
mklink /D de $IIWA_STACK_DIR\iiwa_ros_java\src\de
- Inside Sunrise Workbench select all the files inside ROSJavaLib, right click and choose Build Path -> Add to Build Path...
- Copy the content of
$IIWA_STACK_DIR\iiwa_ros_java\src
inside thesrc
folder of the *Sunrise project. - Copy the folder
$IIWA_STACK_DIR\iiwa_ros_java\ROSJavaLib
into the root of the Sunrise project. - Inside Sunrise Workbench select all the files inside ROSJavaLib, right click and choose Build Path -> Add to Build Path...
In your Sunrise Project, open the file src/RoboticsAPI.data.xml
and modify its content to
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<RoboticsAPIData version="3">
<world>
<gravitation x="0.0" y="0.0" z="9.81"/>
</world>
<processDataContainer>
<processData dataType="java.lang.String" defaultValue="iiwa" displayName="Robot Name" editableOnHmi="true" id="robot_name" value="iiwa"/>
<processData dataType="java.lang.String" defaultValue="172.31.1.150" displayName="ROS Master IP" editableOnHmi="true" id="master_ip" value="172.31.1.150"/>
<processData dataType="java.lang.String" defaultValue="11311" displayName="ROS Master Port" editableOnHmi="false" id="master_port" value="11311"/>
<processData dataType="java.lang.String" defaultValue="172.31.1.147" displayName="Robot IP" editableOnHmi="false" id="robot_ip" value="172.31.1.147" visibleOnHmi="false"/>
<processData dataType="java.lang.Boolean" defaultValue="false" displayName="Enable NTP" editableOnHmi="true" id="ntp" value="false"/>
<processData dataType="java.lang.Boolean" defaultValue="false" displayName="Enable Debug Output" editableOnHmi="true" id="debug" value="false"/>
</processDataContainer>
</RoboticsAPIData>
This enables you to dynamically reconfigure some parameters that are used in the Sunrise Application without having to resynchronize it to the Sunrise Cabinet. These options will be available on the Process Data window of the SmartPad.
If your RoboticsAPI.data.xml
file contains or will contain something else, adjust it accordingly to your needs maintaining the items above inside the processDataContainer
field.
Whatever option you choose you should now have a Sunrise project without any error.
You can now install it (Station Setup -> Installation) and then synchronize it.
Have you already set your Safety Configuration? If not, you should! HERE we show how we set up ours.
Mind that every time you change your Safety Configuration you need to reinstall the project.