Use case: Temperature range with e-mail message

Brief description


This use case is aimed to provide both a sample of the “IF Then” and the “Email” plugin modules application. We are going to configure the delivery of an e-mail message for all the times the temperature is lower and higher than a certain range. This will be possible thanks to the configuration of a logic that defines when this condition does occur.

Download


Download .eve project

To allow a better comprehension of the following use case, we provide the .eve project sample.

After the download is completed, open the file on EVE Manager software and follow all the steps below keeping an eye to the sample.

If you are up to test the sample project on a real installation, remember to update EVE firmware and EVE Manager software to the latest version.

Also, remember to download and install EVE Logic before uploading project to the server.

Process


N.1 Info component to get the real temperature information

First of all we need to include an Info component within the .eve project and configure it with the right gateway.

N.2 Switch components to be used as triggers for the e-mail messages delivery

We need to include two Switch components within the .eve project. Both of them should be configured with the EVE Ghost gateway.
Once added, we could proceed configuring the IF Then components for the e-mail messages delivery.

N.2 IF Then components to set two different conditions: when temperature is < 18 °C and > 28 °C

We need to include two IF Then components within the .eve project. Now we need to configure them as follow:

1. When temperature is lower than 18 °C:

  • IF the Info component (temperature reader) is lower than 18
  • THEN set Switch 1 component to value 1
  • ELSE set Switch 1 component to value 0.

2. When temperature is greater than 28 °C:

  • IF the Info component (temperature reader) is greater than 28
  • THEN set Switch 2 component to value 1
  • ELSE set Switch 2 component to value 0.

 

N.1 Email Account component to configure the server

We need to include an Email Account component within the .eve project to define the server for the messages delivery.

N.1 Contact component as recipient of your e-mail message

We need to include also a Contact component within the .eve project. This will be the receiver of the e-mail messages.

N.2 Email components to set two different e-mail messages depending on the two different conditions

We need to include two Email components within the .eve project. Now we need to configure them as follow:

1. When temperature is lower than 18 °C:

  • TRIGGER COMPONENT: Switch 1 component
  • SEND WHEN: Trigger changes from Off to On (from 0 to 1)
  • TO: Contact component
  • SUBJECT: Temperature alarm
  • INFORMATION (#1): Info component
  • CONTENT: The temperature is lower than the limit. Temp.: #1

2. When temperature is greater than 28 °C:

  • TRIGGER COMPONENT: Switch 2 component
  • SEND WHEN: Trigger changes from Off to On (from 0 to 1)
  • TO: Contact component
  • SUBJECT: Temperature alarm
  • INFORMATION (#1): Info component
  • CONTENT: The temperature is higher than the limit. Temp.: #1