cgarcia2097 / 4-Square

Repository for 4-Square PCB
MIT License
0 stars 0 forks source link

Keyboard.h missing? #1

Open DongerZone opened 5 years ago

DongerZone commented 5 years ago

I'm trying to upload the test code to my pro micro, and I'm getting this error

Arduino: 1.8.8 (Mac OS X), Board: "Arduino Pro or Pro Mini, ATmega328P (5V, 16 MHz)"

Build options changed, rebuilding all
/Users/kieran/Documents/Arduino/sketch_mar28a/sketch_mar28a.ino: In function 'void setup()':
sketch_mar28a:78:3: error: 'Keyboard' not found. Does your sketch include the line '#include <Keyboard.h>'?
   Keyboard.begin();  
   ^
/Users/kieran/Documents/Arduino/sketch_mar28a/sketch_mar28a.ino: In function 'void loop()':
sketch_mar28a:114:9: error: 'Keyboard' not found. Does your sketch include the line '#include <Keyboard.h>'?
         Keyboard.press(macros[i*KEYROWS + j]);
         ^
sketch_mar28a:117:9: error: 'Keyboard' not found. Does your sketch include the line '#include <Keyboard.h>'?
         Keyboard.release(macros[i*KEYROWS + j]);     
         ^
exit status 1
'Keyboard' not found. Does your sketch include the line '#include <Keyboard.h>'?

This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.
DongerZone commented 5 years ago

Figured out the problem, should probably add an instruction set to your README with instructions regarding the pro micro. It's not too easy finding it online.

Solved by adding the sparkfun boards to the board manager, and selecting the Pro Micro (with 5V processor but ymmv)

DongerZone commented 5 years ago

If your board isn't being recognized, plug in your boards usb, hit upload code. When the editor says it is uploading, pull the RST pin to GND twice very quickly to reset the bootloader.

cgarcia2097 commented 5 years ago

Noted. I will add a README when time allows.