Created
January 6, 2022 10:48
-
-
Save QZLin/ac0ca464f610df0d3f562b0bcac24965 to your computer and use it in GitHub Desktop.
Simple Python Udp Client
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from socket import * | |
addr = ('127.0.0.1', 8000) | |
s = socket(AF_INET, SOCK_DGRAM) | |
s.sendto('testmsg'.encode(encoding='utf-8'), addr) | |
s.close() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment