## 1.1 Purpose
This document specifies the requirements for the development of a “Smart House” system, called DigitalHome (DH). The system is a home management system that allows residents to manage their daily lives by providing a lifestyle that brings together security, environmental and energy management (temperature, humidity, and lighting), entertainment, and communications.

This initial version of DigitalHome will be a limited prototype. The purpose of this prototype is to allow HomeOwner management to make business decisions about the future commercial development of DigitalHome products and services.

## 1.2 Scope
The software product to be produced is a limited prototype version of a smart house system named DigitalHome (DH).

The DigitalHome system will allow a user to manage devices that control a home's environment using a web-ready device such as a computer, cell phone, or PDA. The scope of this prototype is limited to the management of devices that control temperature, humidity, security, and power to small appliances and lighting units. The prototype will be tested in a simulated environment where all physical components are simulated.

The primary objective of this prototype is to serve as a proof-of-concept for HomeOwner management. It will be used to make business decisions regarding the future commercial development of DigitalHome products and services. The ultimate goal is to provide a system that allows residents to easily manage their daily lives by integrating security with environmental and energy management.

This specification is based on the DigitalHome Customer Need Statement and the Digital Home High Level Requirements Definition [HLRD 2010].

### 1.3.1 Product perspective
The DigitalHome (DH) system is a home management system that allows a user to manage devices controlling the home environment. It is a prototype based on the Digital Home High Level Requirements Definition [HLRD 2010]. The system consists of a central computer system which manages various household components, including devices, sensors, controllers, and the communication links between them.

#### System interfaces
The DH system interfaces with various sensors and controllers within the home. These include:
*   Digital programmable thermostats
*   Digital programmable humidistats
*   Magnetic alarm contact switches
*   Security sound and light alarms
*   Digital programmable power switches for small appliances and lighting

#### User interfaces
The user interacts with the DigitalHome system through a personal web page hosted on the DigitalHome web server or a local home server. This web interface is accessible from a web-ready computer, cell phone, or PDA. Users are expected to be familiar with standard web operations such as logging in, browsing pages, and submitting information via a web interface.

#### Hardware interfaces
The software interfaces with the following hardware components:
*   A DH Home Web Server, hosted on a home computer.
*   A DH Gateway Device, which connects to a broadband internet connection and contains an RF Module for wireless communication with other devices. It has an indoor range of up to 1000 feet.
*   Environmental sensors and controllers (thermostats, humidistats, contact sensors, alarms, power switches) that communicate wirelessly with the DH Gateway Device.

#### Software interfaces
The system will use a recognized security technology, such as Transport Layer Security, for authentication and information encryption.

#### Communications interfaces
*   The system requires a broadband Internet connection from an Internet Service Provider (ISP), such as a cable modem or high-speed DSL.
*   Internal communication between the DH Gateway Device and the sensors/controllers is handled via wireless RF signals.

#### Memory constraints
[N/A]

#### Operations
*   A Master User or DH Technician can perform system configuration, including adding user accounts, changing default parameter settings, and starting and stopping system operation.
*   The system will perform daily backups of all system data, including configuration, default parameter settings, planning, and usage data.
*   In case of system failure, a recovery mechanism will restore system data from the most recent backup.

#### Site adaptation requirements
A DH Technician is responsible for the initial setup and configuration of a DH system at a specific site. This includes setting system parameters, establishing user accounts, and setting the daily backup time.

#### Interfaces with services
The system requires services from an Internet Service Provider (ISP) for internet connectivity.

### 1.3.2 Product functions
The DigitalHome (DH) system will provide users with the capability to monitor and control their home's environment using a web-ready computer, cell phone, or PDA. The major functions of the system are summarized below:

