In this paper we propose a distributed coordination algorithm for safe and efficient traffic management of heterogeneous robotic agents, moving within dynamic large scale industrial environments. The algorithm consists of a distributed resource–sharing protocol involving a re–planning strategy. Once every agent is assigned with a desired motion path, the algorithm ensures ordered traffic flows of agents, that avoid inter–robot collision and system deadlock (stalls). The algorithm allows multi–level representation of the environment, i.e. large or complex rooms may be seen as a unique resource with given capacity at convenience, which makes the approach appealing for complex industrial environments. Under a suitable condition on the maximum number of agents with respect to the capacity of the environment, we prove that the algorithm correctly allows mutual access to shared resources while avoiding deadlocks. The proposed solution requires no centralized mechanism, no shared memory or ground infrastructure support. Only a local inter–robot communication is required, i.e. every agent must communicate with a limited number of other spatially adjacent robots. We finally show the effectiveness of the proposed approach by simulations, with application to an industrial scenario.