Swarms of flying robots can be used in disaster areas to autonomously create communication networks for rescuers and victims. Flying robots have the advantage of rapidly overcoming difficult terrain and providing unobstructed wireless communication. To allow for a swarm composed of cheap, transportable and robust robots, we avoid using positioning sensors which typically depend on the environment (GPS, cameras) or are expensive and heavy (lasers, radars). Instead, robot behaviors depend on local communication with robots within transmission range. There currently exists no methodology to design robot controllers resulting in the emergence of desired swarm behaviors. Here, we propose two bio-inspired techniques to overcome this problem. In the first approach, we use artificial evolution as a mean to automatically design simple, efficient and unthought-of controllers for robots. We then reverse-engineer these controllers and reuse the discovered principles in a wide variety of scenarios. In the second approach, we look at the creation, maintenance and evaporation of army-ant pheromone trails during foraging and apply the same principles to the design of robot controllers for the deployment, maintenance and retraction of communication networks.