*   **Environmental Management:** The system will allow a user to monitor and control the temperature and humidity in different spaces within the home.
*   **Security Management:** The system will monitor door and window contact sensors and activate light and sound alarms when a security breach is detected.
*   **Appliance and Lighting Management:** The system will allow a user to turn small appliances and lighting units on or off.
*   **Planning:** The system will provide a planner for users to create and modify monthly schedules that specify environmental parameter settings for different time periods.
*   **Reporting:** The system will generate monthly reports on the management and control of the home, including average environmental values, security breach logs, and system operational status.

A supplementary Use Case Model provides additional detail and an overview of the system functionality.

### 1.3.3 User characteristics
There are three types of users for the DigitalHome system: General User, Master User, and DigitalHome Technician.

*   **General User**
    *   Is familiar with the layout of their home and the location of sensor and control devices.
    *   Is not familiar with the technical features of the DigitalHome system but is familiar with using a web interface.
    *   Can perform simple web operations such as logging in, browsing web pages, and submitting information and requests.

*   **Master User**
    *   A designated user who can change the configuration of the system, such as adding a user account or changing default parameter settings.
    *   Possesses the same system rights as a DigitalHome Technician.

*   **DigitalHome Technician**
    *   Is responsible for setting up and maintaining the system configuration.
    *   Has experience with the type of hardware, software, and web services associated with the DigitalHome system.
    *   Is specially trained by DigitalHomeOwner to be familiar with the functionality, architecture, and operation of the system.
    *   Has administrative rights to configure the system, set system parameters, establish user accounts, and start and stop system operation.

### 1.3.4 Limitations
*   The DigitalHome system specified in this document is a limited prototype version intended to inform business decisions, not a comprehensive specification for a commercial product.
*   The prototype system will be situated in a simulated environment. There will be no actual physical home, and all sensors and controllers will be simulated.
*   The system requires a broadband Internet connection from a third-party Internet Service Provider (ISP).
*   The system must adhere to the standards, policies, and procedures of the American Society of Heating, Refrigerating and Air-Conditioning Engineers (ASHRAE).
*   Development must use object-oriented methods with UML 2.0, and adhere to specified IEEE standards and the HomeOwner Coding Standard.
*   The Gateway device has an operational range of up to 1000 feet for indoor transmission; sensors and controllers must be within this range to communicate with the system.
*   The thermostat's temperature sensor has a sensitivity range between 14°F and 104°F (-10°C and 40°C).
*   The system is limited to managing the following maximum number of devices:
    *   Eight thermostats
    *   Eight humidistats
    *   Fifty door and window contact sensors
    *   One sound alarm and one light alarm subsystem
    *   One hundred 115 volt, 10 amp power switches
*   User-configurable set points are limited to the following ranges:
    *   Temperature: 60°F to 80°F
    *   Humidity: 30% to 60%
*   The system must achieve a reliability of no more than one failure per 10,000 hours of operation.
*   Historical data for reports is only retained for the past two years.
*   System access requires user authentication, and communications must be encrypted using a recognized technology such as Transport Layer Security.

## 1.4 Definitions
*   ASHRAE - American Society of Heating, Refrigerating and Air-Conditioning Engineers.
*   Authentication - Any process by which it is verified that someone is who they claim they are. This typically involves submission and verification of a username and a password.
*   Broadband Internet - A high data rate Internet access, typically contrasted with slower dial-up access.
*   DH (Digital Home) - The name of the prototype smart home product that is to be produced by DigitalHomeOwner.
*   DigitalHomeOwner – The division of HomeOwner Inc. responsible for producing DigitalHome products.
*   DSL (Digital Subscriber Line) - A family of technologies that provides digital data transmission over the wires of a local telephone network.
*   Encryption - The process of transforming information (referred to as plaintext) using an algorithm (called a cipher) to make it unreadable to anyone except those possessing special knowledge, usually referred to as a key.
*   FAQ – Frequently asked question.
*   Gateway Device - A home networking device used to connect devices in the home to the Internet or other Wide Area Networks.
*   HomeOwner Inc. - The largest national retail chain serving the needs of home owners in building, furnishing, repairing, and improving their homes.
*   HVAC - Heating, Ventilation and Air Conditioning.
*   Humidistat - An instrument that measures and controls relative humidity.
*   ISP - Internet Service Provider.
*   PDA – Personal Digital Assistant.
*   RF – Radio Frequency.
*   Security Breach – An external act that bypasses or contravenes the digital home security system. For example, if an intruder opens a door where the contact sensor is set to “on”, the system will sense a ‘security breach”.
*   Set Point – A numeric value that establishes the desired value of an environmental quality (e.g., a temperature value of 70° F).
*   SRS – Software Requirements Specification.
*   Transport Layer Security - Cryptographic protocols that provide security for communications over networks such as the Internet.

