Minor bug fixing to become compatible with new virsions of Arduino IDE