Skip to content

Added example library #9

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

Merged
merged 8 commits into from
Dec 10, 2018
Merged

Added example library #9

merged 8 commits into from
Dec 10, 2018

Conversation

zlite
Copy link

@zlite zlite commented Dec 9, 2018

Similar to Robot.py in previous Python Adafruit Motor Hat Library.

Also added a robot.steer function. Use form: robot.steer(speed, direction) where both speed and direction are +/- 0-1

@ladyada
Copy link
Member

ladyada commented Dec 9, 2018

thanks! looks like there's a few pylint issues -
https://travis-ci.com/adafruit/Adafruit_CircuitPython_MotorKit/builds/94101676
we're strict about PRs passing pylint, since it often finds bugs, if you're not sure how to fix these we can help!

************* Module Robot
C: 75, 0: Line too long (109/100) (line-too-long)
R: 19, 4: Too many arguments (7/5) (too-many-arguments)
W: 19,23: Unused argument 'addr' (unused-argument)
W: 19,34: Unused argument 'left_id' (unused-argument)
W: 19,45: Unused argument 'right_id' (unused-argument)
R: 56, 4: Method could be a function (no-self-use)

Chris Anderson added 2 commits December 9, 2018 17:05
@zlite
Copy link
Author

zlite commented Dec 10, 2018

Not sure why the build is failing. It's been tested and works in the real world. All previous Travis complaints (all cosmetic) have been addressed

@ladyada
Copy link
Member

ladyada commented Dec 10, 2018

ahhh the linter is picky - @kattni can take a look tomorrow, looks like the two warnings are minor!

@ladyada ladyada requested a review from kattni December 10, 2018 01:27
@dhalbert
Copy link
Contributor

@zlite
Copy link
Author

zlite commented Dec 10, 2018

Yeah, those linter complaints are silly:

C: 71, 0: Line too long (107/100) (line-too-long)
R: 52, 4: Method could be a function (no-self-use)

@dhalbert
Copy link
Contributor

You can just make line 52 be a @staticmethod.

@zlite
Copy link
Author

zlite commented Dec 10, 2018

I guess I could, but it's perfectly fine as it is, too. I think our linter friend is wrong in both these cases ;-)

I'm going to leave it here. If you like it, pull it! If not, no hard feelings

@ladyada
Copy link
Member

ladyada commented Dec 10, 2018

no biggie - thanks for the PR
@kattni tomorrow please merge 'n fix the 2 lints

@kattni kattni merged commit 26fab61 into adafruit:master Dec 10, 2018
@ladyada
Copy link
Member

ladyada commented Dec 10, 2018

thanks @kattni !!

adafruit-adabot added a commit to adafruit/Adafruit_CircuitPython_Bundle that referenced this pull request Dec 11, 2018
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.

4 participants