-
Notifications
You must be signed in to change notification settings - Fork 0
/
windows_prank.ino
72 lines (67 loc) · 2.21 KB
/
windows_prank.ino
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
#include "DigiKeyboard.h"
int led = 0; // Change to pin 1 for MODEL A
int on_wait = 1000; // How long to toggle CAPS LOCK for.
int off_wait = 5000; // Delay between toggles.
void setup() {
DigiKeyboard.sendKeyStroke(0);
DigiKeyboard.delay(500);
DigiKeyboard.sendKeyStroke(KEY_D, MOD_GUI_LEFT);
DigiKeyboard.delay(500);
DigiKeyboard.sendKeyStroke(70, MOD_ALT_LEFT);
DigiKeyboard.delay(500);
DigiKeyboard.sendKeyStroke(KEY_R, MOD_GUI_LEFT);
DigiKeyboard.delay(500);
DigiKeyboard.print("mspaint");
DigiKeyboard.sendKeyStroke(KEY_ENTER);
DigiKeyboard.delay(800);
DigiKeyboard.sendKeyStroke(KEY_V, MOD_CONTROL_LEFT);
DigiKeyboard.delay(500);
DigiKeyboard.sendKeyStroke(KEY_S, MOD_CONTROL_LEFT);
DigiKeyboard.delay(600);
DigiKeyboard.print("%USERPROFILE%\\wall.jpg");
DigiKeyboard.sendKeyStroke(KEY_ENTER);
DigiKeyboard.delay(600);
DigiKeyboard.sendKeyStroke(KEY_F, MOD_ALT_LEFT);
DigiKeyboard.delay(500);
DigiKeyboard.sendKeyStroke(KEY_K);
DigiKeyboard.delay(500);
DigiKeyboard.sendKeyStroke(KEY_F);
DigiKeyboard.delay(500);
DigiKeyboard.sendKeyStroke(KEY_F, MOD_ALT_LEFT);
DigiKeyboard.delay(500);
DigiKeyboard.sendKeyStroke(KEY_X);
DigiKeyboard.delay(600);
DigiKeyboard.sendKeyStroke(KEY_D, MOD_GUI_LEFT);
DigiKeyboard.delay(500);
DigiKeyboard.sendKeyStroke(KEY_F10, MOD_SHIFT_LEFT);
DigiKeyboard.delay(500);
DigiKeyboard.sendKeyStroke(KEY_V);
DigiKeyboard.delay(200);
DigiKeyboard.sendKeyStroke(81);
DigiKeyboard.delay(200);
DigiKeyboard.sendKeyStroke(81);
DigiKeyboard.delay(200);
DigiKeyboard.sendKeyStroke(81);
DigiKeyboard.delay(200);
DigiKeyboard.sendKeyStroke(81);
DigiKeyboard.delay(200);
DigiKeyboard.sendKeyStroke(81);
DigiKeyboard.sendKeyStroke(KEY_ENTER);
DigiKeyboard.delay(5000);
DigiKeyboard.sendKeyStroke(KEY_R, MOD_GUI_LEFT);
DigiKeyboard.delay(3000);
DigiKeyboard.print("http://fakeupdate.net/win10u/index.html");
DigiKeyboard.sendKeyStroke(KEY_ENTER);
DigiKeyboard.delay(2000);
DigiKeyboard.sendKeyStroke(KEY_F11);
pinMode(led, OUTPUT);
DigiKeyboard.update();
}
void loop() {
DigiKeyboard.sendKeyStroke(57);
digitalWrite(led, 1);
delay(on_wait);
DigiKeyboard.sendKeyStroke(57);
digitalWrite(led, 0);
delay(off_wait);
}