nyni je funkce
[mirrors/Programs.git] / arduino / TV_B_Gone / TV_B_Gone.pde
CommitLineData
cad05b18 1/*
a3a3e374 2 * Arduino TV-B-GONE
cad05b18
H
3 * <~~Harvie 2oo8
4 *
a3a3e374
H
5 * THX 2 Ladyada
6 * http://www.ladyada.net/make/tvbgone/
cad05b18
H
7 *
8 */
9
a3a3e374
H
10//#include "NAcodes.c"
11//#include "NAcodes2.c"
cad05b18
H
12#define ledpin 13
13//Maybe you will have to experiment also with this value
a3a3e374
H
14int d;
15float i;
16
17void fire_code(int outpin, long freq, fuck *code) { //kHz
18 freq = 1000000/(freq*1000); //freq2millis
19 for()
20}
cad05b18
H
21
22void setup() {
23 pinMode(ledpin, OUTPUT);
24}
25
26void loop() {
27 for(d=1000/100;d<=1000/20;d++) { // 1000/frequency in kHz
28 //You maybe have to experiment with ^^^ this ^^^ values
29 //Frequency sweeping: 100->20 kHz works, i saw 60->1 too
a3a3e374 30 for(i=0;i<bitlen;i+=0.5) {
cad05b18
H
31 digitalWrite(ledpin, HIGH); delayMicroseconds(d/2);
32 digitalWrite(ledpin, LOW ); delayMicroseconds(d/2);
33 }
34 delayMicroseconds(d*bitlen);
35 }
36}
37
This page took 0.192749 seconds and 4 git commands to generate.