can you walk me through how to accomplish this?
For $100/hour, yes.
It isn't rocket science. Look at the stupid function that you have. See where it gets (and prints) the temperature? Instead of printing the temperature, return it. Of course, you need to change the function return type, too.