A significant amount of sensor network research has addressed the problem of energy-efficiency, primarily by exploiting the fact that computation is many orders of magnitude less expensive than radio communication. The role of storage in sensor networks has often been overlooked since flash memory has been assumed to be inefficient energy-wise. The emergence of new NAND flash technologies significantly alters this tradeoff, and measurements show that the cost of storage is now two orders of magnitude cheaper than communication and comparable to that of computation. This development calls for a significant rethinking in sensor network design and articulates a vision where sensor nodes will be equipped with high-capacity local flash storage. The STONES project proposes fundamental cross-disciplinary research aimed at redesigning sensor software and platforms by making the role of storage central in these systems. STONES provides a rich data management stack that employs a layered architecture similar to a network protocol stack. This stack comprises three layers: (i) an object storage layer that supports flexible object types optimized for energy and memory-constrained systems, (ii) a local database layer that supports power-constrained query processing using locally archived and indexed data as well as multi-resolution storage, and (iii) a distributed data management layer responsible for ensuring data availability despite node failures. The STONES system will be evaluated using a camera sensor network and reference implementations and source code for prototypes will be made available to other researchers via an open-source software license.