Take the switch and place it near the pc and connect it to power. Take the ethernet cable that was originally in the pc (that runs to the cnc) and connect it into the switch. Take the 2meter ethernet cable you have just bought and connect to into the switch, with the other end connect it into the pc.