Skip to content

Instantly share code, notes, and snippets.

@KushagraKarira
Created June 26, 2022 17:55
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save KushagraKarira/cad8a96a2168c77f25ede56c18094291 to your computer and use it in GitHub Desktop.
Save KushagraKarira/cad8a96a2168c77f25ede56c18094291 to your computer and use it in GitHub Desktop.
Automate GNOME 2048 using Digispark Attiny85
#include "DigiKeyboard.h"
void setup() {
// don't need to set anything up to use DigiKeyboard
}
void loop() {
// this is generally not necessary but with some older systems it seems to
// prevent missing the first character after a delay:
DigiKeyboard.sendKeyStroke(0);
DigiKeyboard.sendKeyStroke(22);
DigiKeyboard.sendKeyStroke(4);
DigiKeyboard.sendKeyStroke(22);
DigiKeyboard.sendKeyStroke(7);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment