Skip to content

Commit

Permalink
Include changes from upstream
Browse files Browse the repository at this point in the history
  • Loading branch information
KenwoodFox committed Nov 6, 2023
1 parent 44cfcda commit 277da44
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions Firmware/src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@
// Objects
Encoder lEnc(LENCA, LENCB);
Algorithm alg;
shiftDisplay disp = shiftDisplay(DIN_PIN, CLK_PIN, LAT_PIN);
shiftDisplay num = shiftDisplay(DIN_PIN, CLK_PIN, LAT_PIN); // Position 0 (furthest from chain)
shiftDisplay lamps = shiftDisplay(DIN_PIN, CLK_PIN, LAT_PIN); // Position 1 (closest)

void setup(void)
{
Expand All @@ -30,8 +31,9 @@ void setup(void)
// Ready up fresh algorithm!
alg.init();

// Initalize display
disp.begin();
// Initalize displays and lights
num.begin();
lamps.begin();

// Pins
pinMode(LED_BUILTIN, OUTPUT);
Expand All @@ -52,4 +54,8 @@ void loop()

analogWrite(LMOT1, 120);
analogWrite(LMOT2, 0);

num.setDecimal(millis() % 1000 > 500);
num.setDigit(l_BLANK);
lamps.setDigit(0b00000001);
}

0 comments on commit 277da44

Please sign in to comment.