-
Notifications
You must be signed in to change notification settings - Fork 0
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
Lohni
committed
Mar 27, 2022
1 parent
2ed03a8
commit b36cfeb
Showing
4 changed files
with
52 additions
and
19 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
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
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,11 +1,27 @@ | ||
import MatrixSocket | ||
import LedMain | ||
import uasyncio | ||
import _thread | ||
import time | ||
|
||
from LEDUtils import LEDUtils | ||
|
||
sLock = _thread.allocate_lock() | ||
|
||
# load wlan config | ||
matrixSocket = MatrixSocket.MatrixSocket() | ||
main = LedMain.LedMain(matrixSocket) | ||
|
||
def animateMatrixThread(): | ||
while True: | ||
main.ledUtil.animateTxt() | ||
time.sleep_ms(50) | ||
|
||
_thread.start_new_thread(animateMatrixThread, ()) | ||
|
||
while True: | ||
sLock.acquire() | ||
main.run() | ||
time.sleep_ms(1000) | ||
sLock.release() | ||
time.sleep(1) | ||
|