-
Notifications
You must be signed in to change notification settings - Fork 13.6k
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
Refactor the teraranger driver: uniform initialization, format whitespace, deprecate usage of the ringbuffer, etc. #11892
Conversation
ec40787
to
c9d44cd
Compare
@msadowski , would you be willing to review this PR for me? I am working to align the distance sensor drivers so that an inheritance hierarchy can be created. Thanks for any feedback you might have! |
c9d44cd
to
f2c1fd1
Compare
@mcsauder great effort on reducing code duplication! I had a read through and the changes make sense to me. Unfortunately I don't have access to TeraRanger sensors anymore but I'll forward this issue to some people from Terabee so that they can verify the changes work as expected with the sensors. |
Thank you @msadowski ! |
4eacf9b
to
9f41bbd
Compare
9f41bbd
to
97ad131
Compare
97ad131
to
eda6e1a
Compare
eda6e1a
to
ea52109
Compare
ea52109
to
2a22b5e
Compare
bc6b050
to
47405a2
Compare
f70e65d
to
89f45cf
Compare
859e379
to
aa3a609
Compare
0f00b62
to
212d6da
Compare
41e0445
to
30587af
Compare
Hi @julianoes , I've rebased this PR against current master and reverted the changes to the driver usage() method as we discussed in the dev call. Please let me know if you would like to see any other changes made to this PR! Thanks! Console output was tested:
|
PRINT_MODULE_USAGE_COMMAND_DESCR("info","Print driver information"); | ||
|
||
|
||
PRINT_MODULE_USAGE_COMMAND_DESCR("status","Print driver information"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great!
30587af
to
c211d9b
Compare
Rebased against current master. |
b47a07d
to
c550ca4
Compare
e2bb2ca
to
75abd3a
Compare
75abd3a
to
e0c347c
Compare
Rebased on current master to kick the stalled CI tools again. |
e0c347c
to
5e0ee58
Compare
Thanks @msadowski ! Fixed, rebased, and pushed up! |
Describe problem solved by the proposed pull request
This PR refactors the teraranger distance sensor driver. Usage of the ringbuffer is deprecated. Uniform initialization is employed along with formatting/alphabetizing/organizing, and standardizing the driver against other current distance sensor driver implementations.
Describe your preferred solution
Standardizing all of the distance sensor driver variable initialization, method ordering and general style will allow for future inheritance structure work to be performed on the distance sensor driver classes.
Describe possible alternatives
All of the distance sensor driver work could be accomplished in one massive PR, but breaking up work in each driver should minimize risk and reduce review effort.
Additional context
See #9279, #11853, #11857, #1858, #11859, #11891
Please let me know if you have any questions on this PR. Thanks!
-Mark