# 2 References
## Compliance
*   [ASHRAE 2010] Website for American Society of Heating, Refrigerating and Air-Conditioning Engineers, accessed October 2010, http://www.ashrae.org/.
*   [HLRD 2010] DigitalHomeOwner Division, Digital Home High Level Requirements Definition, Homeowner Inc., September 2010.
*   [HO2305] Sykes, J., and Rook, R., Guidelines for Developing HomeOwner Technical Reports, HO2305., Homeowner Inc., March 2002.
*   [HO4710] Kramer, S., HomeOwner Coding Standard, HO4710., Homeowner Inc., August 2009.
*   [IEEE830] IEEE Std 830-1998, IEEE Recommended Practice for Software Requirements Specifications, Institute of Electrical and Electronics Engineers, Inc., 1998.
*   [IEEE 1008] ANSI/IEEE Std 1008-1987, IEEE Standard for Software Unit Testing, Institute of Electrical and Electronics Engineers, Inc., 1987.
*   [IEEE 1012] IEEE Std 1012-2004, IEEE Standard for Software Verification and Validation, Institute of Electrical and Electronics Engineers, Inc., 2004.
*   [IEEE1016] IEEE Std 1016-2009, IEEE Standard for Information Technology - Systems Design - Software Design Descriptions, Institute of Electrical and Electronics Engineers, Inc., 2009.
*   [IEEE1028] IEEE Std 1028-2008, IEEE Standard for Software Reviews and Audits, Institute of Electrical and Electronics Engineers, Inc., 2008.

## Guidance
*   [HO2010] Digital Home Use Case Model, HomeOwner Inc, DigitalHomeOwner Division, October 24, 2010.
*   [Meyer 2004] Meyer, G., Smart Home Hacks: Tips & Tools for Automating Your House, O’Reilly, 2004.

## 3.1 Functions
### 3.1.1 General Functions
*   The system shall allow a user to monitor and control a home's temperature, humidity, lights, security, and the state of small appliances using a web-ready computer, cell phone, or PDA.
*   The system shall use a DH home web server as the central point for user interaction to monitor and control home devices.
*   The system shall read sensor values via wireless communication and save them in a home database.
*   The system shall send controller values via wireless communication to change the home environment.

### 3.1.2 User and System Management
*   The system shall provide for the establishment of user accounts.
*   A Master User or DH Technician shall be able to add user accounts and change default parameter settings.
*   A DH Technician shall be able to start and stop the operation of the system.
*   The system shall provide a backup service for user account information, user plans, and a home database.

### 3.1.3 Security and Authentication
*   The system shall require users to log in with an account name and password for authentication.
*   The system shall use a recognized security technology, such as Transport Layer Security, for authentication and information encryption.

### 3.1.4 Thermostat Management
*   The system shall allow a user to read the current temperature at each thermostat's location.
*   The system shall allow a user to set thermostat temperatures between 60°F and 80°F, inclusive, in one-degree increments.
*   The system shall support up to eight thermostats, which can be controlled individually or collectively.
*   For each thermostat, the system shall allow scheduling of up to twenty-four one-hour settings per day for every day of the week.
*   If a user makes a manual temperature setting on a device, the setting shall remain in effect until the end of the current time period, after which the scheduled or default setting will resume.
*   The system shall support both Fahrenheit and Celsius temperature values.

