Updated to work with Leonardo Arduino board