Commit | Line | Data |
---|---|---|
cad05b18 H |
1 | /* |
2 | * Arduino IR-Jammer | |
3 | * <~~Harvie 2oo8 | |
4 | * | |
5 | * You can look for couple of old TV remote controlls | |
6 | * to extract some IR LEDs... | |
7 | * | |
8 | * Each TV should have LED of specific "color" | |
9 | * (even you can't see it). So its better to connect | |
10 | * more LEDs with different light frequency (color). | |
11 | * Specialy if jammer is working only from small distance. | |
12 | * | |
13 | */ | |
14 | ||
15 | #define ledpin 13 | |
16 | //Maybe you will have to experiment also with this value | |
17 | int bitlen = 5; | |
a3a3e374 H |
18 | int d; |
19 | float i; | |
cad05b18 H |
20 | |
21 | void setup() { | |
22 | pinMode(ledpin, OUTPUT); | |
23 | } | |
24 | ||
25 | void loop() { | |
26 | for(d=1000/100;d<=1000/20;d++) { // 1000/frequency in kHz | |
27 | //You maybe have to experiment with ^^^ this ^^^ values | |
28 | //Frequency sweeping: 100->20 kHz works, i saw 60->1 too | |
a3a3e374 | 29 | for(i=0;i<bitlen;i+=0.5) { |
cad05b18 H |
30 | digitalWrite(ledpin, HIGH); delayMicroseconds(d/2); |
31 | digitalWrite(ledpin, LOW ); delayMicroseconds(d/2); | |
32 | } | |
33 | delayMicroseconds(d*bitlen); | |
34 | } | |
35 | } | |
36 |