Keyboard.h not found on Arduino Micro and v2 IDE beta

Hi @zersiax. The classic Arduino IDE comes with a collection of the most popular official libraries pre-installed. For this reason, we're used to having them always available, and many tutorials and documentation also make this assumption.

The Arduino IDE 2.x does not currently come with any libraries pre-installed. You must install any library your sketch requires.

Fortunately, this is very easy to do via Library Manager. Please do this:

  1. Select Sketch > Library > Manage Libraries... from the Arduino IDE's menus.
  2. In the "Filter your search..." field, type keyboard.
  3. Scroll down through the list of search results until you see "Keyboard by Arduino.
  4. Click the Install button.
  5. Wait for the installation to finish.

Now try compiling your sketch again.

1 Like