Lab #9: Home security system (Alarm System)
Objective: Design and implement a microcontroller-based development board for a home security system using the PIC16F18875 microcontroller. The system should meet the specified performance requirements and be thoroughly documented.
Specifications
- System Scope:
- The system is designed to secure an average home.
- It must monitor a minimum of 5 openings (doors or windows), with at least one door and one window.
- Code Input:
- The system will be enabled and disabled by inputting a 3-digit code sequentially.
- Arming Delay:
- A 30-second delay upon arming the system at a door opening to allow the occupant to exit without triggering the alarm.
- Disarming Delay:
- A 30-second delay upon entering the premises at a door opening to allow the occupant to enter and disarm the system without triggering the alarm.
- Alarm Outputs:
- Two distinct outputs:
- A signal to activate an external siren or bell.
- A second signal, delayed by 15 seconds, to notify a local monitoring station.
- The external siren signal will have a silent feature.
- Two distinct outputs:
- Opening Indication:
- The system will indicate which opening was entered when enabled and retain this information until reset.
- Inputs and Outputs:
- Inputs: Sensor outputs (5), code input, silent feature, and reset signal.
- Outputs: Two system outputs for the siren and monitoring station, indicated by LEDs.
- Board Design:
- Ensure the development board has enough pins for all connections.
Requirements
- Assembly Language Program:
- Write the program in Assembly language with appropriate comments.
- Include subroutines where possible to adhere to standard programming techniques.
- Building and Debugging:
- Build the program and produce the .asm file for review.
- Download the .HEX file.
- Debug the program thoroughly and include portions of the debug process in your report.
- Demonstration:
- Demonstrate the operational program to the instructor.
- Post a demo video on Canvas.
- Technical Report:
- Prepare a fully documented technical report, including:
- Introduction: Overview of the project and objectives.
- Discussion of Results: Detailed explanation of the design process, including equations, graphs, schematics, oscilloscope pictures, and other relevant components.
- Understandability: Ensure the report is understandable to another engineer or supervisor not working on the project.
- Conclusion: Summarize the results, discuss interesting findings or unexpected outcomes.
- Prepare a fully documented technical report, including:
Detailed Steps
- Circuit Design:
- Design the circuit to monitor 5 openings with sensors connected to the microcontroller.
- Include input mechanisms for the 3-digit code, silent feature, and reset signal.
- Design output connections for the siren and monitoring station, indicated by LEDs.
- Coding:
- Initialize the microcontroller’s I/O ports and configure the ADC for sensor inputs.
- Write subroutines for reading the sensors, inputting the code, and managing delays.
- Implement logic for arming/disarming the system, triggering alarms, and indicating which opening was entered.
- Testing and Debugging:
- Test the circuit and code to ensure all specifications are met.
- Debug any issues and document the debugging process.
- Documentation:
- Create a detailed schematic diagram of the circuit.
- Include high-quality pictures of the assembled circuit board.
- Write and comment the assembly code.
- Record a video demonstrating the working system.
Submission
- Schematic Diagram: Upload a PDF or image file of the schematic diagram.
- Circuit Board Pictures: Upload image files of the circuit board.
- Code: Include the commented assembly code in a text file or directly within the submission platform.
- Video: Upload the video file demonstrating the working security system.
- ASM and HEX Files: Upload the .asm and .HEX files containing the code.
Grading Criteria
- Report Quality:
- Clarity, spelling, grammar, and organization of the report.
- The report should be understandable to another engineer or supervisor not involved in the project.
- System Functionality:
- Whether the system works according to the specifications.
- How well the system was designed and implemented.
- Programming Standards:
- Adherence to standard programming techniques, including the use of subroutines.