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

i75/i75w: Auto-detect board and set up user button. #655

Merged
merged 8 commits into from
Mar 16, 2023

Conversation

ageeandakeyboard
Copy link
Contributor

Allows for the Interstate75 (non W) user button to be used with our new python module

@ZodiusInfuser
Copy link
Member

Thanks @ageeandakeyboard. This should really do some handling of Interstate75 vs Interstate75W. GPIO23 which is used for boot button in Interstate, is the WIFI_ON pin on Interstate W, so we should not be touching that.

@ZodiusInfuser
Copy link
Member

@ZodiusInfuser
Copy link
Member

Thanks. I suggested some edits. It could also do with the updates to the C++ definitions and readme too: https://github.com/pimoroni/pimoroni-pico/tree/main/libraries/interstate75 i.e. the addition of static const uint8_t BOOT = 23; to the header

@Gadgetoid
Copy link
Member

There must be a way to auto-detect that the code is running on a Pico W, rather than relying upon user testimony?

@ZodiusInfuser
Copy link
Member

Since we have Pico W and Non-W builds, we could be evil and swap out which version of interstate75 gets baked in.

@ageeandakeyboard
Copy link
Contributor Author

It makes sense but then we i'll need to have two differently named modules.

@Gadgetoid
Copy link
Member

I think the user-facing logic here can be replaced with "Pico W" in sys.implementation._machine, I might grab/rebase this with that change to keep it fresh.

@Gadgetoid
Copy link
Member

@ageeandakeyboard if you still have i75 and i75w boards to hand, could you see if this works please?

@Gadgetoid Gadgetoid changed the title Patch/i75 userbutton i75/i75w: Auto-detect board and set up user button. Feb 22, 2023
@ageeandakeyboard
Copy link
Contributor Author

@Gadgetoid This works great with i75 and i75w the self.interstate75w variable detects correctly and the wifi is running fine on the i75w.
Tested with:
buttons.py
clock.py

@helgibbons helgibbons merged commit d0e2425 into main Mar 16, 2023
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.

Interstate 75 - Interacting with BOOT button using interstate.py
4 participants