api: rename _common to builtins

Because this module describes devices that can be built into a hub or other device.

Since this design is now explicitly shown in
the docs as well, we don't need to hide this
module in the package.
This commit is contained in:
Laurens Valk
2019-10-18 16:05:23 +02:00
parent f5762447b4
commit 529f8fe31c
9 changed files with 9 additions and 9 deletions
+1 -1
View File
@@ -6,7 +6,7 @@ verify_ssl = true
[dev-packages]
sphinx = "*"
flake8 = "*"
sphinx-rtd-theme = "~=0.4.0"
sphinx-rtd-theme = "==0.4.2"
doc8 = "*"
[packages]
+1 -1
View File
@@ -1,6 +1,6 @@
"""Sphinx workaround to document instance attributes such as self.light"""
from ._common import Speaker, Display, Battery, ColorLight, KeyPad, LightArray
from .builtins import Speaker, Display, Battery, ColorLight, KeyPad, LightArray
from types import ModuleType
+1 -1
View File
@@ -1,6 +1,6 @@
"""LEGO® Power Functions 2.0 City Hub."""
from ._common import Battery, ColorLight
from .builtins import Battery, ColorLight
battery = Battery()
light = ColorLight()
+1 -1
View File
@@ -1,6 +1,6 @@
"""LEGO® MINDSTORMS® EV3 Brick."""
from ._common import Speaker, Display, Battery, ColorLight, KeyPad
from .builtins import Speaker, Display, Battery, ColorLight, KeyPad
sound = Speaker()
display = Display()
+1 -1
View File
@@ -1,7 +1,7 @@
"""LEGO® MINDSTORMS® EV3 motors and sensors."""
from .parameters import Direction
from ._common import Motor as CommonMotor
from .builtins import Motor as CommonMotor
class Motor(CommonMotor):
+1 -1
View File
@@ -1,6 +1,6 @@
"""LEGO® Programmable Hubs."""
from enum import Enum
from ._common import Speaker, Display, Battery, ColorLight, KeyPad
from .builtins import Speaker, Display, Battery, ColorLight, KeyPad
class EV3Brick():
"""LEGO® MINDSTORMS® EV3 Brick.
+2 -2
View File
@@ -1,8 +1,8 @@
"""LEGO® Power Functions 2.0 motor, sensors, and lights."""
from ._common import Motor as CommonMotor, ColorLight
from .builtins import Motor as CommonMotor, ColorLight
from ._common import KeyPad, Accelerometer
from .builtins import KeyPad, Accelerometer
# The above abviously needs fixing (but not until after fixing merge conflict)
+1 -1
View File
@@ -1,6 +1,6 @@
"""LEGO® Power Functions 2.0 Move Hub."""
from ._common import Battery, ColorLight
from .builtins import Battery, ColorLight
battery = Battery()
light = ColorLight()