I just finished my Arduino Uno clock and everything works as it should. I ended up installing the LDR on the rear side of the case to keep the front clean and simple. This is causing the maximum LDR reading to be about 750 in a bright room (instead of 999). I see how I can adjust the low minimum dimness, and I was wondering if there was a way to change the LDR point at which the tubes reached their maximum brightness. In other words, if the dim level is linear between 100 and 999, can I change the maximum brightness point such that the dim curve is linear between 100 and, say 750, then maintain maximum brightness between 750 and 999? I'm comfortable modifying the firmware if someone can point me to the relevant section and values?
Hi. I just finished building my Uno clock and everything works as it should. I ended up putting the LDR on the back side of the case. On full brightness, it's only registering about 750 (instead of 999). Is there a way for me to adjust the firmware to have the tubes reach maximum brightness at a lower LDR value?
Also, where in the firmware should I look to adjust the lowest LED setting / brightness. I'd like a very soft glow, but even at a setting of "1" it's still a bit too bright.
If you change the SENSOR_HIGH_DEFAULT value to something lower, you can adjust the sensitivity. Note that the value is persisted to EEPROM, so you need to factory reset to make it pick up a changed value.
I tried dividing them by 8 (arbitrary number) as noted above to get the result scaled down a bit. I didn't work as I had hoped. It seems as if there's a minimum threshold to have the LEDs illuminate, and that threshold was crossed as the "dimFactor" was adjusted. So, with a LDR reading of ~500+, the LED backlights would be on, and under ~500, the LEDs would turn off. I can see a use for this, so I may leave it set this way for a bit.
Thanks again for the quick reply! Here are some pictures of my build...
So, there is going to be a minimum you can run the LEDs at - you can easily see the steps when they are very low. The back light curve is probably needs to be more "exponential" than it is, so the steps are closer together at the very low end.
The other option is to cover the LED with some light diffusing or reducing layer. You might have more luck "going physical" on it. I'm thinking like a partially transparent plastic covering.
Thanks. I'll see if I can find a suitable material or method. Either a transparent covering as you mention, or perhaps a "lens" of sorts. Perhaps a thicker opaque material with a pin-hole allowing just a small amount of light through? Thanks again for the help. It was a fun project.