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

wifinina: add support for http server #480

Merged
merged 2 commits into from
Nov 14, 2022
Merged

wifinina: add support for http server #480

merged 2 commits into from
Nov 14, 2022

Conversation

scottfeldman
Copy link
Contributor

This adds http.ListenAndServe() implementation for wifinina. Included is an example webserver, basically copied from the rtl8720dn/webserver.

Tested on Arduino Nano RP2040 Connect. Also tried testing on Arduino Nano33 IoT but test panics with "out of memory". There's only 32K of SRAM on the Nano33, vs 264K on the rp2040 Connect.

This adds http.ListenAndServe() implementation for wifinina.  Included
is an example webserver, basically copied from the rtl8720dn/webserver.

Tested on Arduino Nano RP2040 Connect.  Also tried testing on Arduino
Nano33 IoT but test panics with "out of memory".  There's only 32K of
SRAM on the Nano33, vs 264K on the rp2040 Connect.
@sago35
Copy link
Member

sago35 commented Nov 10, 2022

I will check this weekend.

@sago35 sago35 self-requested a review November 10, 2022 23:04
Copy link
Member

@sago35 sago35 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Source code verified.
I think it is very good.

I also tried running it on PyPortal.
I was able to confirm that it is working correctly.

@deadprogram
Copy link
Member

Thank you for the addition @scottfeldman and to @sago35 for review. Now going to squash/merge.

@deadprogram deadprogram merged commit 0ec887c into tinygo-org:dev Nov 14, 2022
@scottfeldman scottfeldman deleted the wifinina-webserver branch November 15, 2022 17:08
deadprogram pushed a commit that referenced this pull request Dec 23, 2022
* wifinina: add support for http server

This adds http.ListenAndServe() implementation for wifinina.  Included
is an example webserver, basically copied from the rtl8720dn/webserver.

Tested on Arduino Nano RP2040 Connect.  Also tried testing on Arduino
Nano33 IoT but test panics with "out of memory".  There's only 32K of
SRAM on the Nano33, vs 264K on the rp2040 Connect.
@fangyygw
Copy link

out of memory in Arduino-Nano33-iot

@scottfeldman
Copy link
Contributor Author

@fangyygw Yes, arduino-nano33 doesn't have enough SRAM (32KB) to support http server. Alternate boards that can use wifinina for http server are: nano-rp2040, pyportal, metro-m4-airlift, and matrixportal-m4.

roman-dvorak pushed a commit to roman-dvorak/tinygo-drivers that referenced this pull request Feb 17, 2023
* wifinina: add support for http server

This adds http.ListenAndServe() implementation for wifinina.  Included
is an example webserver, basically copied from the rtl8720dn/webserver.

Tested on Arduino Nano RP2040 Connect.  Also tried testing on Arduino
Nano33 IoT but test panics with "out of memory".  There's only 32K of
SRAM on the Nano33, vs 264K on the rp2040 Connect.
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.

4 participants