Wireless reprogramming is a key functionality in Wireless Sensor Networks (WSNs). In fact, the requirements for the network may change in time, or new parameters might have to be loaded to change the behavior of a given protocol. In large scale WSNs it makes economical as well as practical sense to upload the code with the needed functionalities without human intervention, i.e., by means of efficient over the air reprogramming. This poses several challenges as wireless links are affected by errors, data dissemination has to be 100% reliable, and data transmission and recovery schemes are often called to work with a large number of receivers. State-of-the-art protocols, such as Deluge, implement error recovery through the adaptation of standard Automatic Repeat reQuest (ARQ) techniques. These, however, do not scale well in the presence of channel errors and multiple receivers. In this paper, we present an original reprogramming system for WSNs called SYNAPSE, which we designed to improve the efficiency of the error recovery phase. SYNAPSE features a hybrid ARQ (HARQ) solution where data are encoded prior to transmission and incremental redundancy is used to recover from losses, thus considerably reducing the transmission overhead. For the coding, digital Fountain Codes were selected as they are rateless and allow for lightweight implementations. In this paper, we design special Fountain Codes and use them at the heart of SYNAPSE to provide high performance while meeting the requirements of WSNs. Moreover, we present our implementation of SYNAPSE for the Tmote Sky sensor platform and show experimental results, where we compare the performance of SYNAPSE with that of state of the art protocols.