Error when combining two simple sketches - range sensors and photocells