Temperature Logging Project with mc-Things
In This video we go through a Temperature Logging use-case.
Use the following code to create a script that will log the temperature from the location of the mc-Module and relay that information back through your IFTTT recipe:
Class TempSETUP
Shared Event checktemp() RaiseEvent Every 30 Seconds
Dim temp As Float = Temperature.GetTemp ()
Dim tempstring As String = temp.ToString()
Lplan.IFTTT("YOURUNIQUEIFTTTKEY", "TRIGGEREVENTNAME", tempstring, "", "")
End Event
End Class
Keep in mind you need to setup your own IFTTT account, and enter your own unique IFTTT key into the above code. You will also need to remember to add the ‘Temperature’ library to your script to make sure the script understands the variables you are trying to measure. The video provides additional details and a walk-through.