Skip to content

Instantly share code, notes, and snippets.

@AlexanderKozhevin
Created October 15, 2021 18:51
Show Gist options
  • Save AlexanderKozhevin/55b06c1f4b766313ad693d238df7aa64 to your computer and use it in GitHub Desktop.
Save AlexanderKozhevin/55b06c1f4b766313ad693d238df7aa64 to your computer and use it in GitHub Desktop.
#include <TM1637Display.h>
const int CLK = D6; //Set the CLK pin connection to the display
const int DIO = D5; //Set the DIO pin connection to the display
int numCounter = 0;
TM1637Display display(CLK, DIO); //set up the 4-Digit Display.
void setup() {
// put your setup code here, to run once:
display.setBrightness(0x0a);
}
void loop() {
// put your main code here, to run repeatedly:
for(numCounter = 0; numCounter < 1000; numCounter++) //Iterate numCounter
{
display.showNumberDec(numCounter); //Display the numCounter value;
delay(1000);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment