-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Add WIZnet W5500-EVB-Pico2 board #10179
Conversation
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.
Tested on a W5100S-EVB-Pico2 (the WIZnet library handles the difference in the chips). Looks good operationally.
Looks like I made a couple of mistakes in the W5100S-EVB-Pico2 PR (not sure if we change those now as it may break user code). The WIZnet PRs for the original Pico W5100s and W5500 do not have default UART, I2C, or and SPI Singletons. However, WIZnet docs (arguably) show a preferred UART on GP0 and GP1 (peripheral 0), and of course the SPI used for Ethernet is highlighted. No hints on the silkscreen labels, everything is GPxx though the span of Ethernet pins is generally marked.
But perhaps the most relevant thing here is naming pins GPIO26 and GPIO 27 (doubling up on scarce ADC pins) as SDA and SCL, when the default I2C is called out as GPIO5 and GPIO4... could lead to some confusion. Both are on peripheral 1.
Some guidance from one of the core devs may be helpful. We could potentially go back and edit all of these WIZnet boards to match.
I looked at that page and could not find something that marked that as preferred (or for the preferred I2C). What am I missing? |
In the pinout diagram in the docs, GP0 and GP1 are in a bolder shade of purple than the other UART pins. I don't find any indications of a preference for I2C. |
I am a little reluctant to make default UART, I2C, etc., if there is little to no documentation for that. We didn't do that on the Pi Pico, for instance, though there are defaults (more than one set!). @fasteddy516, how did you decide on those defaults? |
I just copied the existing W5100S-EVB-Pico2 then compared with the existing W5500-EVB-Pico. I pulled the Dropping the two |
I may have done the same thing with the W5100S-EVB-Pico2 since the W5100s and W5500 EVB Pico boards were the only WIZnet definitions at the time. I misspoke above, I may have been looking at the PR and not the current code. The original Pico1 Wiznet boards do now have all three Singletons defined in Maybe we decide what's right for this board, then decide how much to retrofit (break?) the previous three boards. I don't have any strong positions either way. |
If we ignore the existing boards and approach this one fresh, it's a Raspberry Pi Pico 2 (The board pinouts/GPIO/peripheral assignments are identical) with a W5500 ethernet chip hardwired to GP16-GP21. I would suggest:
I'm happy to make whatever changes make the most sense to everyone. |
Was thinking about this some more - maybe 'W5K_' instead of 'ETH_'. That at least keeps them hardware family-specific and helps relate them to the 'adafruit_wiznet5K' driver. Could even update the driver to recognize and auto-assign appropriately named 'W5K' pins if they exist in 'board'. |
I agree with this and the other points. Could you make those changes and regularize the other related boards if needed? Thanks. Also I like the |
For sure, I'll make those changes. I can regularize the other related boards in a separate pull request unless you prefer it all in one. |
Either way is fine. |
Should be good to go for this board now. It's effectively the same as a Pico 2, but with the added |
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.
Thanks! - one thing re default and STEMMA I2C
ports/raspberrypi/boards/wiznet_w5500_evb_pico2/mpconfigboard.h
Outdated
Show resolved
Hide resolved
One more thing: it looks like some changes in |
I believe should be good to merge now, thanks! |
This adds the WIZnet W5500-EVB-Pico2 development board. It's virtually identical to the existing W5100S-EVB-Pico2 aside from the USB PID and WIZnet ethernet chip.