A controlled drug delivery system (CODS) that is capable of releasing right dose of drug in the alimentary canal at the prespecified time has been designed, fabricated and tested. This micro-electro-mechanical system (MEMS)-based CODS, in the form of an electronic capsule, has four major components: a timer module for controlling drug release, a driving unit for releasing drug to the alimentary canal, a microfluidic chamber for drug reservoir, and a power supply. Of these four components, the timer module is the most critical one as it needs to provide precise timing points for drug release and must have a simple mechanism for setting up timing parameters externally. To this end, a microcontroller has been employed to realize the timer, while an external resistance network is used to program the timing parameter. The performance of the electronic capsule is evaluated through in vitro and in vivo animal experiments. The preliminary results have confirmed that the electronic capsule can release drug reliably and effectively at the scheduled time points. (C) 2011 Elsevier B.V. All rights reserved.