Communicating with a drive using modbusTCP

I know I need to debouce the button, I will correct that once the rest of the code is working.

What do you mean remove the network code?