Jump to content

User:Zainab Siddiqui/Open-Source Sleep/Activity Tracking System

From Appropedia

Project Overview

[edit | edit source]

This project developed an affordable, non-invasive system for long-term monitoring of sleep and activity patterns in mice. The system was developed as part of an undergraduate thesis investigating the relationship between the CADM2 gene and sleep behaviour in transgenic mice. Existing approaches such as electroencephalography (EEG) can provide detailed measurements of sleep but require surgical implantation. Non-invasive infrared sensors have their own limitations because they infer sleep from movement, but they can still provide useful measurements of sleep behaviour. The system therefore adapted the open-source COMPASS framework, using passive infrared (PIR) motion sensing to continuously detect movement across multiple mouse cages.

The resulting setup was designed to provide time-stamped activity data over extended experimental periods while remaining fairly low-cost, modular, and practical for laboratory use. The modified system incorporated remote data logging to make longer-term monitoring more practical.

System Design

[edit | edit source]

The system uses PIR sensors to detect movement within individual mouse cages and convert those signals into time-stamped voltage data. Eight cages could be recorded at once using eight PIR sensors connected across two Arduino boards. An LDR was also included to monitor ambient light conditions.

The hardware was based on the COMPASS design and consisted of individual PIR sensor boards, a multi-channel main PCB, Arduino microcontrollers, and a MicroSD data logging system, which allowed remote recording and was the main modification. The components were connected through RJ12 cabling, allowing the sensor boards to be mounted above individual cages while the main electronics remained centralized.

Table 1. Components of the PIR motion-tracking system
Component Product Information
PIR Sensor Panasonic AMN32111
1K Ohm Resistor 1 kΩ ±5% 1/4 W axial resistor
10K Ohm Resistor 10 kΩ ±5% 1/4 W axial resistor
Main PCB 6-channel PIR main board
PIR Sensor PCB Single PIR + LDR sensor board
Data Logger Shield RTC MicroSD Data Logging Shield for Arduino Uno
LDR Light-dependent resistor, 550 nm peak sensitivity
Arduino Board Arduino Mega 2560 Rev 3
RJ12 Connector 6P4C Right-Angle Modular Jack
2-Pin Header 2.54 mm 2-pin socket header
6-Pin Header 2.54 mm 6-pin socket header
RJ12 Cable 6P6C RJ12 Male-to-Male Cable

My Contributions

[edit | edit source]
Figure 6. 3D-printed block under the water bottle in a home cage

My work focused primarily on the hardware development, assembly, and implementation of the sleep tracking system. I soldered and assembled 18 PIR sensor boards and three main PCB boards, assembled the Micro-SD data logging shield, and connected and tested the components during system setup. I also helped with programming the Arduino to verify and monitor individual PIR sensor outputs duringtesting.

Furthermore, I contributed to the physical implementation of the system by helping develop ideas for sensor mounting and taking measurements used to design 3D-printed PIR sensor housings and the support beneath the water bottle. During testing, I helped troubleshoot hardware connections and refine the physical setup to support consistent operation during long-term behavioural monitoring.

My contribution was primarily on the hardware and physical implementation side of the project; the experimental analysis and final research conclusions were conducted as part of the broader thesis.

Research Outcome

[edit | edit source]

The completed system was used to collect motion-based sleep-wake cycle data from multiple cages over six days. The associated thesis used these measurements to investigate the differences in sleep and activity patterns between CADM2 genotypes. The study reported differences in sleep-pattern adaptation between mouse genotypes and identified the system as a useful approach to further investigating the relationship between CADM2, sleep behaviour, and vulnerability to addiction disorders.

Figure 7. Example of motion-based activity data collected by the system showing average sleeping bouts over six days

Research Team

[edit | edit source]

This engineering work supported an undergraduate thesis project by Aisha Siddiqui in the Khokhar Lab at Western University, supervised by Dr. Jibran Khokhar, with hardware development supported by Hakan Kayir.

My contributions focused on the hardware assembly, testing, and physical implementation described above.

Open-Source Materials

[edit | edit source]

The system was adapted from the open-source COMPASS framework for automated monitoring of transgenic mouse sleep and activity behaviour.

Page data
Authors Zainab Siddiqui
License CC-BY-SA-4.0
Language English (en)
Related 0 subpages, 0 pages link here
Views 55 page views (analytics)
Created September 23, 2026 by Zainab Siddiqui
Last edit September 25, 2026 by Zainab Siddiqui
Cookies help us deliver our services. By using our services, you agree to our use of cookies.