The Smart Applications REFerence ontology (SAREF) is intended to enable interoperability between solutions from different providers and among various activity sectors in the Internet of Things (IoT), thus contributing to the development of the global digital market.
SAREF shall use the SAREF Communication framework as defined in  (ETSI TS 103 267: "SmartM2M; Smart Appliances; Communication Framework”).
Figure 1 shows an overview of the main classes of SAREF and their relationships.
SAREF focuses on the concept of device, which is defined as
a tangible object designed to accomplish a particular task in households, common public buildings or offices. In order to accomplish this task, the device performs one or more functions. Examples of devices are a light switch, a temperature sensor, an energy meter and a washing machine. A washing machine is designed to wash (task) and to accomplish this task it performs a start and stop function. The saref:Device class and its properties are shown in Figure 2.
SAREF is conceived in a modular way in order to allow the definition of any device from pre-defined building blocks, based on the function(s) that the device performs. Therefore, a saref:Device has at least one function (saref:hasFunction min 1 saref:Function). Moreover, a saref:Device can be used for (saref:isUsedFor property) the purpose of offering a commodity, such as saref:Water or saref:Gas. It can also measure a property, such as saref:Temperature, saref:Energy and saref:Smoke. Moreover, a device may consist of other devices (saref:consistsOf property).As shown in Figure 3, types of devices that can be represented are actuators (e.g. a saref:Switch that can be further specialized in saref:LightSwitch and saref:DoorSwitch), sensors (e.g. a saref:SmokeSensor and saref:TemperatureSensor), meters, and appliances. Note that more types of devices, sensors and actuators exist which can be defined to extend SAREF (the device types in Figure 4 represent only some examples that aim at explaining the rationale behind SAREF). A description of these types of devices is presented in the next clause, in combination with the function that they perform. Examples of devices for specific domains are defined in the SAREF extensions ([i.2] to [i.7]).
A function is represented in SAREF with the saref:Function class and is defined as
the functionality necessary to accomplish the task for which a device is designed. Examples of functions are saref:ActuatingFunction, saref:SensingFunction, saref:MeteringFunction and saref:EventFunction. The saref:Function class and its properties are shown in Figure 4.
transmit data to actuators, such as level settings (e.g. temperature) or binary switching (e.g. open/close, on/off)and can be divided into different types, such as for example:
switch on and off an actuator. This function allows the commands saref:OnCommand, saref:OffCommand and saref:ToggleCommand.
do level adjustments of an actuator in a certain range (e.g. 0%-100%), such as dimming a light or set the speed of an electric motor. This function allows the commands saref:SetLevelCommand (which can be of type saref:SetAbsoluteLevel or saref:SetRelativeLevel), saref:StepUpCommand and saref:StepDownCommand.
transmit data from sensors, such as measurement values (e.g. temperature) or sensing data (e.g. occupancy). This function allows the command saref:GetCommand.
get data from a meter, such as current meter reading or instantaneous demand. This function allows the commands saref:GetCurrentMeterValueCommand, saref:GetMeterDataCommand, and saref:GetMeterHistoryCommand.
notify another device that a certain threshold value has been exceeded. This function allows the command saref:NotifyCommand.
In order to show how these functions shall be used, some examples of devices and their functions are defined as follows:
A saref:Function shall have at least one command associated to it (saref:hasCommand min 1 saref:Command). Figure 5 shows the list of commands currently available in SAREF. This list is used here for illustration purposes and can be extended with new commands.
Figure 5 further shows that a command can act upon a state (saref:actsUpon relation) to represent that the consequence of a command can be a change of state of a device. Note that a command may act upon a state, but does not necessarily act upon a state. For example, the saref:OnCommand acts upon the saref:OnOffState, but the saref:GetCommand does not act upon any state, since it only gives a directive to retrieve a certain value.
Depending on the function(s) it performs, a device can be found in a corresponding saref:State, as shown in Figure 6. For example, a switch can be found in the saref:OnOffState, which is further specialized in saref:OnState and saref:OffState. A light switch can be found in the saref:OnOffState upon which the saref:OnCommand and saref:OffCommand shall act. Note that SAREF is not restricted to binary states such as the saref:OnOffState, but allows to define also n-ary states (see, for example, the saref:MultiLevelState class).
Figure 7 shows that a device offers a service (the saref:Service class), which is a representation of a function to a network that makes this function discoverable, registerable and remotely controllable by other devices in the network. A service shall represent at least one function (saref:represents min 1 saref:Function) and is offered by at least one device that wants (a certain set of) its function(s) to be discoverable, registerable and remotely controllable by other devices in the network (saref:isOfferedBy min 1 saref:Device). Multiple devices can offer the same service. A service shall specify the device that is offering the service and the function(s) to be represented.
For example, a light switch can offer the service of remotely switching the lights in a home through mobile phone devices that are connected to the local network (saref:SwitchOnService class). This "remote switching" service represents the saref:OnOffFunction previously described.
Note that the concept of service is further elaborated in the oneM2M Base Ontology , to which the reader is referred in order to model the details of a service that are out of the scope of SAREF.
A device in SAREF can be further characterized by a profile. Figure 8 shows the saref:Profile class and its properties. A profile is a specification associated to a device to collect information about a certain property or commodity (e.g. energy or water) for optimizing its usage in the home/building in which the device is located. Therefore, a profile is linked to a certain property or commodity (using the saref:isAbout property), can be calculated over a time span (using the saref:hasTime property) and can be associated to some costs (using the saref:hasPrice property). A specialization of a profile is the Power Profile defined in the SAREF4ENER extension in ETSI TS 103 410-1 [i.2] (this power profile can be associated to a device for optimizing the energy efficiency in the home/building in which the device is located).
The classes saref:Measurement, saref:Property and saref:UnitOfMeasure allow to relate different measurements from a given device for different properties measured in different units, i.e. the saref:Measurement class describes a measurement of a physical quantity (using the saref:hasValue property) for a given saref:Property and according to a given saref:UnitOfMeasure. In this way, it is possible to differentiate between properties and the measurements made for such properties, and to store measurements for a concrete property in different units of measurement. Furthermore, a timestamp can be added (using the saref:hasTimestamp property) to identify when the measurement applies to the property, which can be used either for single measurements or for series of measurements (e.g. measurement streams). Figure 9 shows that a saref:Device can measure or control a saref:Property (which may be from a saref:FeatureOfInterest), which in turn relates to a saref:Measurement, which in turn is measured in a given saref:UnitOfMeasure. Note that it is possible to follow also the inverse direction in which a saref:Device makes a measurement in a certain unit of measure (using the saref:makesMeasurement property), and this measurement can be related to a saref:Property (using the saref:relatesToProperty property). A saref:FeatureOfInterest represents any real world entity from which a saref:Property is measured.
As an example, the saref:Power and saref:Energy classes can be related to a certain measurement value (using the saref:hasValue property), which is measured in a certain unit of measure i.e. Kilowatt for power (saref:PowerUnit) and Kilowatt_Hour for energy (saref:EnergyUnit). Analogously, the saref:Price class can be related to a certain measurement value that is measured using a certain saref:Currency, which is a subclass of the saref:UnitOfMeasure class. Further examples on how to define units of measure can be found in the different SAREF extensions ([i.2] to [i.7]).
The saref:Time class allows to specify the "time" concept in terms of temporal entities (i.e. instants or intervals) according to the existing W3C® Time ontology to avoid defining this concept from scratch.
The editors would like to thank the ETSI SmartM2M technical committee for providing guidance and expertise.
Also, many thanks to the ETSI staff and all other current and former active Participants of the ETSI SmartM2M group for their support, technical input and suggestions that led to improvements to this ontology.
Also, special thanks goes to the ETSI SmartM2M Technical Officer Guillemin Patrick for his help.
This documentation page was generated automatically using SPARQL-Generate, developed by Maxime Lefrançois. The SAREF public portal, the SAREF sources with continuous integration and deployment, the SAREF Pipeline software, and ETSI Technical Specification TS 103 673 v1.1.1 "SAREF Development Framework and Workflow, Streamlining the Development of SAREF and its Extensions", have been developed in the context of the ETSI STF 578, which followed the ETSI STF 556.