I purchased this RGB LED strip a while back, and created a custom ESP8266 controller for it using this code and the circuit diagram below. I used an IRLZ44N transistor a 220 Ohm resistor on each colour channel, with an L7805CV powering the ESP8266.
The issue I am facing is that any colours produced by the light strip are generally inaccurate (with the exception of red, green and blue). I am not sure whether this is due to the human eye's differing sensitivity red, green and blue light, or if it's something else — either way, I'm not sure how I can improve colour accuracy.
As an example, #FFA500, a colour which would display orange on any colour-accurate screen, appears yellow when emitted by the light strip.
JacobCXDev:
The issue I am facing is that any colours produced by the light strip are generally inaccurate (with the exception of red, green and blue). I am not sure whether this is due to the human eye's differing sensitivity red, green and blue light, or if it's something else — either way, I'm not sure how I can improve colour accuracy.
As an example, #FFA500, a colour which would display orange on any colour-accurate screen, appears yellow when emitted by the light strip.
Is there any remedy/solution for this?
#FFA500 is definitely orange. On a computer display. But your screen is not made of LEDs (unless you can afford an OLED screen). You can approximate you target color by adjusting the Red and Green values. But you will never get an exact match.
Try looking at the LEDS through a diffuser (a ping-pong ball is nice as a diffuser) and a few feet from your eyes.
SteveMann: #FFA500 is definitely orange. On a computer display. But your screen is not made of LEDs (unless you can afford an OLED screen). You can approximate you target color by adjusting the Red and Green values. But you will never get an exact match.
Try looking at the LEDS through a diffuser (a ping-pong ball is nice as a diffuser) and a few feet from your eyes.
Thanks for the advice — I do indeed have an OLED screen (my phone)!. Unfortunately, the diffuser hasn't seemed to affect the colour accuracy, meaning the colours are still way off what they should be. I've found that to achieve a colour which looks somewhat identical to #FFA500, I have to use close 100% red and much lower green. However, this is not a solution — I control my light strip via voice recognition (amongst other methods), meaning the colours I dictate are pre-defined hex codes which I cannot modify. It's because of this that I'd like to find an automated solution, where given any hex value it will reproduce an accurate replication of the colour.
JacobCXDev:
Thanks for the advice — I do indeed have an OLED screen (my phone)!. Unfortunately, the diffuser hasn't seemed to affect the colour accuracy, meaning the colours are still way off what they should be. I've found that to achieve a colour which looks somewhat identical to #FFA500, I have to use close 100% red and much lower green. However, this is not a solution — I control my light strip via voice recognition (amongst other methods), meaning the colours I dictate are pre-defined hex codes which I cannot modify. It's because of this that I'd like to find an automated solution, where given any hex value it will reproduce an accurate replication of the colour.
The diffuser won't change color accuracy, but it will help with the observation. You will need a lookup table to convert the perfect color, #FFA500 for orange, for example, to the actual color of the LEDs. From my limited experience, you will never get an exact match from any RGB LED.
The eye's perception of colour is very subjective. Try making brown light!
Could the cause be gamma correction? Are the devices you are comparing to corrected for gamma? The PWM outputs of the esp will not be. Gamma correction adjusts for the fact that the eye does not perceive brightness linearly.
Looking at your example #FFA500. That's 100% red, 65% green, 0% blue. But maybe that 65% is intended to mean perceived 65% of maximum rather than absolute 65% of maximum. Perceived 65% may correspond to a much lower actual/linear brightness, maybe 40~50%.
If I'm right, you maybe can take the hex values and correct them for gamma before setting the PWM duty cycle.
You have no capacitors on that regulator, while it might not be causing your problem you need to fix that before addressing your colour problem.
meaning the colours I dictate are pre-defined hex codes which I cannot modify.
But you can modify them at the Arduino end using either a map or lookup table.
By the way you will never get a good orange out of an RGB LED. If you want to play about with colours then attach three pots to three analogue inputs and use them to control the PWM value to each FET.
The thing about colours is that what we see depends not only on the composition of the three wavelengths of light but the background colour as well. There are many optical illusions that illustrate this if you search.