Skip to content

Commit 164ff53

Browse files
committed
Merge branch 'master' of github.com:petercorke/robotics-toolbox-python
2 parents a714b57 + d855a80 commit 164ff53

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

45 files changed

+11487
-7299
lines changed

.github/workflows/pythonpackage.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,8 @@ jobs:
6868
run: |
6969
python -m pip install --upgrade pip
7070
pip install .[docs]
71+
pip install git+https://github.com/petercorke/sphinx-autorun.git
72+
sudo apt-get install graphviz
7173
- name: Build docs
7274
run: |
7375
cd docs

docs/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
# You can set these variables from the command line, and also
55
# from the environment for the first two.
6-
SPHINXOPTS ?=
6+
SPHINXOPTS ?= -j 4
77
SPHINXBUILD ?= sphinx-build
88
SOURCEDIR = source
99
BUILDDIR = build

docs/source/arm.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ Manipulator arms
77

88
arm_dh
99
arm_ets
10-
arm_urdf
10+
arm_erobot
1111
arm_superclass
1212
arm_backend
1313
arm_trajectory

docs/source/arm_dh.rst

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,11 @@ Denavit-Hartenberg models
33

44
.. codeauthor:: Jesse Haviland
55

6+
This class is used to model robots defined in terms of standard or modified
7+
Denavit-Hartenberg notation.
68

9+
.. note:: These classes are similar to MATLAB Toolbox ``SerialLink`` and
10+
``Link`` classes.
711

812
DHRobot
913
-------
Lines changed: 24 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
1-
URDF Robot models
2-
=================
1+
ERobot models
2+
=============
33

44
.. codeauthor:: Jesse Haviland
55

66

77
ERobot
8-
-------
8+
------
99

1010
.. inheritance-diagram:: roboticstoolbox.ERobot
1111
:top-classes: roboticstoolbox.Robot
@@ -37,8 +37,27 @@ The ``ERobot`` is defined by a tree of ``ELink`` subclass objects.
3737

3838
.. _E Models:
3939

40-
Models
41-
------
40+
ERobot models
41+
-------------
42+
43+
Defined using ETS
44+
^^^^^^^^^^^^^^^^^
45+
46+
A number of models are defined in terms of elementary transform sequences.
47+
They can be listed by:
48+
49+
.. runblock:: pycon
50+
51+
>>> import roboticstoolbox as rtb
52+
>>> rtb.models.list(mtype="ETS")
53+
54+
.. automodule:: roboticstoolbox.models.ETS
55+
:members:
56+
:undoc-members:
57+
:show-inheritance:
58+
59+
Defined from URDF
60+
^^^^^^^^^^^^^^^^^
4261

4362
A number of models are defined in terms of Denavit-Hartenberg parameters, either
4463
standard or modified. They can be listed by:

docs/source/arm_ets.rst

Lines changed: 5 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,8 @@ This approach is general enough to be able to describe any serial-link robot
5959
manipulator. For a branched manipulator we can use ETS to describe the
6060
connections between every parent and child link pair.
6161

62+
The ETS inherits list-like properties and has methods like ``reverse`` and ``pop``.
63+
6264
**Reference:**
6365

6466
- `A simple and systematic approach to assigning Denavit-Hartenberg parameters <https://petercorke.com/robotics/a-simple-and-systematic-approach-to-assigning-denavit-hartenberg-parameters>`_.
@@ -68,25 +70,15 @@ ETS - 3D
6870
--------
6971

7072
.. autoclass:: roboticstoolbox.robot.ETS.ETS
71-
:members: rx, ry, rz, tx, ty, tz, eta, eval, T, joints, axis, jtype, config, __getitem__, __mul__, __repr__, __str__
73+
:members: rx, ry, rz, tx, ty, tz, eta, n, joints, isjoint, isconstant, isrevolute, isprismatic, axis, config, __getitem__, pop, __mul__, __repr__, __str__, T, eval, jacob0, hessian0
7274
:undoc-members:
7375
:show-inheritance:
7476

7577
ETS - 2D
7678
--------
7779

78-
.. autoclass:: roboticstoolbox.robot.ETS2.ETS
79-
:members: rx, ry, rz, tx, ty, tz, eta, eval, T, joints, axis, jtype, config, __getitem__, __mul__, __repr__, __str__
80+
.. autoclass:: roboticstoolbox.robot.ETS.ETS2
81+
:members: r, tx, ty, eta, n, joints, isjoint, isconstant, isrevolute, isprismatic, axis, config, __getitem__, pop, __mul__, __repr__, __str__, T, eval
8082
:undoc-members:
8183
:show-inheritance:
8284

