Add files via upload

This commit is contained in:
zarpli
2022-05-11 21:54:48 -05:00
committed by GitHub
parent 68924861ae
commit e07b484f0d
5 changed files with 305 additions and 0 deletions

45
examples/basic/basic.ino Normal file
View File

@@ -0,0 +1,45 @@
/*
Zarpli - Tecnología Interactiva
12112021 Alejandro Zárate
https://github.com/zarpli/BrightSign/
DESCRIPTION
====================
Simple example of the BrightSign library that play a media file
and wait for it to finish to run again.
The BSuControl Script must be installed in the BrightSign unit
memory unit and must be connected to the Serial1 port.
https://github.com/zarpli/BSuControl/
Media Files for Testing
https://github.com/zarpli/Media/
*/
#include <BrightSign.h>
// Instantiate a BrightSign object and Attach to Serial1
BrightSign BS(Serial1);
void setup(){
// Enable debug msg over Serial
BS.debug();
Serial.begin(9600);
while(!Serial);
Serial.println("Waiting BrightSign Power-Up");
while(!BS.online())BS.update();
//Set Volume to 20%
BS.volume(20);
}
void loop(){
// Update the BrightSign instance
BS.update();
if(BS.media_ended()) BS.play("AUDIO.M4A");
}