A granular moving-bed apparatus is introduced to have an inlet louvered wall, an outlet louvered wall opposing to the inlet louvered wall, a granular path formed in between, a plurality of serial roof-shaped flow-corrective elements located along the granular path, and a predetermined type of granular materials flowing inside the granular path. In one embodiment the direction to the intruding object is established by virtue of the use of pairs of E-field sensors. The microcontroller translates the plurality of IO signals to signals comprehensible by IO bus and transmits the translated signal over a serial bus. After a passivation layer, including suitable diffusion barriers, has been laid over the structure, it is over-filled with a suitable soft metal and then planarized in the usual way.