### 3.1.5 Humidistat Management
*   The system shall allow a user to read the current humidity at each humidistat's location.
*   The system shall allow a user to set the humidity level for a humidistat from 30% to 60%, inclusive, in 1% increments.
*   The system shall support up to eight humidistats.
*   For each humidistat, the system shall allow scheduling of up to twenty-four one-hour settings per day for every day of the week.
*   If a user makes a manual humidity setting on a device, the setting shall remain in effect until the end of the current time period, after which the scheduled or default setting will resume.

### 3.1.6 Security System Management
*   The system shall manage up to fifty door and window contact sensors.
*   The system shall activate one sound alarm and one light alarm subsystem when a security breach occurs (i.e., a contact sensor is set to OPEN).

### 3.1.7 Appliance and Lighting Management
*   The system shall manage up to one hundred power switches for small appliances and lighting units.
*   The system shall provide the current state of a power switch (ON or OFF).
*   The system shall allow a user to change the state of a power switch (from ON to OFF, or OFF to ON).
*   If a user manually changes the state of a power switch, the device shall remain in that state until the end of the current time period, after which the scheduled or default setting will resume.

### 3.1.8 Planning and Reporting
*   The system shall provide a monthly planner for a user to create or modify a plan that specifies environmental parameter settings for up to four daily time periods.
*   The system shall allow a user to override planned parameter values at any time.
*   The system shall generate monthly reports for any month in the past two years.
*   The monthly report shall contain:
    *   Daily average, maximum, and minimum values for temperature and humidity for each sensor, including the time of the maximum and minimum.
    *   The day and time of any security breaches.
    *   Periods of time when the system was not in operation.

### 3.1.9 User Documentation
*   The system shall provide online user documentation that includes:
    *   A "Frequently Asked Questions" (FAQ) section.
    *   An explanation of how to set parameters and read sensor values.
    *   A description of how to use the planner.

### 3.1.10 Error Handling and Recovery
*   The system shall perform a daily backup of all system data, including configuration, default settings, plans, and usage data.
*   If the system fails due to power loss, loss of internet access, or other failures, a recovery mechanism shall restore system data from the most recent backup.
*   The system shall incorporate exception handling to respond to a user with a clear, descriptive message when an error or exceptional condition occurs.
*   Responses to overflow conditions: [N/A]

## 3.2 Performance requirements
*   Displays of environmental conditions (temperature, humidity, contact sensors and power switches) shall be updated at least every two seconds.
*   Sensors (temperature, humidity, contact sensor, power state) shall have a minimum data acquisition rate of 10 Hz.
*   An environmental sensor or controller device must be within 1000 feet of the master control device to be in communication with the system.
*   The system shall be able to manage up to eight thermostats.
*   The system shall be able to manage up to eight humidistats.
*   The system shall be able to manage up to fifty door and window contact sensors.
*   The system shall be able to manage up to one hundred power switches.
*   The system shall be able to provide reports on the management and control of the home for any given month in the past two years.
*   The system must be highly reliable with no more than 1 failure per 10,000 hours of operation.

## 3.3 Usability requirements
The system shall be usable by a general user who is familiar with the use of a web interface and can perform simple web operations, but is not familiar with the technical features of the DigitalHome system.

All DigitalHome operations shall incorporate exception handling so that the system responds to a user with a clear, descriptive message when an error or an exceptional condition occurs.

The DigitalHome System shall provide users with online documentation about the system installed in their home. The user documentation shall include the following:
*   An FAQ section with frequently asked questions about the use and maintenance of the system.
*   A section that explains how system parameters are set and sensor values are read, including information on limitations and constraints on parameter settings and sensor reading accuracy.
*   A section that describes how to use the DH Planner.

