Problem adjusting code to work with Arduino 1.0