83-
ETS Robot models
84-
----------------
85-
86-
A number of models are defined in terms of elementary transform sequences.
87-
They can be listed by:
88-
89-
.. runblock:: pycon
90-
91-
>>> import roboticstoolbox as rtb
92-
>>> rtb.models.list(mtype="ETS")

docs/source/conf.py

Lines changed: 37 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818

1919
# -- Project information -----------------------------------------------------
2020

21-
project = 'Robotics Toolbox Python'
21+
project = 'Robotics Toolbox for Python'
2222
copyright = '2020, Jesse Haviland and Peter Corke'
2323
author = 'Jesse Haviland and Peter Corke'
2424

@@ -42,58 +42,73 @@
4242
'sphinx.ext.inheritance_diagram',
4343
'sphinx_autorun',
4444
]
45-
#'recommonmark',
46-
#'sphinx.ext.autosummary',
47-
# 'sphinx_markdown_tables',
48-
4945

5046
autosummary_generate = True
5147
autodoc_member_order = 'bysource'
5248

5349
# Add any paths that contain templates here, relative to this directory.
5450
templates_path = ['_templates']
5551

56-
# List of patterns, relative to source directory, that match files and
57-
# directories to ignore when looking for source files.
58-
# This pattern also affects html_static_path and html_extra_path.
5952
exclude_patterns = ['test_*']
6053

54+
# options for spinx_autorun, used for inline examples
55+
# choose UTF-8 encoding to allow for Unicode characters, eg. ansitable
56+
# Python session setup, turn off color printing for SE3, set NumPy precision
57+
autorun_languages = {}
58+
autorun_languages['pycon_output_encoding'] = 'UTF-8'
59+
autorun_languages['pycon_input_encoding'] = 'UTF-8'
60+
autorun_languages['pycon_runfirst'] = """
61+
from spatialmath import SE3
62+
SE3._color = False
63+
import numpy as np
64+
np.set_printoptions(precision=4, suppress=True)
65+
from ansitable import ANSITable
66+
ANSITable._color = False
67+
"""
6168

6269
# -- Options for HTML output -------------------------------------------------
6370

64-
# The theme to use for HTML and HTML Help pages. See the documentation for
65-
# a list of builtin themes.
66-
#
6771
html_theme = 'sphinx_rtd_theme'
6872

6973
html_theme_options = {
70-
'github_user': 'petercorke',
74+
'github_user': 'petercorke',
7175
#'github_repo': 'spatialmath-python',
7276
#'logo_name': False,
7377
'logo_only': False,
7478
#'description': 'Spatial maths and geometry for Python',
7579
'display_version': True,
7680
'prev_next_buttons_location': 'both',
7781
'analytics_id': 'G-11Q6WJM565',
82+
'style_external_links': True,
7883
}
7984
html_logo = '../figs/RobToolBox_RoundLogoB.png'
8085
html_last_updated_fmt = '%d-%b-%Y'
8186
show_authors = True
8287

88+
# mathjax_config = {
89+
# "jax": ["input/TeX","output/HTML-CSS"],
90+
# "displayAlign": "left"
91+
# }
92+
8393
# Add any paths that contain custom static files (such as style sheets) here,
8494
# relative to this directory. They are copied after the builtin static files,
8595
# so a file named "default.css" will overwrite the builtin "default.css".
8696
# html_static_path = ['_static']
8797

8898
# autodoc_mock_imports = ["numpy", "scipy"]
8999

90-
# extensions = ['rst2pdf.pdfbuilder']
91-
# pdf_documents = [('index', u'rst2pdf', u'Sample rst2pdf doc', u'Your Name'),]
92-
autorun_languages = {}
93-
autorun_languages['pycon_output_encoding'] = 'UTF-8'
94-
autorun_languages['pycon_initial_code'] = [
95-
"from spatialmath import SE3",
96-
"SE3._color = False",
97-
"import numpy as np",
98-
"np.set_printoptions(precision=4, suppress=True)",
99-
]
100+
101+
# -- Options for LaTeX/PDF output --------------------------------------------
102+
latex_engine = 'xelatex'
103+
# maybe need to set graphics path in here somewhere
104+
# \graphicspath{{figures/}{../figures/}{C:/Users/me/Documents/project/figures/}}
105+
# https://stackoverflow.com/questions/63452024/how-to-include-image-files-in-sphinx-latex-pdf-files
106+
latex_elements = {
107+
# The paper size ('letterpaper' or 'a4paper').
108+
'papersize': 'a4paper',
109+
#'releasename':" ",
110+
# Sonny, Lenny, Glenn, Conny, Rejne, Bjarne and Bjornstrup
111+
# 'fncychap': '\\usepackage[Lenny]{fncychap}',
112+
'fncychap': '\\usepackage{fncychap}',
113+
'maketitle': "blah blah blah"
114+
}

0 commit comments

Comments
 (0)