CircuitPython/digitalio.py

Wed, 28 Aug 2019 19:53:19 +0200

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Wed, 28 Aug 2019 19:53:19 +0200
changeset 6
81a2208f13e4
child 7
e336d6afc5a6
permissions
-rw-r--r--

Started with the stubs for CircuitPython.

# -*- 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

eric ide

mercurial