Hi:
I've been using the TM1637 7-segment, 4-digit display in the Uno. Now I run the same sketch in a Nano but there is a problem: there is no persistence, I mean, after turning the segments on, they quickly turn off, so I can barely see the digits blinking.
This is the sketch, and as you can see, there is a 1-second delay between displays of numbers 1111...9999:
#include <TM1637Display.h>
// Module connection pins (Digital Pins)
#define CLK 5
#define DIO 6
TM1637Display display(CLK, DIO);
int d = 0;
void setup()
{
display.setBrightness(7);
}
void loop() {
while (d<=9999)
{
display.showNumberDec(d);
delay(1000);
d = d + 1111;
}
d = 1111;
}
It works fine in the Uno, the digits remain bright for one second until the next digit is displayed, but in the Nano they turn on only for a fraction of a second, then off until the next digit is displayed.
I thought there was a problem in the +5V pin with it not having enough power to turn the segments on, but if I remove the delay(1000) line, they are (almost) always.
Is there any compatibility issue here? Needles to say I tried different pins for CLK and DIO to no avail. And this Nano works fine in my other projects.