Wireless sensor network (WSN) motes of small form factor are operated in resource-constrained settings. This demands for low-power designs and energy-aware operation, but especially for optimization of costly wireless transmissions. A promising approach is to find network structures where network coding can be applied to optimize energy efficiency of information flows. Schemes exist for global optimization of the load on WSN's resources. Nevertheless, applying them in practical settings is often not feasible due to complex computations and the need for centralized knowledge. The gain from optimization methods fades away for scaled and autonomous operation of WSNs due to control overhead. This paper presents LINDONCS: Localized In-Network Detection Of Network Coding Structures. Communication patterns are adapted autonomously without paying off impact on network scalability. We show how to detect structures and apply network coding to improve network lifetime over state-of-the-art solutions.