Co-design of controller and routing redundancy over a wireless network