Announcement

Collapse
No announcement yet.

Celsius to Fahrenheit conversion

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Celsius to Fahrenheit conversion

    Does anyone know a quick way to script this? I'd perfer to build it right into the HS script right now I have an AutoIT script doing it.


    Thanks in advance for any help


    Tim

    #2
    Tf = ((9/5)*Tc)+32

    -Dave

    Comment


      #3
      I know the formula.
      What I'm looking for is, what is the easiest wAY to script it in a HS script.

      I just need to know how tO do floating point math in HS scripts.

      Sorry about the confusion


      Thanks
      Tim

      Comment


        #4
        function TempCtoF(ftemp)
        TempCtoF = (ftemp-32) * 9 / 5
        end function

        function TempFtoC(ctemp)
        TempFtoC = ctemp * 5 / 9 + 32
        end function

        Nucleus Home Automation
        News, support, and updates for Rover, Network Monitor, TimeIcons, and more

        Comment

        Working...
        X