]> Repositories - Adafruit_Blinka-hackapet.git/commitdiff
Get docs building
authorScott Shawcroft <scott@tannewt.org>
Wed, 27 Jun 2018 17:53:00 +0000 (10:53 -0700)
committerScott Shawcroft <scott@tannewt.org>
Wed, 27 Jun 2018 17:53:00 +0000 (10:53 -0700)
.gitignore
docs/api.rst [changed mode: 0644->0755]
docs/conf.py [changed mode: 0644->0755]
docs/examples.rst [changed mode: 0644->0755]
docs/index.rst [changed mode: 0644->0755]
src/adafruit_blinka/__init__.py
src/bitbangio.py [changed mode: 0644->0755]
src/board.py [changed mode: 0644->0755]
src/busio.py [changed mode: 0644->0755]
src/digitalio.py [changed mode: 0644->0755]

index cc5b9ac44a2918a5cf50f88461be14fdb8f7f428..25364dafa944926fd8ff1029239ba49ec134ab0c 100644 (file)
@@ -6,3 +6,4 @@ _build
 .env
 build*
 bundles
+*.DS_Store
old mode 100644 (file)
new mode 100755 (executable)
index ab40507..66bca16
@@ -6,3 +6,21 @@
 
 .. automodule:: adafruit_blinka
    :members:
+
+.. automodule:: adafruit_blinka.agnostic
+  :members:
+
+.. automodule:: adafruit_blinka.microcontroller
+  :members:
+
+.. automodule:: bitbangio
+  :members:
+
+.. automodule:: board
+  :members:
+
+.. automodule:: busio
+  :members:
+
+.. automodule:: digitalio
+  :members:
old mode 100644 (file)
new mode 100755 (executable)
index 5976c17..4e0f359
@@ -2,7 +2,7 @@
 
 import os
 import sys
-sys.path.insert(0, os.path.abspath('..'))
+sys.path.insert(0, os.path.abspath('../src'))
 
 # -- General configuration ------------------------------------------------
 
@@ -18,9 +18,10 @@ extensions = [
 # Uncomment the below if you use native CircuitPython modules such as
 # digitalio, micropython and busio. List the modules you use. Without it, the
 # autodoc module docs will fail to generate with a warning.
-# autodoc_mock_imports = ["digitalio", "busio"]
+autodoc_mock_imports = ["machine"]
 
-intersphinx_mapping = {'python': ('https://docs.python.org/3.4', None),'CircuitPython': ('https://circuitpython.readthedocs.io/en/latest/', None)}
+intersphinx_mapping = {'python': ('https://docs.python.org/3.4', None),
+                       'CircuitPython': ('https://circuitpython.readthedocs.io/en/latest/', None)}
 
 # Add any paths that contain templates here, relative to this directory.
 templates_path = ['_templates']
old mode 100644 (file)
new mode 100755 (executable)
index 83f5ffe..c174f0c
@@ -1,8 +1,5 @@
-Simple test
-------------
+examples
+--------
 
-Ensure your device works with this simple test.
-
-.. literalinclude:: ../examples/blinka_simpletest.py
-    :caption: examples/blinka_simpletest.py
-    :linenos:
+No examples are currently available. See the `CircuitPython docs
+<https://circuitpython.readthedocs.io/>`_ for extensive API documentation.
old mode 100644 (file)
new mode 100755 (executable)
index 8d71e1b..07e52d5
@@ -20,18 +20,6 @@ Table of Contents
 
     api
 
-.. toctree::
-    :caption: Tutorials
-
-.. todo:: Add any Learn guide links here. If there are none, then simply delete this todo and leave
-    the toctree above for use later.
-
-.. toctree::
-    :caption: Related Products
-
-.. todo:: Add any product links here. If there are none, then simply delete this todo and leave
-    the toctree above for use later.
-
 .. toctree::
     :caption: Other Links
 
index 8c83305655eae82d331535544741115961743efa..845c802cb26731a0358ed474c60c2e4c5432f19c 100755 (executable)
@@ -1,5 +1,9 @@
-"""Module providing runtime utility objects to support the Micro/CircuitPython api"""
+"""
+`adafruit_blinka` - Runtime utility objects for re-implementation of CircuitPython API
+======================================================================================
 
+* Author(s): cefn
+"""
 
 class Enum(object):
     """
old mode 100644 (file)
new mode 100755 (executable)
index 101bfff..aa679f0
@@ -1,3 +1,12 @@
+"""
+`bitbangio` - Bitbanged bus protocols
+==============================================================
+
+See `CircuitPython:bitbangio` in CircuitPython for more details.
+
+* Author(s): cefn
+"""
+
 from adafruit_blinka import Lockable, agnostic
 
 
old mode 100644 (file)
new mode 100755 (executable)
index 536bc6b..d1c04c4
 """
 `board` - Define ids for available pins
 =================================================
-Conditionally imports and re-exports a submodule, such as boards.esp8266 based on 
-platform introspection
+
+See `CircuitPython:board` in CircuitPython for more details.
 
 * Author(s): cefn
 """
+import sys
 
-import gc
-gc.collect()
 from adafruit_blinka.agnostic import board
-gc.collect()
 
 if board == "feather_huzzah":
     from adafruit_blinka.board.feather_huzzah import *
@@ -39,6 +37,7 @@ elif board == "nodemcu":
     from adafruit_blinka.board.nodemcu import *
 elif board == "pyboard":
     from adafruit_blinka.board.pyboard import *
+elif "sphinx" in sys.modules:
+    pass
 else:
     raise NotImplementedError("Board not supported")
-gc.collect()
old mode 100644 (file)
new mode 100755 (executable)
index 0c6e296..6c5e76f
@@ -1,3 +1,12 @@
+"""
+`busio` - Bus protocol support like I2C and SPI
+=================================================
+
+See `CircuitPython:busio` in CircuitPython for more details.
+
+* Author(s): cefn
+"""
+
 from adafruit_blinka import Enum, Lockable, agnostic
 
 class I2C(Lockable):
old mode 100644 (file)
new mode 100755 (executable)
index 45cada2..8fb5385
@@ -1,8 +1,16 @@
+"""
+`digitalio` - Digital input and output control
+=================================================
+
+See `CircuitPython:digitalio` in CircuitPython for more details.
+
+* Author(s): cefn
+"""
+
 from machine import Pin
 from adafruit_blinka.agnostic import board as boardId
 from adafruit_blinka import Enum, ContextManaged
 
-
 class DriveMode(Enum):
     PUSH_PULL = None
     OPEN_DRAIN = None