-
Notifications
You must be signed in to change notification settings - Fork 36
support for socketpool? #126
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
I wasn't sure if it would work, but it seems to: import time
import board
import busio
import digitalio
import adafruit_ntp
from adafruit_wiznet5k.adafruit_wiznet5k import WIZNET5K
import adafruit_wiznet5k.adafruit_wiznet5k_socket as socket
cs = digitalio.DigitalInOut(board.GP17)
spi = busio.SPI(board.GP18, MOSI=board.GP19, MISO=board.GP16)
eth = WIZNET5K(spi, cs, debug=False)
eth_ip = eth.pretty_ip(eth.ip_address)
print(f"WIZnet Client IP Address: {eth_ip}")
# socket.set_interface(eth) # needed with v3.0.0
ntp = adafruit_ntp.NTP(socket, tz_offset=-5)
while True:
print(ntp.datetime)
time.sleep(5) Result:
|
hi, |
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi,
I'd like to use adafruit_ntp but this library has a dependency on socketpool, which isn't supported for the rp2040 featherwing (which I am using) because the featherwing doesn't have a wifi, hence I'm using the wiznet5k ethernet module.
So, I'm asking you to please look into the effort it would take to not only allow the import of wiznet5k_socket but also the import of wiznet5k_socketpool.
Thank you,
bob s.
The text was updated successfully, but these errors were encountered: