Page 221 - Programming the Photon Getting Started With the Internet of Things
P. 221

HIGH or LOW states, 69–70

           on relay shield, 114

        Syntax:

           arrays, 41


           Boolean variables, 36–37

           char types, 37–38

           coding best practices, 43

           commands, 38

           commenting code, 44–45

           floats, 35–36


           if statement, 38–39

           indentation in code, 43

           overview of, 31

           for statement, 39–40


           strings, 42–43

           summary, 45

           variables, 33–35

           what is programming, 31–33

           while statement, 40


           whitespaces in code, 45




        T

        Temperature sensors, reading, 101–105

        Thermostatic controls, 102


        Tinker:

           API requests, 18–19

           getting range of values for ambient light, 130

           overview of, 16

           reflashing Photon, 17

           running simultaneously with scripts, 19–21
   216   217   218   219   220   221   222   223   224