Onewire Temperature Sensor

Wattmon lets you connect onewire DS18B20 temperature sensors which can be either purchased from us or from any third party. This guide explains how to connect and configure them.

Configuring Onewire Sensors with the RJ45 Cable

Onewire sensors can be plugged directly into the master module's device port or to either of the ports in any of the devices such as C752. The first step will be to make a network cable if you do not already have one ready. The following diagram, Fig. 1, shows the connections for making a network cable. The RJ45 cable's outer gray jacket will need to be stripped to expose the eight colored wires inside. Arrange the wires so that they lay brown/white, white/brown, green/white, white/blue, blue/white, white/green, orange/white, and white/orange (as shown in Fig. 1). With the wires laying flat and parallel, cut off any excess ends so that all of the wires are of the same length. Insert the wires into the RJ45 plug with the brown/white wire being the top when the tab is on the back. Crimp the plug.

Fig. 1: RJ45 Plug Colour Code

Connect your onewire temperature's wires to the RJ45 wires. The typical colour code for the 5V, data, and ground of onewire temperature sensors can be seen below in Fig. 2.

Fig. 2: Onewire Temperature Sensor Wire Configuration

The 5V wire (typically red) will correspond to the brown/white and white/brown wires of the RJ45 wire. The data wire will correspond to the green/white wire of the RJ45 cable. The ground wire (typically black) will correspond to the orange/white and white/orange wires of the RJ45 cable. A

2.2 kiloOhm to 4.7 kiloOhm resistor will need to be placed with one end connected to the 5V wire and the other end connected to the data wire. This setup can be seen below in Fig. 3.

Fig. 3: Onewire and RJ45 Connections

Configuring Wattmon Online Portal for Onewire Devices

Once the wiring is set up, you can go online to your Wattmon portal to configure the rest of the device and check to see the sensor's recordings. Open your Wattmon portal, go to Control Panel, and then Onewire Settings. Click the blue “Scan” button near the top right. The onewire temperature sensor device should appear like in Figure 4 below (Right click & view image to see a larger picture of the figure).

Fig. 4: Completed Scan

To edit the settings of the device, click on “Action” and then “Configure” from the drop down tab. This will lead to the Configure Onewire page, shown in Figure 5, where you can name the device and assign specific roles to each temperature sensor.

Fig. 5: Configure Onewire

In this case, there is only one temperature sensor with this onewire device. In other cases, there may be five sensors corresponding to a onewire device, and all of these would be listed in the Configure Roles section.

A role can be assigned to each temperature sensor in the Configure Roles section. There should already be three temperature roles defined by default (can be found listed in Roles), and these will appear in the drop down tab of the Configure Roles section. If this is not the case, a temperature role can be created by going to the Control Panel,Roles, and “Add Role.” Be sure to assign the role to “Onewire: Device” in the Role Type section.

To have the temperature data recorded, go to Control Panel and then Data Collection. A list containing a group “KwH Log” should appear as in Figure 6.

Fig. 6 Data Collection

Click on “Action” and then “Edit.” This should lead to a page with a list of data points that are currently being recorded in regards to your Wattmon device. Click on the “Add” button. A new data point will appear at the bottom of the list. To specify this as the temperature sensor, choose “Device Variable” for the Value Type, “Temp 1” (or whatever role you specified for the first temperature sensor) for the Value, “*1” for the Scale, and “Max” for the Function just as it appears in Figure 7 below, and then click the “Add” button near the top right. Repeat this for however many temperature sensors you will be using.

Fig. 7: Adding Temperature to Data Collection

To have the temperature sensor data appear on the dashboard, go to the Control Panel and then Widgets. Click on the “Add Widget” button near the top right. A widget for variables will need to be created like in Figure 8.

Fig. 8: Variables Widget

Next, to have the temperature role and the current reading visible in the Variables widget, go to the Control Panel and then Roles. Edit the roles that have been assigned to the temperature sensor(s) so that the Display on dashboard reads “Yes” as in Figure 9. Repeat this for however many temperature sensors you are using.

Figure 9: Configuring Role: Temp 1

This should allow the temperature sensor to appear in the Variables widget on the dashboard as in Figure 10.