Open
Description
The WIZNET5K driver stores a single value for a source port as an instance variable. Source ports are set per hardware socket before each socket is opened.
I don't think this should be an instance variable, but should be an attribute of the socket_open
method. The 'port' attribute can default to 0 so that a random port is still assigned if no port is specified.
eth.socket_open(socket_number, port=68, conn_mode=SNMR_TCP)
is more intuitive and less prone to error than
eth.src_port = 68
eth.socket_open(socket_number, conn_mode=SNMR_TCP)
eth.src_port = 0
Metadata
Metadata
Assignees
Labels
No labels