Skip to content

Commit 34271f2

Browse files
committed
Add documentation for script sender example
1 parent f112d72 commit 34271f2

File tree

3 files changed

+18
-9
lines changed

3 files changed

+18
-9
lines changed

doc/architecture/script_sender.rst

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -13,15 +13,7 @@ corresponding request when starting a program on the robot that contains the **E
1313
program node. In order to work properly, make sure that the IP address and script sender port are
1414
configured correctly on the robot.
1515

16-
The following example creates a ``ScriptSender`` listening on port ``12345`` and sends the script
17-
``textmsg("Hello, World!")`` when requested. A fully compilable example can be found in `script_sender.cpp <https://github.com/UniversalRobots/Universal_Robots_Client_Library/blob/master/examples/script_sender.cpp>`_
18-
19-
.. literalinclude:: ../../examples/script_sender.cpp
20-
:language: c++
21-
:caption: examples/script_sender.cpp
22-
:linenos:
23-
:lineno-match:
24-
:start-at: constexpr uint32_t PORT
16+
An example of how to use the ``ScriptSender`` class can be found in the :ref:`script_sender_example`.
2517

2618
.. note::
2719
PolyScope X users cannot use the URCap linked above. There is a development version of a URCapX

doc/examples.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,5 @@ may be running forever until manually stopped.
2121
examples/primary_pipeline
2222
examples/primary_pipeline_calibration
2323
examples/rtde_client
24+
examples/script_sender
2425
examples/ur_driver

doc/examples/script_sender.rst

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
:github_url: https://github.com/UniversalRobots/Universal_Robots_Client_Library/blob/master/doc/examples/script_sender.rst
2+
3+
.. _script_sender_example:
4+
5+
Script Sender example
6+
=====================
7+
8+
The following example creates a ``ScriptSender`` listening on port ``12345`` and sends the script
9+
``textmsg("Hello, World!")`` when requested. A fully compilable example can be found in `script_sender.cpp <https://github.com/UniversalRobots/Universal_Robots_Client_Library/blob/master/examples/script_sender.cpp>`_
10+
11+
.. literalinclude:: ../../examples/script_sender.cpp
12+
:language: c++
13+
:caption: examples/script_sender.cpp
14+
:linenos:
15+
:lineno-match:
16+
:start-at: constexpr uint32_t PORT

0 commit comments

Comments
 (0)