Skip to content

Commit

Permalink
Enhances sphinx documentation
Browse files Browse the repository at this point in the history
Enhances documentation on source code
Enhances load serial message action
  • Loading branch information
Carlos Mão de Ferro committed Jan 19, 2017
1 parent 2e3cb1a commit 5488016
Show file tree
Hide file tree
Showing 16 changed files with 568 additions and 371 deletions.
10 changes: 6 additions & 4 deletions docs/source/api_reference/com/arcom.rst
Original file line number Diff line number Diff line change
@@ -1,17 +1,19 @@
*****************************
=============================
Arduino Communication Wrapper
*****************************
=============================

.. contents:: Contents
:local:

--------
Overview
========
--------

TODO

--------------
Implementation
==============
--------------


.. automodule:: pybpodapi.com.arcom
Expand Down
19 changes: 0 additions & 19 deletions docs/source/api_reference/com/com.rst

This file was deleted.

23 changes: 23 additions & 0 deletions docs/source/api_reference/com/hw_info_container.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
=======================
Hardware Info Container
=======================

.. contents:: Contents
:local:

--------
Overview
--------

This container is used to store hardware description received from Bpod device.
After, this info will be used to fill the :class:`pybpodapi.hardware.hardwarw.Hardware` object.
The reason to use this container is because :class:`pybpodapi.hardware.hardwarw.Hardware` does some initializations that depend on information collected from several protocol commands.

--------------
Implementation
--------------


.. automodule:: pybpodapi.com.hardware_info_container
:members:
:private-members:
10 changes: 6 additions & 4 deletions docs/source/api_reference/com/index.rst
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
Communication
=============
**********************
Communication Protocol
**********************

Contents:

.. toctree::
:maxdepth: 2

com
protocol
arcom
message_headers
arcom
hw_info_container
23 changes: 23 additions & 0 deletions docs/source/api_reference/com/message_headers.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
========================
Protocol Message Headers
========================

.. contents:: Contents
:local:

--------
Overview
--------

The protocol to talk with Bpod device is defined by the Arduino firmware version installed.

Each message sent or received from Bpod contains a header which is the first byte (character). This header defines the type of action that should be executed.

--------------
Implementation
--------------


.. automodule:: pybpodapi.com.message_headers
:members:
:private-members:
17 changes: 9 additions & 8 deletions docs/source/api_reference/com/protocol.rst
Original file line number Diff line number Diff line change
@@ -1,19 +1,20 @@
**********************
Communication Protocol
**********************
=================
Protocol Commands
=================

.. contents:: Contents
:local:

--------
Overview
========
--------

TODO
This module defines protocol commands that are available to interact with the Bpod device.

--------------
Implementation
==============
--------------


.. automodule:: pybpodapi.com.bpod_protocol
.. automodule:: pybpodapi.com.protocol
:members:
:private-members:
3 changes: 2 additions & 1 deletion docs/source/api_reference/index.rst
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
###############
Model Reference
===============
###############

Contents:

Expand Down
5 changes: 4 additions & 1 deletion docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,9 @@
'sphinx.ext.todo',
'sphinx.ext.viewcode']

# Do not sort autodoc alphabetically, use source code appearance order
autodoc_member_order= 'bysource'

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

Expand Down Expand Up @@ -192,4 +195,4 @@


# Example configuration for intersphinx: refer to the Python standard library.
intersphinx_mapping = {'https://docs.python.org/': None}
intersphinx_mapping = {'https://docs.python.org/3/': None}

0 comments on commit 5488016

Please sign in to comment.