diff --git a/README.md b/README.md index 9c5ed51..b2f1967 100644 --- a/README.md +++ b/README.md @@ -27,14 +27,17 @@ This ROS package and associated GUI make use of the 6-axis force/torque sensor o ## Usage ### Bringup the robot -1. _(Teach Pendant)_ Turn on the robot, get into _manual_ mode, then load the "EXTERNAL_CONTROL.urp" program. +1. _(Teach Pendant)_ Turn on the robot, and get into _manual_ mode. 2. _(Teach Pendant)_ Start the robot (tap the small red dot on the bottom left corner) ### Start Armstron 1. _(Host Computer)_ Choose "Armstron" from your application menu (Super + A). - This starts communication with the robot arm, starts the Armstron test server, and starts the Armstron GUI. -b. _(Teach Pendant)_ Run the "EXTERNAL_CONTROL.urp" program. -2. Use the GUI to load/build test profiles, set data save locations, and run tests. +2. Use the GUI to load/build test profiles, set data save locations. +3. Run tests + 1. _(Teach Pendant)_ Move the arm around manually to set things up. + 2. _(Teach Pendant)_ Once you are ready to test, run the "EXTERNAL_CONTROL.urp" program. (press "play" in the bottom bar) + 3. _(Host Computer)_ Run a test using the "Run Test" button. ## Advanced Usage @@ -45,11 +48,13 @@ Since everything is modular, you can run each part of the Armstron software stac 1. _(Teach Pendant)_ Turn on the robot, get into _manual_ mode, then load the "EXTERNAL_CONTROL.urp" program. 2. _(Teach Pendant)_ Start the robot (tap the small red dot on the bottom left corner) 3. _(Host Computer)_ (new terminal): `roslaunch ur_user_calibration bringup_armando.launch` -4. _(Teach Pendant)_ Run the "EXTERNAL_CONTROL.urp" program. ### Use the Armstron test server -1. Start the test server (new terminal): `roslaunch armstron bringup_testing.launch` -2. Start a test (new terminal): +1. _(Host Computer)_ Start the test server (new terminal): `roslaunch armstron bringup_testing.launch` +2. Setup the robot + 1. _(Teach Pendant)_ Move the arm around manually to set things up. + 2. _(Teach Pendant)_ Once you are ready to test, run the "EXTERNAL_CONTROL.urp" program. (press "play" in the bottom bar) +3. _(Host Computer)_ Start a test (new terminal): ```bash roslaunch armstron run_test.launch config:="ceti_pull_test.yaml" save:="~/armstron_data/testing_launch.csv" @@ -57,8 +62,8 @@ Since everything is modular, you can run each part of the Armstron software stac ``` ### Start the GUI -1. Start the test server (new terminal): `roslaunch armstron bringup_testing.launch` -2. Start the Armstron GUI (new terminal): `rosrun armstron gui.py` +1. _(Host Computer)_ Start the test server (new terminal): `roslaunch armstron bringup_testing.launch` +2. _(Host Computer)_ Start the Armstron GUI (new terminal): `rosrun armstron gui.py` ### Useful commands for debugging diff --git a/armstron/config/rqt_multiplot.xml b/armstron/config/rqt_multiplot.xml index 4ab250c..2248a58 100644 --- a/armstron/config/rqt_multiplot.xml +++ b/armstron/config/rqt_multiplot.xml @@ -11,13 +11,13 @@ - Untitled Axis - 0 + Time (s) + 1 true - Untitled Axis - 0 + EE Position (m) + 1 true @@ -187,13 +187,13 @@ - Untitled Axis - 0 + Time (s) + 1 true - Untitled Axis - 0 + EE Orientation (rad) + 1 true @@ -365,13 +365,13 @@ - Untitled Axis - 0 + Time (s) + 1 true - Untitled Axis - 0 + EE Force (N) + 1 true @@ -541,13 +541,13 @@ - Untitled Axis - 0 + Time (s) + 1 true - Untitled Axis - 0 + EE Torque (Nm) + 1 true diff --git a/armstron/config/test_profiles/simple_pull_test.yaml b/armstron/config/test_profiles/simple_pull_test.yaml new file mode 100644 index 0000000..b486133 --- /dev/null +++ b/armstron/config/test_profiles/simple_pull_test.yaml @@ -0,0 +1,13 @@ +params: + preload: + - {balance: pose} + - jog: + angular: [0.0, 0.0, 0.0] + linear: [0.0, 0.0, -0.003] + stop_conditions: {min_force_z: -60.0} + test: + - jog: + angular: [0.0, 0.0, 0.0] + linear: [0.0, 0.0, 0.001] + stop_conditions: {max_position_z: 0.02} +type: sequence diff --git a/armstron/src/armstron/gui/profile_editor.py b/armstron/src/armstron/gui/profile_editor.py index e0d47c7..8812747 100644 --- a/armstron/src/armstron/gui/profile_editor.py +++ b/armstron/src/armstron/gui/profile_editor.py @@ -441,17 +441,17 @@ def _make_add_button(self, parent, key): font=('Arial', 10, 'bold'), bd=2, fg = self.colors['default'][0]) - add_balance = tk.Button(fr_group, + add_balance = ttk.Button(fr_group, text="Balance", command = lambda key=key, : self._add_step(key, 'balance'), state = 'normal',) - add_pose = tk.Button(fr_group, + add_pose = ttk.Button(fr_group, text="Pose", command = lambda key=key, : self._add_step(key, 'pose'), state = 'normal') - add_jog = tk.Button(fr_group, + add_jog = ttk.Button(fr_group, text="Jog", command = lambda key=key, : self._add_step(key, 'jog'), state = 'normal') diff --git a/docs/examples/gui_test.rst b/docs/examples/gui_test.rst index 22cee73..52439c3 100644 --- a/docs/examples/gui_test.rst +++ b/docs/examples/gui_test.rst @@ -1,4 +1,4 @@ -.. _gui: +.. _gui_test: .. |up| unicode:: U+25B2 .. UP .. |dn| unicode:: U+25BC .. DOWN @@ -29,25 +29,42 @@ _______ 2. Start Armstron a. *(Host Computer)* Choose “Armstron” from your application menu (Super + A). - b. *(Teach Pendant)* Run the "EXTERNAL_CONTROL.urp" program. +Now the Armstron GUI and a live graph will open: + +.. image:: ../img/gui_start.png + +.. image:: ../img/gui_graph.png Build a Test Profile -___________________ +____________________ 1. Click the "Load" button and choose an existing profile -2. Use the |up| or |dn| buttons to move a step up or down +2. Use the |up| and |dn| buttons to move a step up or down 3. Use the |x| button to remove a step -4. Add a step to with the "add step" buttons. +4. Add a step with the "add step" buttons. +.. image:: ../img/gui_simple_test.png Run a Test __________ -1. Choose where to save data. -2. Run a test using the "Run Test" button. -3. Abort a test using the "STOP" button. *Note: Data is saved continuously during tests, so your data is safe even if a test gets aborted.* - +1. *(Teach Pendant)* Move the arm around manually to set things up. +2. *(Teach Pendant)* Once you are ready to test, run the "EXTERNAL_CONTROL.urp" program. (press "play" in the bottom bar) +3. *(Host Computer)* Choose where to save data with the "Set File" button. +4. *(Host Computer)* Run a test using the "Run Test" button. +5. *(Host Computer)* Abort a test using the "STOP" button. *Note: Data is saved continuously during tests, so your data is safe even if a test gets aborted.* .. note:: - Pictures of the GUI in action are coming soon! \ No newline at end of file + + Savefile names are auto-incremented to prevent overwriting of data, so you only need to set the filename once. + +.. important:: + + **Don't forget to run the "EXTERNAL_CONTROL.urp" program** before running tests! It's easy to forget, so let this note serve as a reminder. + + +Happy Testing! +______________ + +This is all you really need to know to use the Armstron. If you are interested in doing more-advanced things, keep reading in :ref:`Manual Testing ` section \ No newline at end of file diff --git a/docs/examples/manual_test.rst b/docs/examples/manual_test.rst index f0dc265..bb1a13a 100644 --- a/docs/examples/manual_test.rst +++ b/docs/examples/manual_test.rst @@ -1,4 +1,4 @@ -.. _first_test: +.. _manual_test: =================== Run a Test Manually @@ -106,24 +106,31 @@ Testing Procedure a. *(Teach Pendant)* Turn on the robot, get into _manual_ mode, then load the "EXTERNAL_CONTROL.urp" program. b. *(Host Computer)* In a new terminal: ``roslaunch ur_user_calibration bringup_armando.launch`` - c. *(Teach Pendant)* Run the "EXTERNAL_CONTROL.urp" program. 2. Start the Armstron test server (this waits for tests to be started, and handles balancing and estop commands) a. In a new terminal, start the test server: ``roslaunch armstron bringup_testing.launch`` -3. Start a test (for example, *ceti_pull_test.yaml*), and save data in the Documents folder (*~/Documents/vinst_data/test.csv*) - - a. In a new terminal, run: +3. Start a test (for example, *ceti_pull_test.yaml*), and save data in the Documents folder (*~/Documents/armstron_data/test.csv*) + + a. *(Teach Pendant)* Move the arm around manually to set things up. + b. *(Teach Pendant)* Once you are ready to test, run the "EXTERNAL_CONTROL.urp" program. (press "play" in the bottom bar) + c. *(Host Computer)* In a new terminal, run: .. code-block:: bash - roslaunch armstron run_test.launch config:="ceti_pull_test.yaml" save:="~/Documents/vinst_data/test.csv" + roslaunch armstron run_test.launch config:="ceti_pull_test.yaml" save:="~/Documents/armstron_data/test.csv" + .. note:: - If you want to run more tests, just keep repeating step 3. Savefile names are auto-incremented to prevent overwriting of data, so you can keep sending the same filename (and thus the same terminal command) over and over to keep repeating the same test procedure. + Savefile names are auto-incremented to prevent overwriting of data, so you can keep sending the same filename (and thus the same terminal command) over and over to keep repeating the same test procedure + +.. important:: + + **Don't forget to run the "EXTERNAL_CONTROL.urp" program** before running tests! It's easy to forget, so let this note serve as a reminder. + More Details diff --git a/docs/img/gui_graph.png b/docs/img/gui_graph.png new file mode 100644 index 0000000..3b77785 Binary files /dev/null and b/docs/img/gui_graph.png differ diff --git a/docs/img/gui_simple_test.png b/docs/img/gui_simple_test.png new file mode 100644 index 0000000..38a0bb8 Binary files /dev/null and b/docs/img/gui_simple_test.png differ diff --git a/docs/img/gui_start.png b/docs/img/gui_start.png new file mode 100644 index 0000000..3acc60c Binary files /dev/null and b/docs/img/gui_start.png differ