## 3.5 Logical database requirements
The system shall maintain a home database with the following characteristics:

*   **Types of information used by various functions:**
    *   User account information, including account name and password.
    *   System configuration and default parameter settings.
    *   User-defined monthly plans that specify environmental parameter settings (temperature, humidity, contact sensors, and power switches) for up to four daily time periods.
    *   Historical sensor values from thermostats and humidistats, with timestamps.
    *   Historical security breach events, with timestamps.
    *   System operational status, including periods when the system was not in operation.
    *   Usage data.

*   **Frequency of use:**
    *   Sensor values are read from devices and saved to the database.
    *   Users can create or modify plans as needed.
    *   The system generates monthly reports based on historical data.
    *   All system data (configuration, settings, planning, and usage data) is backed up on a daily basis.

*   **Accessing capabilities:**
    *   A general user shall be able to create and modify plans.
    *   A general user shall be able to generate reports based on their home's historical data.
    *   A Master User or DH Technician shall be able to establish and maintain user accounts.
    *   A Master User or DH Technician shall be able to change system configuration and default parameter settings.

*   **Data entities and their relationships:**
    *   [N/A]

*   **Integrity constraints:**
    *   Thermostat temperature settings must be between 60°F and 80°F.
    *   Humidistat humidity settings must be between 30% and 60%.

*   **Security:**
    *   The database shall store user account information, including account names and passwords for authentication.

*   **Data retention requirements:**
    *   Data required for monthly reports (sensor values, security breaches, system operation status) shall be retained for the past two years.

## 3.6 Design constraints
*   The system shall adhere to the standards, policies, and procedures of the American Society of Heating, Refrigerating and Air-Conditioning Engineers [ASHRAE 2010].
*   The development team shall use the development process specified by DigitalHomeOwner Inc.
*   Object-oriented development using UML 2.0 is the designated method for software development.
*   The project shall employ widely used, accepted, and available hardware and software technology and standards for both product elements and development tools.
*   All modules and components of the prototype shall be designed and implemented for potential incorporation into a fully specified commercial version of the DigitalHome System.
*   The development shall adhere to the following documentation and coding standards:
    *   IEEE standards [IEEE830, IEEE1008, IEEE1016, IEEE1028].
    *   The HomeOwner Coding Standard [HO4710].
    *   The Homeowner document format [HO2305] for all system documents.
*   The prototype must be completed within twelve months of inception.
*   The development team will consist of five engineers.
*   The cost of system elements (sensors, controllers, server, tools, etc.) should be minimized.
*   The system will be tested in a simulated environment where all sensors and controllers are simulated. The simulated environment must be realistic and adhere to the physical properties and constraints of an actual home and real devices.

## 3.7 Software system attributes
### Reliability
The DigitalHome System must be highly reliable with no more than 1 failure per 10,000 hours of operation.

All DigitalHome operations shall incorporate exception handling so that the system responds to a user with a clear, descriptive message when an error or an exceptional condition occurs.

### Availability
The Digital Home System shall incorporate backup and recovery mechanisms.

The DH System will backup all system data (configuration, default parameter settings, planning, and usage data) on a daily basis, with the backup time set by the DH Technician at system set up.

If the DH System fails due to power loss, loss of internet access, or other software or hardware failure, the system recovery mechanism shall restore system data from the most recent backup.

### Security
Upon installation, a DigitalHome user account shall be established. The DigitalHome web system shall provide for authentication and information encryption through a recognized reliable and effective security technology, such as Transport Layer Security.

Log in to an account shall require entry of an account name and a password.

### Maintainability
The development of the DH system shall use methods and techniques to support system maintenance, including:
*   Documentation of requirements, design, and code.
*   Use of abstraction, information hiding and module independence in system design.
*   Use of IEEE standards and the HomeOwner Coding Standard.

All modules and components of the prototype version shall be designed and implemented in such a manner that they may be incorporated in a fully specified commercial version of the DigitalHome System.

