Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

https://github.com/adafruit/Adafruit_CircuitPython_SimpleIO/issues/10 #30

Merged
merged 7 commits into from
May 18, 2018

Conversation

apatt
Copy link

@apatt apatt commented May 15, 2018

I was able to test that the parameter passing works as expected and that there are not python errors, but I don't know to confirm the underlying functions (switch_to_input and switch_to_output) functions work as expected.

Copy link
Member

@tannewt tannewt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

THanks for picking this up. A couple comments to simplify things.

simpleio.py Outdated
@@ -230,9 +230,14 @@ class DigitalOut:
"""
Simple digital output that is valid until soft reset.
"""
def __init__(self, pin):
def __init__(self, pin, value=None, drive_mode=None):
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Simpler to do def __init__(self, pin, **kwargs):

simpleio.py Outdated
def __init__(self, pin, value=None, drive_mode=None):
"""
value and drive_mode: if passed in will be passed to switch_to_output
see digitalio.DigitalInOut.switch_to_output for more details
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please copy the docs here. Directing elsewhere doesn't simplify the docs.

@apatt
Copy link
Author

apatt commented May 18, 2018

ok, fixed all of your comments. again, tested to make sure python doesn't fail.

tannewt added 2 commits May 18, 2018 11:57
Don't mention switch methods which are implementation details.
@tannewt
Copy link
Member

tannewt commented May 18, 2018

Thanks @apatt !

@tannewt tannewt merged commit c722041 into adafruit:master May 18, 2018
tannewt pushed a commit to adafruit/Adafruit_CircuitPython_Bundle that referenced this pull request Aug 10, 2018
Updating https://github.com/adafruit/Adafruit_CircuitPython_AVRprog to 1.1.0 from 1.0.2:
  > Merge pull request adafruit/Adafruit_CircuitPython_AVRprog#5 from kattni/pypi
  > updated CoC
  > Merge pull request adafruit/Adafruit_CircuitPython_AVRprog#4 from sommersoft/new_docs

Updating https://github.com/adafruit/Adafruit_CircuitPython_FancyLED to 1.2.0 from 1.1.1:
  > Merge pull request adafruit/Adafruit_CircuitPython_FancyLED#4 from kattni/pypi
  > updated CoC

Updating https://github.com/adafruit/Adafruit_CircuitPython_FeatherWing to 0.9.2 from 1.0.0:
  > Merge pull request adafruit/Adafruit_CircuitPython_FeatherWing#15 from kattni/api-doc-fix
  > Merge pull request adafruit/Adafruit_CircuitPython_FeatherWing#14 from kattni/busdevice-fix
  > Merge pull request adafruit/Adafruit_CircuitPython_FeatherWing#13 from adafruit/revert-8-pypi
  > Merge pull request adafruit/Adafruit_CircuitPython_FeatherWing#12 from adafruit/revert-9-pypi-fix
  > Merge pull request adafruit/Adafruit_CircuitPython_FeatherWing#11 from adafruit/revert-10-pypi-fix
  > Merge pull request adafruit/Adafruit_CircuitPython_FeatherWing#10 from kattni/pypi-fix
  > Merge pull request adafruit/Adafruit_CircuitPython_FeatherWing#9 from kattni/pypi-fix

Updating https://github.com/adafruit/Adafruit_CircuitPython_HID to 3.2.0 from 3.1.3:
  > Merge pull request adafruit/Adafruit_CircuitPython_HID#26 from kattni/pypi
  > updated CoC

Updating https://github.com/adafruit/Adafruit_CircuitPython_RTTTL to 2.2.0 from 2.1.2:
  > Merge pull request adafruit/Adafruit_CircuitPython_RTTTL#9 from kattni/pypi
  > updated CoC

Updating https://github.com/adafruit/Adafruit_CircuitPython_SimpleIO to 1.1.0 from 1.0.2:
  > Merge pull request adafruit/Adafruit_CircuitPython_SimpleIO#31 from kattni/pypi
  > updated CoC
  > Merge pull request adafruit/Adafruit_CircuitPython_SimpleIO#30 from apatt/master
  > Merge pull request adafruit/Adafruit_CircuitPython_SimpleIO#28 from sommersoft/new_docs

Updating https://github.com/adafruit/Adafruit_CircuitPython_Waveform to 1.2.0 from 1.1.0:
  > Merge pull request adafruit/Adafruit_CircuitPython_Waveform#4 from kattni/pypi
  > updated CoC
  > Merge pull request adafruit/Adafruit_CircuitPython_Waveform#3 from sommersoft/new_docs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants