forked from RMDLO/abb_dual_arm
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtouch-test-routine.sh
executable file
·65 lines (48 loc) · 2.14 KB
/
touch-test-routine.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
#!/bin/bash
echo "Starting Touch Test Routine..."
# Source ROS environment
source ~/cws/abb_dual_arm/devel/setup.bash
echo "Launching abb_control..."
# Launch ROS nodes in separate Terminator windows
terminator -e "bash -c 'source ~/cws/abb_dual_arm/devel/setup.bash;
roslaunch abb_control abb_control.launch sim:=False pointer:=True;
exec bash'" &
# Wait for nodes to initialize
sleep 10
echo "Starting realsense..."
terminator -e "bash -c 'source ~/cws/abb_dual_arm/devel/setup.bash;
roslaunch realsense2_camera rs_camera.launch;
exec bash'" &
# Wait for nodes to initialize
sleep 10
echo "Begin calibration data collection..."
# Activate Python environment and run calibration in a new Terminator window
terminator -e "bash -c 'source ~/cws/abb_dual_arm/devel/setup.bash;
source numpyenvros/bin/activate;
rosrun axbycz_data calibrate.py;
deactivate;
exec bash'" &
# Wait for data collection to complete
echo "Press any key once image capture is complete..."
read -n 1 -s
# Compile/run identifyCorner in a new Terminator window
terminator -e "bash -c 'source ~/cws/abb_dual_arm/devel/setup.bash;
g++ ~/cws/abb_dual_arm/src/abb_dual_arm/abb_irb120_support/src/identifyCorner.cpp -o identifyCorner \`pkg-config --cflags --libs opencv4\`;
./identifyCorner;
exec bash'" &
# Wait for corner identification to complete
echo "Press any key once corner identification is complete..."
read -n 1 -s
# Launch the frames in a new Terminator window
terminator -e "bash -c 'source ~/cws/abb_dual_arm/devel/setup.bash;
source numpyenvros/bin/activate;
roslaunch abb_irb120_support camera_tf.launch;
exec bash'" &
# Wait for frame to come up
echo "Frames are being launched..."
# Wait for nodes to initialize
sleep 10
# Launch final move group in a new Terminator window
terminator -e "bash -c 'source ~/cws/abb_dual_arm/devel/setup.bash;
roslaunch abb_irb120_support abb_irb120_cartesian_planning.launch;
exec bash'" &