Hello Everybody
I'm completely new to electronics so I apologize for my newbie way of explaining what I try to do.
I want to build an IR transmitter with three pods that can remote control 3 LEDs for color mixing.
So far, I have figured out on how to have the pots control the intensity of each LED, but even after
a good amount of re-search, I can't figure out on how to send the value that I'm reading of the pots
over an IR signal to the LEDs.
I use this code to get the desired brightness value from the pots:
RVal = analogRead(RLed) / 4;
GVal = analogRead(GLed) / 4;
BVal = analogRead(BLed) / 4;
//gives me a value between 0-255 for each of the three LEDs
My problem no is how to send these values over an IR signal.
I found out on how to pulse the IR signal etc. but I just can't figure
out an easy way to just transmit three bytes of data.
Once the three values are transmitted, I should be able to adjust the LEDs with this code:
analogWrite(ROut, RVal);
analogWrite(GOut, GVal);
analogWrite(BOut, BVal);
Am I generally on the right track, or is there a better way to do it? Any chance somebody can give me some input on how to write the code for this
or direct me to some literature/website that might be helpful? I would really appreciate it
(PS: Sorry for my English, it's not my native tongue)