An open source device for operant licking in rats

PeerJ. 2017 Feb 14:5:e2981. doi: 10.7717/peerj.2981. eCollection 2017.


We created an easy-to-use device for operant licking experiments and another device that records environmental variables. Both devices use the Raspberry Pi computer to obtain data from multiple input devices (e.g., radio frequency identification tag readers, touch and motion sensors, environmental sensors) and activate output devices (e.g., LED lights, syringe pumps) as needed. Data gathered from these devices are stored locally on the computer but can be automatically transferred to a remote server via a wireless network. We tested the operant device by training rats to obtain either sucrose or water under the control of a fixed ratio, a variable ratio, or a progressive ratio reinforcement schedule. The lick data demonstrated that the device has sufficient precision and time resolution to record the fast licking behavior of rats. Data from the environment monitoring device also showed reliable measurements. By providing the source code and 3D design under an open source license, we believe these examples will stimulate innovation in behavioral studies. The source code can be found at

Keywords: Behavior testing device; Environment variables; Licking response; Open source; Operant behavior; Single board computer.

Grants and funding

This work was supported by NIH DA-037844 (HC) and the Faculty Start Up Fund by the University of Tennessee Health Science Center. The funders had no role in study design, data collection and analysis, decision to publish, or preparation of the manuscript.