New to Arduino, help with ' 1-Wire'

Hello, I am using an Arduino Uno for a school project, and have only begun to learn how to program it.
I am using this temperature sensor to gain temperature data. The sensor uses a special library and I have no idea how to access the readings from the device. I would greatly appreciate any help with getting the reading into a variable so I can work with it in my if statements. I will attach my code.

If you are curious, the project will modulate the power to a water pump (or just use a relay for binary control) to maintain a desired water temperature. the water is being used to cool industrial parts. I understand the code may be inefficient, but I am not here to fix the code itself, I’m just trying to get a better understanding of how to read digital thermometers.

Thanks in advance,


EDIT: If you can point me to a tutorial on this, that would be cool as well, I just havent managed to find one.

Draft_of_complete_code_1.1.ino (2.92 KB)

You should post your code (between code tags). Attaching it to your post means that people need to download it and create a folder before they can see it in their IDE.

Code tags are generated using the </> button in the IDE, or can be manually typed like this:-

[code]Paste your code here[/code]
It will appear in a block like this

Regarding a tutorial, there’s a link to one at the bottom of the product page that you linked:- Bildr tutorial

Edit: Also, here’s a link to the Dallas Temperature Control Library page. It has more info, and an example.