WEEK 4: Time Machines
I found this amazing YouTube video that walked me through setting it up. The code was simple enough - the only weird thing was this chart of how to program different characters:
I didn’t realize I wouldn’t be able to write any letter I wanted (I wanted to write my name...).
I didn’t get far enough to incorporate an element of time passing, but I like working with this component and might try to use it in my midterm project.
10:04, the time I worked on this homework
A b C d
I realized that the reason that some of the letters are uppercase vs lowercase is because they can’t be made the other way around - like a capitol letter “D” would look just like a zero. But why is the “C” uppercase?
Code:
#include <TM1637.h>
int CLK = 2;int DIO = 3;
TM1637 tm(CLK, DIO);
void setup() {
tm.init();}
//setting brightness
tm.set(2);
void loop() {
//tm.display(position,character);}
//first digit/character
tm.display(0, 10);
//second digit/character
tm.display(1, 11);
//display the colon
tm.point(1);
//third digit/character
tm.display(2, 12);
//fourth digit/character
tm.display(3, 13);
Sources:
TM1637 Digit Display - Arduino Quick Tutorial
How to use the TM1637 Digit Display with an Arduino (Quick Tutorial)