diff --git a/html/.buildinfo b/html/.buildinfo index 834133b..444e9d7 100644 --- a/html/.buildinfo +++ b/html/.buildinfo @@ -1,4 +1,4 @@ # Sphinx build info version 1 # This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done. -config: 5fb11da93cdb0f49bc97733fbb9cadaf +config: 485364fc47e6585839eb0832cd879672 tags: 645f666f9bcd5a90fca523b33c5a78b7 diff --git a/html/_sources/index.rst.txt b/html/_sources/index.rst.txt index c207a90..2c0ae75 100644 --- a/html/_sources/index.rst.txt +++ b/html/_sources/index.rst.txt @@ -1,25 +1,21 @@ -Welcome to CompLib's documentation! -=================================== +Robo4you Competition Library +############################# .. toctree:: :maxdepth: 2 :caption: Contents: -Indices and tables -================== - -* :ref:`genindex` -* :ref:`modindex` -* :ref:`search` +CompLib is the library used in the robo4you competition 2021. -Table of Contents -^^^^^^^^^^^^^^^^^ +Contents +********* .. toctree:: :maxdepth: 5 :glob: self + other/usage lib/* diff --git a/html/_sources/lib/Api.rst.txt b/html/_sources/lib/Api.rst.txt new file mode 100644 index 0000000..44b2a43 --- /dev/null +++ b/html/_sources/lib/Api.rst.txt @@ -0,0 +1,67 @@ +.. _lib_api: + +Api +===== + +Seeding +******** + +.. autoclass:: compLib.Api.Seeding + :members: + +Double Elimination +******************* + +.. autoclass:: compLib.Api.DoubleElim + :members: + +Position +********* + +.. autoclass:: compLib.Api.Position + :members: + + +Examples +********* + +Calling Seeding API +--------------------- + +.. code-block:: python + + from compLib.Api import Seeding + + park = Seeding.get_park() + print(f"I should move to parking position: {park}") + + if park == 0: + print(f"I can't move to this position yet :(") + elif park == 1: + print(f"Moving to position 1!") + # drive to parking position using Motors module... + print(f"Now hopefully at position 1") + # drive back using Motors module... + elif park == 2: + # do something similar to park == 1.. + elif park == 3: + # do something similar to park == 1.. + + success = Seeding.pay_park() + if success: + print(f"We scored some points!") + else: + print(f"We failed :(") + +Calling Double Elimination API +---------------------------------- + +.. code-block:: python + + from compLib.Api import DoubleElim + + position = DoubleElim.get_position() + print(f"Position of my robot is: x={position.x}, y={position.y} and rotation is: {position.degrees}") + + goal = DoubleElim.get_goal() + print(f"Goal is at: x={goal.x}, y={goal.y}") diff --git a/html/_sources/other/usage.rst.txt b/html/_sources/other/usage.rst.txt new file mode 100644 index 0000000..93b2425 --- /dev/null +++ b/html/_sources/other/usage.rst.txt @@ -0,0 +1,28 @@ +.. _other_usage: + +Usage +###### + +.. code-block:: python + + import time + from compLib.Motor import * + + def forward(): + for port in range(0, 3): + Motor.power(port, 30); + + def backward(): + for port in range(0, 3): + Motor.power(port, -30); + + def main(): + print("hallo ich bin ein roboter beep buup") + + forward() + time.sleep(1) + backward() + time.sleep(1) + + if __name__ == '__main__': + main() \ No newline at end of file diff --git a/html/_static/documentation_options.js b/html/_static/documentation_options.js index 23fc755..dbef29e 100644 --- a/html/_static/documentation_options.js +++ b/html/_static/documentation_options.js @@ -1,6 +1,6 @@ var DOCUMENTATION_OPTIONS = { URL_ROOT: document.getElementById("documentation_options").getAttribute('data-url_root'), - VERSION: '0.0.1', + VERSION: '0.0.2', LANGUAGE: 'None', COLLAPSE_INDEX: false, BUILDER: 'html', diff --git a/html/genindex.html b/html/genindex.html index f105020..a8c84dc 100644 --- a/html/genindex.html +++ b/html/genindex.html @@ -7,7 +7,7 @@ - Index — CompLib 0.0.1 documentation + Index — CompLib 0.0.2 documentation @@ -83,7 +83,9 @@ +

D

+ + +
+ +

G

+ + + +
+

I

    @@ -212,10 +242,14 @@

    P

    @@ -224,6 +258,8 @@

    S

    diff --git a/html/index.html b/html/index.html index 73c9f96..c787d9d 100644 --- a/html/index.html +++ b/html/index.html @@ -7,7 +7,7 @@ - Welcome to CompLib’s documentation! — CompLib 0.0.1 documentation + Robo4you Competition Library — CompLib 0.0.2 documentation @@ -38,7 +38,7 @@ - + @@ -84,7 +84,9 @@
      -
    • Welcome to CompLib’s documentation!
    • +
    • Robo4you Competition Library
    • +
    • Usage
    • +
    • Api
    • Battery
    • Buzzer
    • Infrared Sensor
    • @@ -138,7 +140,7 @@
    • »
    • -
    • Welcome to CompLib’s documentation!
    • +
    • Robo4you Competition Library
    • @@ -157,23 +159,28 @@
      -
      -

      Welcome to CompLib’s documentation!

      +
      +

      Robo4you Competition Library

      -
      -
      -

      Indices and tables

      - -
      -

      Table of Contents

      +

      CompLib is the library used in the robo4you competition 2021.

      +
      +

      Contents