-
Notifications
You must be signed in to change notification settings - Fork 58
Move consts related to user settings to class level. #21
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
Comments
Module level is how I've seen it done in other places. The more proper way is to do it as a Python enum which is essentially an empty class with statics. So it'd be |
Thanks. That make more sense. I'll try and implement something and PR it. |
Just tossing in my support/agreeance @caternuson. These could definitely be more useful at the class level, especially so that the user doesn't have to remember which integer matches a mode. |
Yah, I totally did a sloppy job on this. I hit this myself when I was trying to help someone change mode and realized they didn't have anything convenient to use on the right hand side. They need to be able to do |
Done. See #25 |
Did you want to do the release? |
Or I can... :) |
Thanks! |
The register addresses are OK at the module level. But for things like mode (maybe that's the only one?) there is no convenient way to access them when using the recommended code setup:
Having these at the class level would allow:
May also want to change their names? Or just add new ones? So could:
The text was updated successfully, but these errors were encountered: