Changed state[1-5] to floats for accuracy when reading from ananalog inputs.
Added functions to populate an array with flame sensor values, and get the direction of the flame.
Added comments