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

Examples: Update ADC() #966

Merged
merged 1 commit into from
Oct 31, 2024
Merged

Examples: Update ADC() #966

merged 1 commit into from
Oct 31, 2024

Conversation

helgibbons
Copy link
Contributor

Should help with #965

@helgibbons
Copy link
Contributor Author

I've not done anything with our Analog class in modules_py/pimoroni.py here, which might also need looking at?

@Gadgetoid
Copy link
Member

Thank you!

I guess in Analog it should be something like:

self.pin = ADC(pin) if isinstance(pin, Pin) else ADC(Pin(pin))

Looks like it's never actually called with a Pin instance, but it should probably handle that just in case.

@Gadgetoid
Copy link
Member

Gadgetoid commented Oct 25, 2024

I think this has been rendered redundant by micropython/micropython@2b8de74

Edit: Or rather, will be, as you correctly point out in #959 - when MicroPython 1.24.x is released 🤔

@Gadgetoid Gadgetoid merged commit b8f4bd3 into main Oct 31, 2024
30 checks passed
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