"Error compiling for board Arduino/Genuino Mega or Mega 2560."

Why are you using such an outdated version of the Arduino IDE?

If you update to a recent version your problem will be solved. You can download the Arduino IDE from:

1 Like