Closed superkakaboum closed 4 months ago
there is void begin(uint8_t *mac, IPAddress ip, IPAddress dns, IPAddress gateway, IPAddress subnet);
too
Closing as invalid since, as @<!---->JAndrassy pointed out, it seems the library already provides the capability you require and the problem is simply that you aren't using the EthernetClass::begin
overload that provides that capability.
@superkakaboum if you would like assistance with adjusting your sketch to use the correct EthernetClass::begin
overload, or would like any other project discussion or assistance, you are welcome to post over on Arduino Forum:
https://forum.arduino.cc/c/using-arduino/networking-protocols-and-devices/27
I'm sure we'll be able to help you over there.
I'm trying to configure a subnet for my Ethernet shield, but it doesn't work if I wanted it to be in /28.
I don't know why we need to change the W5100.cpp file, but also to change the subnet we had to change line 77 in
Ethernet.cpp
:https://github.com/arduino-libraries/Ethernet/blob/63eec8690b38639642b8adcabf9e356b3f97621b/src/Ethernet.cpp#L75-L77
To:
I'm not very good at programming and maybe I don't know how to use the arduino board but I'd like it to work in my arduino code when I set the subnet and whatever I want it to work so I don't have to go into the configuration files.
For the record, I had to carry out a project to retrieve data from an angular sensor via a more or less complex network on gns3, a storage server which would then display the statistics on a web page.