-
-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Eric
committed
Jan 14, 2021
1 parent
037583a
commit f93b8f7
Showing
4 changed files
with
43 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
38 changes: 38 additions & 0 deletions
38
examples/DEMO_Generating_Random_Key_Non_FreeRTOS/DEMO_Generating_Random_Key_Non_FreeRTOS.ino
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
#include <TFT_eSPI.h> | ||
#include <SPI.h> | ||
#include <DigitalRainAnim.h> | ||
TFT_eSPI tft = TFT_eSPI(); | ||
|
||
DigitalRainAnim digitalRainAnim = DigitalRainAnim(); | ||
|
||
void setup() | ||
{ | ||
Serial.begin(115200); | ||
tft.begin(); | ||
tft.setRotation(0); | ||
tft.fillScreen(TFT_BLACK); | ||
digitalRainAnim.init(&tft); | ||
} | ||
|
||
void loop() | ||
{ | ||
digitalRainAnim.loop(); | ||
|
||
while(Serial.available() > 0 ){ | ||
String str = Serial.readString(); | ||
if(str.indexOf("send") > -1){ | ||
keyMode(); | ||
}else{ | ||
normalMode(); | ||
} | ||
} | ||
} | ||
|
||
void keyMode(){ | ||
String newKey = digitalRainAnim.getKey(0).c_str(); | ||
Serial.println(newKey); | ||
} | ||
|
||
void normalMode(){ | ||
digitalRainAnim.resetKey(); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
name=Digital Rain Animation for TFT_eSPI | ||
version=1.1.0 | ||
version=1.1.1 | ||
author=Eric Nam | ||
maintainer=Eric Nam <[email protected]> | ||
sentence=A library that represents Digital Rain Animation on color displays that support TFT_eSPI | ||
|