Skip to content

Conversation

steve-weinrich
Copy link

  • There are no functionality or interface changes. Just C++ improvements.
  • Use a "pointer to member function" to divide "stepMotor" into discrete methods.
  • Remove unnecessary use of "this".
  • Add a common initialization method for use by all constructors.
  • Add appropriate use of "const".
  • Remove "direction" from class as it was only used in one method.
  • Add "numberOfPositions" so that the "step" method does not need to test the motor type.
  • Change the "motorPins" into an array to make common initialization easier.
  • Use camel case variable names instead of underscores.

@facchinm facchinm added the Library: Stepper The Stepper Arduino library label Jan 8, 2018
@facchinm facchinm changed the title Improvements to C++ code [STEPPER] Improvements to C++ code Jan 8, 2018
@facchinm
Copy link
Member

facchinm commented Jan 8, 2018

Hi @steve-weinrich ,
would you mind moving the PR to https://github.com/arduino-libraries/Stepper/pulls ? Thanks

@steve-weinrich
Copy link
Author

steve-weinrich commented Jan 9, 2018 via email

@facchinm
Copy link
Member

Feel free to create a brand new PR with all your commits included 😉

@steve-weinrich
Copy link
Author

Moving to arduino-libraries

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Library: Stepper The Stepper Arduino library
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants