--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/CircuitPython/digitalio.py Wed Aug 28 19:53:19 2019 +0200 @@ -0,0 +1,45 @@ +# -*- coding: utf-8 -*- + +# Copyright (c) 2019 Detlev Offenbach <detlev@die-offenbachs.de> +# + +""" +Module containing stubs for API generation of the 'digitalio' module. +""" + +class DriveMode(): + PUSH_PULL = 0 + OPEN_DRAIN = 0 + +class DigitalInOut(): + def __init__(self, pin): + pass + + def deinit(self): + pass + + def switch_to_output(self, value=False, drive_mode=DriveMode.PUSH_PULL): + pass + + def switch_to_input(self, pull=None): + pass + + @property + def direction(self): + pass + + @property + def value(self): + pass + + @property + def drive_mode(self): + pass + + @property + def pull(self): + pass + +class Pull(): + UP = 0 + DOWN = 0