Greetings! I recently purchased and got this display up and running:
https://www.adafruit.com/products/438
Two questions are embedded below and denoted (1), and (2):
I have the display connected to an Arduino Uno, using the level shiftter provided to get to 3.3V. All is well there, and the 3.3V is also driving the Blue backlight LED. The demo code runs fine!
I am struggling with the contrast setting. As it runs now, (Adafruit library being used with Arduino IDE), the contrast is set to 0x18, and I can follow the code to see that that value is pushed to the 7565 controller in the ST765.cpp as shown here:
void ST7565::st7565_set_brightness(uint8_t val) {
st7565_command(CMD_SET_VOLUME_FIRST);
st7565_command(CMD_SET_VOLUME_SECOND | (val & 0x3f));
}
I have tried 0 to 255 as the "brightness" (actually... contrast from what I read) and I just can't get an improvement. The display content is their, but the best I can get is a dim view of it with the default 0x18. (1) Why am I not able to land a better contrast as I run through all of the possibilities? From reading the datasheet for the controller, the value is selectable between 0 and 63, so my numbers definitely take me through and beyond that range.
But the value I'm sending is AND'd with 0x3f before it is written to the register. (2) Why is that? Can I remove the & 0x3f and just use a "val" between 0 and 63?
Thanks in advance for your help.
Andy
EDIT:
I should also mention that I tried using 3.3V from a bench supply to drive the LED backlight just to make sure the 3.2V the Arduino was supplying was sufficient. It appears sufficient in both cases. However, the red LED barely turns on, but the blue and green seem to work OK. Overall, I'm wondering if this is a backlight problem because the display just isn't nearly as bright as it appears in other peoples videos and pictures. The outer border should be fairly bright regardless of the contrast setting in the main area of the display, shouldn't it?

