We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 593017d commit 8c91a00Copy full SHA for 8c91a00
UIPServer.cpp
@@ -26,6 +26,12 @@ UIPServer::UIPServer(uint16_t port) : _port(htons(port))
26
{
27
}
28
29
+//added function to change port on the fly
30
+void UIPServer::setport(uint16_t port)
31
+{
32
+ _port=htons(port);
33
+}
34
+
35
UIPClient UIPServer::available()
36
37
UIPEthernetClass::tick();
UIPServer.h
@@ -32,6 +32,7 @@ class UIPServer : public Server {
size_t write(uint8_t);
size_t write(const uint8_t *buf, size_t size);
using Print::write;
+ void setport(uint16_t _port); //added function to change port on the fly
private:
38
uint16_t _port;
0 commit comments