### Portability
Where possible, the DigitalHome project will employ widely used, accepted, and available hardware and software technology and standards.

## 3.8 Supporting information
The development team shall conduct a cost analysis study. As part of the final project report, the team will describe their efforts to minimize costs, including price comparisons between DigitalHome elements and comparable/competitive elements.

The Digital Home Use Case Model [HO2010] provides additional detail and background information, including an overview of the system functionality and the relationships between the DigitalHome System entities.

The DigitalHome System shall provide users with online documentation. This documentation is considered part of the requirements and shall include the following:
*   An FAQ section with answers to frequently asked questions about the use and maintenance of the system.
*   A section that explains how system parameters are set and sensor values are read, including information on limitations and constraints.
*   A section that describes how to use the DigitalHome Planner.

## 4.1 Functions
The DigitalHome system will be tested in a simulated environment. There will be no actual physical home, and all sensors and controllers will be simulated. The simulated environment will be realistic and adhere to the physical properties and constraints of an actual home and to real sensors and controllers.

The project schedule includes dedicated phases for testing:
*   System Testing
*   Acceptance Testing

Software unit testing will adhere to the IEEE Standard for Software Unit Testing [IEEE 1008]. Overall software verification and validation will adhere to IEEE Standard 1012.

## 4.2 Performance requirements
[N/A]

## 4.3 Usability requirements
[N/A]

## 4.5 Logical database requirements
Verification of the logical database requirements will be performed through a combination of inspection, analysis, and testing.

*   Verification of the types of information stored will be accomplished by inspection of the database schema and by testing system functions. This includes creating user accounts, saving system configurations, creating monthly plans, and triggering security events, then querying the database to confirm that all data (user accounts, plans, sensor values, usage data, configuration settings) is stored correctly.
*   Verification of data access capabilities will be performed by demonstration. Testers will execute functions to create and modify plans, generate monthly reports from historical data, and restore the system from a backup to confirm that data can be accessed and manipulated as required.
*   Verification of data retention requirements will be performed by testing. The database will be populated with simulated data spanning more than two years. The reporting function will then be tested to ensure it can successfully generate reports using data from two years prior. The daily backup process will be verified by checking system logs and the backup location to confirm a backup is created each day.
*   Verification of security requirements for the database will be performed by testing the user authentication system with valid and invalid credentials. Network traffic analysis will be used to confirm that data is encrypted during transmission.

## 4.6 Design constraints
[N/A]

## 4.7 Software system attributes
[N/A]

## 5.1 Assumptions and dependencies
*   The system will be developed and tested in a simulated environment. There will be no actual physical home, and all sensors and controllers will be simulated.
*   The simulated environment is assumed to be realistic and will adhere to the physical properties and constraints of an actual home and real sensors and controllers.
*   The system requires a home to have a widely available broadband Internet Service Provider (ISP), such as a cable modem or high-speed DSL.
*   The system assumes a home computer is available to host a local web server.
*   The system depends on the availability of a gateway device that provides wireless communication to home devices and connects to the broadband internet connection.
*   The system depends on the availability of specific hardware components: digital programmable thermostats, digital programmable humidistats, magnetic alarm contact switches, security alarms, and digital programmable power switches.
*   The system's HVAC control functionality will adhere to the standards, policies, and procedures of the American Society of Heating, Refrigerating and Air-Conditioning Engineers [ASHRAE 2010].
*   The development process will use object-oriented development with UML 2.0.

## 5.2 Acronyms and abbreviations
*   ASHRAE - American Society of Heating, Refrigerating and Air-Conditioning Engineers
*   DH - Digital Home
*   DSL - Digital Subscriber Line
*   FAQ - Frequently asked question
*   HVAC - Heating, Ventilation and Air Conditioning
*   ISP - Internet Service Provider
*   PDA - Personal Digital Assistant
*   RF - Radio Frequency
*   SRS - Software Requirements Specification