210 likes | 546 Views
PLC Based Residential Alarm System John Hiddema University of Idaho - ECE 504 - Spring 2012. Project final presentation. Project Goals Project Description Sensors PLC MODBUS RTU over Serial (RS-232) MODBUS Polling Tool Excel Logger and SMS Utility (VBA Based) Project Functionality Video
E N D
PLC Based Residential Alarm System John Hiddema University of Idaho - ECE 504 - Spring 2012 Project final presentation
Project Goals • Project Description • Sensors • PLC • MODBUS RTU over Serial (RS-232) • MODBUS Polling Tool • Excel Logger and SMS Utility (VBA Based) • Project Functionality Video • Project Development Issues • Future Project Additions/Improvements Presentation overview
Wire inputs to a PLC and learn to program a PLC with ladder logic Alarm for events Establish local communication to the PLC via MODBUS RTU over serial (RS-232) Establish remote notification of events via SMS text messages on cell phone Project Goals
Four sensors (‘arm system’, ‘door alarm’, ‘window alarm’, ‘motion alarm’) wired to PLC Inputs Ladder logic in the PLC maps PLC Inputs to PLC Outputs (coils) PLC coil status is polled via MODBUS RTU Poll utility MODBUS data is continuously logged in real-time and alarms are sent via SMS to homeowners cell phone Project DESCRIPTION
Project description – BLOCK DIAGRAM LOCAL ALARMS SENSORS LOCAL AUDIBLE ALARM/BUZZER ARM SYSTEM PLC DOOR ALARM INPUTS OUTPUTS WINDOW ALARM SMS MOTION ALARM RS232 Email Verizon SMS Gateway PC with MODBUS POLL & EXCEL LOGGER AND SMS UTILITY
Project description - sensors • Sensors simulated with four toggle switches on the side of the PLC enclosure • Toggle switches were used instead of actual “field” wiring/sensors to facilitate system development • “Normally-open” contacts used on the toggle switches • Toggle switches mimic magnetic door and window sensors and also a motion sensor with NO/NC contacts
Project description - plc • DirectLOGIC Micro Programmable Logic Controller (DL05 PLC) • Model used: D0-05AR • 8 AC inputs • 6 relay outputs, 2A/point • I/O Rating: 110/220 (+10%, -15%) VAC • Two communication ports • Supports MODBUS RTU master/slave, DeviceNET slave, Proibus slave and Ethernet networking
Project description - plc PLC Program Ladder Logic Arm Alarm System Door Alarm (If Armed) Window Alarm (If Armed) Motion Alarm (If Armed)
Project description - modbus • “Free” MODBUS polling tool (MODBUS Poll) utilized as a MODBUS master to poll the PLC • Coil (outputs) MODBUS address on PLC starts at address 2048. Four coils polled • MODBUS RTU protocol • Serial Connection (RS-232) • MODBUS Poll has data logging capabilities direct to Excel
Project description – excel tool • Custom Excel data logging tool written to interpret data logs • VBA code utilized to interpret coil status and send pre-defined email via Microsoft Outlook • Separate distinct messages are sent for each event (i.e. “Alarm System Armed”, “Door Alarm” etc.) • Verizon SMS gateway and “vtext” address utilized for text messaging. • For example: 555-555-5555@vtext.comsends a text message to 555-555-5555
Project functionality video • Link: www.youtube.com/watch?v=ZuekagVs-3w
Project development issues • Physical mounting and wiring of the PLC took some time • Learning the DirectSoft programming tool and establishing communication with the PLC was a bit of a challenge • The biggest effort was communicating over MODBUS, establishing the logging, and writing VBA code to interpret the logs and send an email via Outlook
future project additions/improvements • Install permanent field sensors for door/window/motion alarms • Install a permanent local audible alarm/buzzer • Possibly add more sensors and actuation (e.g. water sensor > start sump pump) • Improve the functionality and reliability of the Excel Logger & SMS Utility tool