diff --git a/JukeBox.ino b/JukeBox.ino new file mode 100644 index 0000000..7308903 --- /dev/null +++ b/JukeBox.ino @@ -0,0 +1,296 @@ +#include +#include +#include +#include +#include + +//DFPlayer Mini +SoftwareSerial mySoftwareSerial(2, 3); // RX, TX +uint16_t numTracksInFolder; +uint16_t track; + +struct StoredCard { + byte id[4]; + int folder; + byte mode; + byte reserved1; // Um in Zukunft noch weitere Optionen + byte reserved2; // konfigurieren zu können + byte reserved3; // reservieren wir einfach mal ein paar Integer +}; + +StoredCard myCard; +static void nextTrack(); +bool foundCard = false; + +// implement a notification class, +// its member methods will get called +// +class Mp3Notify +{ + public: + static void OnError(uint16_t errorCode) + { + // see DfMp3_Error for code meaning + Serial.println(); + Serial.print("Com Error "); + Serial.println(errorCode); + } + static void OnPlayFinished(uint16_t track) + { + Serial.print("Track beendet"); + Serial.println(track); + delay(100); + nextTrack(); + } + static void OnCardOnline(uint16_t code) + { + Serial.println(F("SD Karte online ")); + } + static void OnCardInserted(uint16_t code) + { + Serial.println(F("SD Karte bereit ")); + } + static void OnCardRemoved(uint16_t code) + { + Serial.println(F("SD Karte entfernt ")); + } +}; + +static DFMiniMp3 mp3(mySoftwareSerial); + +// Leider kann das Modul keine Queue abspielen. +static void nextTrack() { + if (foundCard == false) + // Wenn eine neue Karte angelernt wird soll das Ende eines Tracks nicht verarbeitet werden + return; + + if (myCard.mode == 1) + { + Serial.println(F("Hörspielmodus ist aktiv -> Strom sparen")); + mp3.sleep(); + } + if (myCard.mode == 2) + { + Serial.println(F("Albummodus ist aktiv -> nächster Track")); + if (track != numTracksInFolder) { + track = track + 1; + mp3.playFolderTrack(myCard.folder, track); + } else + mp3.sleep(); + } + if (myCard.mode == 3) + { + Serial.println(F("Party Modus ist aktiv -> zufälligen Track spielen")); + track = random(1, numTracksInFolder + 1); + mp3.playFolderTrack(myCard.folder, track); + } +} + +// MFRC522 +#define RST_PIN 9 // Configurable, see typical pin layout above +#define SS_PIN 10 // Configurable, see typical pin layout above +MFRC522 mfrc522(SS_PIN, RST_PIN); // Create MFRC522 +uint8_t successRead; +byte readCard[4]; // Stores scanned ID read from RFID Module + +const int buttonPause = A0; +const int buttonUp = A1; +const int buttonDown = A2; + +uint8_t numberOfCards = 0; + +void setup() { + + Serial.begin(115200); // Es gibt ein paar Debug Ausgaben über die serielle Schnittstelle + randomSeed(analogRead(A0)); // Zufallsgenerator initialisieren + + Serial.println(F("DIY NFC JUKEBOX")); + Serial.println(F("BY THORSTEN VOß")); + + // Knöpfe mit PullUp + pinMode(buttonPause, INPUT_PULLUP); + pinMode(buttonUp, INPUT_PULLUP); + pinMode(buttonDown, INPUT_PULLUP); + + // NFC Leser initialisieren + SPI.begin(); // Init SPI bus + mfrc522.PCD_Init(); // Init MFRC522 + mfrc522.PCD_DumpVersionToSerial(); // Show details of PCD - MFRC522 Card Reader + + // DFPlayer Mini initialisieren + mp3.begin(); + mp3.reset(); + mp3.setVolume(10); + + // RESET --- ALLE DREI KNÖPFE BEIM STARTEN GEDRÜCKT HALTEN -> alle bekannten Karten werden gelöscht + if (digitalRead(buttonPause) == LOW && digitalRead(buttonUp) == LOW && digitalRead(buttonDown) == LOW) { + Serial.println(F("Reset -> EEPROM wird gelöscht")); + for (int i = 0 ; i < EEPROM.length() ; i++) { + EEPROM.write(i, 0); + } + } + + // Anzahl bekannter Karten auslesen + numberOfCards = EEPROM.read(0); +} + +void loop() { + do { + successRead = getID(); + mp3.loop(); + + if (digitalRead(buttonPause) == LOW) { + Serial.println(F("Play/Pause")); + + if (mp3.getStatus() == 513) + mp3.pause(); + else + mp3.start(); + + delay(500); + } + if (digitalRead(buttonUp) == LOW) { + Serial.println(F("Volume Up")); + mp3.increaseVolume(); + } + if (digitalRead(buttonDown) == LOW) { + Serial.println(F("Volume Down")); + mp3.decreaseVolume(); + } + + } + while (!successRead); + + foundCard = false; + + for (int x = 0; x < numberOfCards; x++) { + EEPROM.get(sizeof(StoredCard) * x + sizeof(int), myCard); + if (checkTwo(readCard, myCard.id)) + { + foundCard = true; + numTracksInFolder = mp3.getFolderTrackCount(myCard.folder); + + // Hörspielmodus: eine zufällige Datei aus dem Ordner + if (myCard.mode == 1) { + Serial.println(F("Hörspielmodus -> zufälligen Track wiedergeben")); + track = random(1, numTracksInFolder + 1); + Serial.println(track); + mp3.playFolderTrack(myCard.folder, track); + } + // Album Modus: kompletten Ordner spielen + if (myCard.mode == 2) { + Serial.println(F("Album Modus -> kompletten Ordner wiedergeben")); + track = 1; + mp3.playFolderTrack(myCard.folder, track); + } + // Party Modus: Ordner in zufälliger Reihenfolge + if (myCard.mode == 3) { + Serial.println(F("Party Modus -> Ordner in zufälliger Reihenfolge wiedergeben")); + track = random(1, numTracksInFolder + 1); + mp3.playFolderTrack(myCard.folder, track); + } + break; + } + } + + // Neue Karte konfigurieren + if (foundCard == false) { + Serial.print(F("Neue Karte konfigurieren")); + + for (int i = 0; i < 4; i++) + myCard.id[i] = readCard[i]; + + myCard.folder = 0; + myCard.mode = 0; + bool done = false; + mp3.playMp3FolderTrack(100); + do { + if (digitalRead(buttonPause) == LOW) { + done = true; + delay(1000); + } + if (digitalRead(buttonUp) == LOW) { + myCard.folder = min(myCard.folder + 1, 99); + //mp3.playMp3FolderTrack(myCard.folder); + mp3.playFolderTrack(myCard.folder, 1); + delay(1000); + } + if (digitalRead(buttonDown) == LOW) { + myCard.folder = max(myCard.folder - 1, 1); + //mp3.playMp3FolderTrack(myCard.folder); + mp3.playFolderTrack(myCard.folder, 1); + delay(1000); + } + } + while (done == false); + + done = false; + mp3.playMp3FolderTrack(101); + do { + if (digitalRead(buttonPause) == LOW) { + done = true; + delay(1000); + } + if (digitalRead(buttonUp) == LOW) { + myCard.mode = min(myCard.mode + 1, 3); + mp3.playMp3FolderTrack(101 + myCard.mode); + delay(1000); + } + if (digitalRead(buttonDown) == LOW) { + myCard.mode = max(myCard.mode - 1, 1); + mp3.playMp3FolderTrack(101 + myCard.mode); + delay(1000); + } + } + while (done == false); + mp3.playMp3FolderTrack(110); + EEPROM.put(sizeof(StoredCard) * numberOfCards + sizeof(int), myCard); + numberOfCards = numberOfCards + 1; + EEPROM.put(0, numberOfCards); + } +} + + + +///////////////////////////////////////// Get PICC's UID /////////////////////////////////// +uint8_t getID() { + // Getting ready for Reading PICCs + if ( ! mfrc522.PICC_IsNewCardPresent()) { //If a new PICC placed to RFID reader continue + return 0; + } + if ( ! mfrc522.PICC_ReadCardSerial()) { //Since a PICC placed get Serial and continue + return 0; + } + // There are Mifare PICCs which have 4 byte or 7 byte UID care if you use 7 byte PICC + // I think we should assume every PICC as they have 4 byte UID + // Until we support 7 byte PICCs + Serial.println(F("Scanned PICC's UID:")); + for ( uint8_t i = 0; i < 4; i++) { // + readCard[i] = mfrc522.uid.uidByte[i]; + Serial.print(readCard[i], HEX); + } + Serial.println(""); + mfrc522.PICC_HaltA(); // Stop reading + return 1; +} + + + +///////////////////////////////////////// Check Bytes /////////////////////////////////// +boolean checkTwo ( byte a[], byte b[] ) { + boolean match = false; // initialize card match to false + if ( a[0] != 0 ) // Make sure there is something in the array first + match = true; // Assume they match at first + for ( uint8_t k = 0; k < 4; k++ ) { // Loop 4 times + if ( a[k] != b[k] ) // IF a != b then set match = false, one fails, all fail + match = false; + } + if ( match ) { // Check to see if if match is still true + return true; // Return true + } + else { + return false; // Return false + } +} + + diff --git a/SD-Karte/mp3/0001.mp3 b/SD-Karte/mp3/0001.mp3 new file mode 100644 index 0000000..0f0ba66 Binary files /dev/null and b/SD-Karte/mp3/0001.mp3 differ diff --git a/SD-Karte/mp3/0002.mp3 b/SD-Karte/mp3/0002.mp3 new file mode 100644 index 0000000..a827423 Binary files /dev/null and b/SD-Karte/mp3/0002.mp3 differ diff --git a/SD-Karte/mp3/0003.mp3 b/SD-Karte/mp3/0003.mp3 new file mode 100644 index 0000000..eb74ff4 Binary files /dev/null and b/SD-Karte/mp3/0003.mp3 differ diff --git a/SD-Karte/mp3/0004.mp3 b/SD-Karte/mp3/0004.mp3 new file mode 100644 index 0000000..e7a053c Binary files /dev/null and b/SD-Karte/mp3/0004.mp3 differ diff --git a/SD-Karte/mp3/0005.mp3 b/SD-Karte/mp3/0005.mp3 new file mode 100644 index 0000000..376d8ef Binary files /dev/null and b/SD-Karte/mp3/0005.mp3 differ diff --git a/SD-Karte/mp3/0006.mp3 b/SD-Karte/mp3/0006.mp3 new file mode 100644 index 0000000..37b3279 Binary files /dev/null and b/SD-Karte/mp3/0006.mp3 differ diff --git a/SD-Karte/mp3/0007.mp3 b/SD-Karte/mp3/0007.mp3 new file mode 100644 index 0000000..a2819f1 Binary files /dev/null and b/SD-Karte/mp3/0007.mp3 differ diff --git a/SD-Karte/mp3/0008.mp3 b/SD-Karte/mp3/0008.mp3 new file mode 100644 index 0000000..e2fa89d Binary files /dev/null and b/SD-Karte/mp3/0008.mp3 differ diff --git a/SD-Karte/mp3/0009.mp3 b/SD-Karte/mp3/0009.mp3 new file mode 100644 index 0000000..06859f3 Binary files /dev/null and b/SD-Karte/mp3/0009.mp3 differ diff --git a/SD-Karte/mp3/0010.mp3 b/SD-Karte/mp3/0010.mp3 new file mode 100644 index 0000000..04f2ffc Binary files /dev/null and b/SD-Karte/mp3/0010.mp3 differ diff --git a/SD-Karte/mp3/0011.mp3 b/SD-Karte/mp3/0011.mp3 new file mode 100644 index 0000000..4333343 Binary files /dev/null and b/SD-Karte/mp3/0011.mp3 differ diff --git a/SD-Karte/mp3/0012.mp3 b/SD-Karte/mp3/0012.mp3 new file mode 100644 index 0000000..1adc0bb Binary files /dev/null and b/SD-Karte/mp3/0012.mp3 differ diff --git a/SD-Karte/mp3/0013.mp3 b/SD-Karte/mp3/0013.mp3 new file mode 100644 index 0000000..aae08aa Binary files /dev/null and b/SD-Karte/mp3/0013.mp3 differ diff --git a/SD-Karte/mp3/0014.mp3 b/SD-Karte/mp3/0014.mp3 new file mode 100644 index 0000000..4808450 Binary files /dev/null and b/SD-Karte/mp3/0014.mp3 differ diff --git a/SD-Karte/mp3/0015.mp3 b/SD-Karte/mp3/0015.mp3 new file mode 100644 index 0000000..163f594 Binary files /dev/null and b/SD-Karte/mp3/0015.mp3 differ diff --git a/SD-Karte/mp3/0016.mp3 b/SD-Karte/mp3/0016.mp3 new file mode 100644 index 0000000..12f9944 Binary files /dev/null and b/SD-Karte/mp3/0016.mp3 differ diff --git a/SD-Karte/mp3/0017.mp3 b/SD-Karte/mp3/0017.mp3 new file mode 100644 index 0000000..c8417ac Binary files /dev/null and b/SD-Karte/mp3/0017.mp3 differ diff --git a/SD-Karte/mp3/0018.mp3 b/SD-Karte/mp3/0018.mp3 new file mode 100644 index 0000000..834dd80 Binary files /dev/null and b/SD-Karte/mp3/0018.mp3 differ diff --git a/SD-Karte/mp3/0019.mp3 b/SD-Karte/mp3/0019.mp3 new file mode 100644 index 0000000..ee13e3b Binary files /dev/null and b/SD-Karte/mp3/0019.mp3 differ diff --git a/SD-Karte/mp3/0020.mp3 b/SD-Karte/mp3/0020.mp3 new file mode 100644 index 0000000..6dd14e8 Binary files /dev/null and b/SD-Karte/mp3/0020.mp3 differ diff --git a/SD-Karte/mp3/0021.mp3 b/SD-Karte/mp3/0021.mp3 new file mode 100644 index 0000000..00c2c6e Binary files /dev/null and b/SD-Karte/mp3/0021.mp3 differ diff --git a/SD-Karte/mp3/0022.mp3 b/SD-Karte/mp3/0022.mp3 new file mode 100644 index 0000000..206f5ae Binary files /dev/null and b/SD-Karte/mp3/0022.mp3 differ diff --git a/SD-Karte/mp3/0023.mp3 b/SD-Karte/mp3/0023.mp3 new file mode 100644 index 0000000..9ea9941 Binary files /dev/null and b/SD-Karte/mp3/0023.mp3 differ diff --git a/SD-Karte/mp3/0024.mp3 b/SD-Karte/mp3/0024.mp3 new file mode 100644 index 0000000..182f06c Binary files /dev/null and b/SD-Karte/mp3/0024.mp3 differ diff --git a/SD-Karte/mp3/0025.mp3 b/SD-Karte/mp3/0025.mp3 new file mode 100644 index 0000000..47edb23 Binary files /dev/null and b/SD-Karte/mp3/0025.mp3 differ diff --git a/SD-Karte/mp3/0026.mp3 b/SD-Karte/mp3/0026.mp3 new file mode 100644 index 0000000..b4bc0bd Binary files /dev/null and b/SD-Karte/mp3/0026.mp3 differ diff --git a/SD-Karte/mp3/0027.mp3 b/SD-Karte/mp3/0027.mp3 new file mode 100644 index 0000000..6616b51 Binary files /dev/null and b/SD-Karte/mp3/0027.mp3 differ diff --git a/SD-Karte/mp3/0028.mp3 b/SD-Karte/mp3/0028.mp3 new file mode 100644 index 0000000..291ee65 Binary files /dev/null and b/SD-Karte/mp3/0028.mp3 differ diff --git a/SD-Karte/mp3/0029.mp3 b/SD-Karte/mp3/0029.mp3 new file mode 100644 index 0000000..ab686dd Binary files /dev/null and b/SD-Karte/mp3/0029.mp3 differ diff --git a/SD-Karte/mp3/0030.mp3 b/SD-Karte/mp3/0030.mp3 new file mode 100644 index 0000000..3286018 Binary files /dev/null and b/SD-Karte/mp3/0030.mp3 differ diff --git a/SD-Karte/mp3/0031.mp3 b/SD-Karte/mp3/0031.mp3 new file mode 100644 index 0000000..c03f020 Binary files /dev/null and b/SD-Karte/mp3/0031.mp3 differ diff --git a/SD-Karte/mp3/0032.mp3 b/SD-Karte/mp3/0032.mp3 new file mode 100644 index 0000000..3b763fb Binary files /dev/null and b/SD-Karte/mp3/0032.mp3 differ diff --git a/SD-Karte/mp3/0033.mp3 b/SD-Karte/mp3/0033.mp3 new file mode 100644 index 0000000..cf20f3c Binary files /dev/null and b/SD-Karte/mp3/0033.mp3 differ diff --git a/SD-Karte/mp3/0034.mp3 b/SD-Karte/mp3/0034.mp3 new file mode 100644 index 0000000..ab2f3a7 Binary files /dev/null and b/SD-Karte/mp3/0034.mp3 differ diff --git a/SD-Karte/mp3/0035.mp3 b/SD-Karte/mp3/0035.mp3 new file mode 100644 index 0000000..063f69d Binary files /dev/null and b/SD-Karte/mp3/0035.mp3 differ diff --git a/SD-Karte/mp3/0036.mp3 b/SD-Karte/mp3/0036.mp3 new file mode 100644 index 0000000..d86c789 Binary files /dev/null and b/SD-Karte/mp3/0036.mp3 differ diff --git a/SD-Karte/mp3/0037.mp3 b/SD-Karte/mp3/0037.mp3 new file mode 100644 index 0000000..31e68f2 Binary files /dev/null and b/SD-Karte/mp3/0037.mp3 differ diff --git a/SD-Karte/mp3/0038.mp3 b/SD-Karte/mp3/0038.mp3 new file mode 100644 index 0000000..df1e1ef Binary files /dev/null and b/SD-Karte/mp3/0038.mp3 differ diff --git a/SD-Karte/mp3/0039.mp3 b/SD-Karte/mp3/0039.mp3 new file mode 100644 index 0000000..ecfcfd3 Binary files /dev/null and b/SD-Karte/mp3/0039.mp3 differ diff --git a/SD-Karte/mp3/0040.mp3 b/SD-Karte/mp3/0040.mp3 new file mode 100644 index 0000000..4a979b8 Binary files /dev/null and b/SD-Karte/mp3/0040.mp3 differ diff --git a/SD-Karte/mp3/0041.mp3 b/SD-Karte/mp3/0041.mp3 new file mode 100644 index 0000000..f5ae286 Binary files /dev/null and b/SD-Karte/mp3/0041.mp3 differ diff --git a/SD-Karte/mp3/0042.mp3 b/SD-Karte/mp3/0042.mp3 new file mode 100644 index 0000000..0dc3fea Binary files /dev/null and b/SD-Karte/mp3/0042.mp3 differ diff --git a/SD-Karte/mp3/0043.mp3 b/SD-Karte/mp3/0043.mp3 new file mode 100644 index 0000000..1c132a4 Binary files /dev/null and b/SD-Karte/mp3/0043.mp3 differ diff --git a/SD-Karte/mp3/0044.mp3 b/SD-Karte/mp3/0044.mp3 new file mode 100644 index 0000000..abdf503 Binary files /dev/null and b/SD-Karte/mp3/0044.mp3 differ diff --git a/SD-Karte/mp3/0045.mp3 b/SD-Karte/mp3/0045.mp3 new file mode 100644 index 0000000..1a35ad4 Binary files /dev/null and b/SD-Karte/mp3/0045.mp3 differ diff --git a/SD-Karte/mp3/0046.mp3 b/SD-Karte/mp3/0046.mp3 new file mode 100644 index 0000000..6728fb0 Binary files /dev/null and b/SD-Karte/mp3/0046.mp3 differ diff --git a/SD-Karte/mp3/0047.mp3 b/SD-Karte/mp3/0047.mp3 new file mode 100644 index 0000000..be0623d Binary files /dev/null and b/SD-Karte/mp3/0047.mp3 differ diff --git a/SD-Karte/mp3/0048.mp3 b/SD-Karte/mp3/0048.mp3 new file mode 100644 index 0000000..db652ab Binary files /dev/null and b/SD-Karte/mp3/0048.mp3 differ diff --git a/SD-Karte/mp3/0049.mp3 b/SD-Karte/mp3/0049.mp3 new file mode 100644 index 0000000..24a5c56 Binary files /dev/null and b/SD-Karte/mp3/0049.mp3 differ diff --git a/SD-Karte/mp3/0050.mp3 b/SD-Karte/mp3/0050.mp3 new file mode 100644 index 0000000..dab8da3 Binary files /dev/null and b/SD-Karte/mp3/0050.mp3 differ diff --git a/SD-Karte/mp3/0051.mp3 b/SD-Karte/mp3/0051.mp3 new file mode 100644 index 0000000..14bf0a3 Binary files /dev/null and b/SD-Karte/mp3/0051.mp3 differ diff --git a/SD-Karte/mp3/0052.mp3 b/SD-Karte/mp3/0052.mp3 new file mode 100644 index 0000000..cd3fa56 Binary files /dev/null and b/SD-Karte/mp3/0052.mp3 differ diff --git a/SD-Karte/mp3/0053.mp3 b/SD-Karte/mp3/0053.mp3 new file mode 100644 index 0000000..5c78a69 Binary files /dev/null and b/SD-Karte/mp3/0053.mp3 differ diff --git a/SD-Karte/mp3/0054.mp3 b/SD-Karte/mp3/0054.mp3 new file mode 100644 index 0000000..de3cc9b Binary files /dev/null and b/SD-Karte/mp3/0054.mp3 differ diff --git a/SD-Karte/mp3/0055.mp3 b/SD-Karte/mp3/0055.mp3 new file mode 100644 index 0000000..dd234d0 Binary files /dev/null and b/SD-Karte/mp3/0055.mp3 differ diff --git a/SD-Karte/mp3/0056.mp3 b/SD-Karte/mp3/0056.mp3 new file mode 100644 index 0000000..13b8cc9 Binary files /dev/null and b/SD-Karte/mp3/0056.mp3 differ diff --git a/SD-Karte/mp3/0057.mp3 b/SD-Karte/mp3/0057.mp3 new file mode 100644 index 0000000..ed556d8 Binary files /dev/null and b/SD-Karte/mp3/0057.mp3 differ diff --git a/SD-Karte/mp3/0058.mp3 b/SD-Karte/mp3/0058.mp3 new file mode 100644 index 0000000..05fc7aa Binary files /dev/null and b/SD-Karte/mp3/0058.mp3 differ diff --git a/SD-Karte/mp3/0059.mp3 b/SD-Karte/mp3/0059.mp3 new file mode 100644 index 0000000..f703bc2 Binary files /dev/null and b/SD-Karte/mp3/0059.mp3 differ diff --git a/SD-Karte/mp3/0060.mp3 b/SD-Karte/mp3/0060.mp3 new file mode 100644 index 0000000..cb76ed2 Binary files /dev/null and b/SD-Karte/mp3/0060.mp3 differ diff --git a/SD-Karte/mp3/0061.mp3 b/SD-Karte/mp3/0061.mp3 new file mode 100644 index 0000000..0384d66 Binary files /dev/null and b/SD-Karte/mp3/0061.mp3 differ diff --git a/SD-Karte/mp3/0062.mp3 b/SD-Karte/mp3/0062.mp3 new file mode 100644 index 0000000..c3ad5b0 Binary files /dev/null and b/SD-Karte/mp3/0062.mp3 differ diff --git a/SD-Karte/mp3/0063.mp3 b/SD-Karte/mp3/0063.mp3 new file mode 100644 index 0000000..93a000b Binary files /dev/null and b/SD-Karte/mp3/0063.mp3 differ diff --git a/SD-Karte/mp3/0064.mp3 b/SD-Karte/mp3/0064.mp3 new file mode 100644 index 0000000..7fb4b6c Binary files /dev/null and b/SD-Karte/mp3/0064.mp3 differ diff --git a/SD-Karte/mp3/0065.mp3 b/SD-Karte/mp3/0065.mp3 new file mode 100644 index 0000000..e95b7cc Binary files /dev/null and b/SD-Karte/mp3/0065.mp3 differ diff --git a/SD-Karte/mp3/0066.mp3 b/SD-Karte/mp3/0066.mp3 new file mode 100644 index 0000000..6bc7d0f Binary files /dev/null and b/SD-Karte/mp3/0066.mp3 differ diff --git a/SD-Karte/mp3/0067.mp3 b/SD-Karte/mp3/0067.mp3 new file mode 100644 index 0000000..f36f8ff Binary files /dev/null and b/SD-Karte/mp3/0067.mp3 differ diff --git a/SD-Karte/mp3/0068.mp3 b/SD-Karte/mp3/0068.mp3 new file mode 100644 index 0000000..850aa72 Binary files /dev/null and b/SD-Karte/mp3/0068.mp3 differ diff --git a/SD-Karte/mp3/0069.mp3 b/SD-Karte/mp3/0069.mp3 new file mode 100644 index 0000000..92d2e70 Binary files /dev/null and b/SD-Karte/mp3/0069.mp3 differ diff --git a/SD-Karte/mp3/0070.mp3 b/SD-Karte/mp3/0070.mp3 new file mode 100644 index 0000000..e5f23b1 Binary files /dev/null and b/SD-Karte/mp3/0070.mp3 differ diff --git a/SD-Karte/mp3/0071.mp3 b/SD-Karte/mp3/0071.mp3 new file mode 100644 index 0000000..25247bc Binary files /dev/null and b/SD-Karte/mp3/0071.mp3 differ diff --git a/SD-Karte/mp3/0072.mp3 b/SD-Karte/mp3/0072.mp3 new file mode 100644 index 0000000..c939de6 Binary files /dev/null and b/SD-Karte/mp3/0072.mp3 differ diff --git a/SD-Karte/mp3/0073.mp3 b/SD-Karte/mp3/0073.mp3 new file mode 100644 index 0000000..6c47a8d Binary files /dev/null and b/SD-Karte/mp3/0073.mp3 differ diff --git a/SD-Karte/mp3/0074.mp3 b/SD-Karte/mp3/0074.mp3 new file mode 100644 index 0000000..479732a Binary files /dev/null and b/SD-Karte/mp3/0074.mp3 differ diff --git a/SD-Karte/mp3/0075.mp3 b/SD-Karte/mp3/0075.mp3 new file mode 100644 index 0000000..1fcc703 Binary files /dev/null and b/SD-Karte/mp3/0075.mp3 differ diff --git a/SD-Karte/mp3/0076.mp3 b/SD-Karte/mp3/0076.mp3 new file mode 100644 index 0000000..d898a5b Binary files /dev/null and b/SD-Karte/mp3/0076.mp3 differ diff --git a/SD-Karte/mp3/0077.mp3 b/SD-Karte/mp3/0077.mp3 new file mode 100644 index 0000000..1798091 Binary files /dev/null and b/SD-Karte/mp3/0077.mp3 differ diff --git a/SD-Karte/mp3/0078.mp3 b/SD-Karte/mp3/0078.mp3 new file mode 100644 index 0000000..7e31d67 Binary files /dev/null and b/SD-Karte/mp3/0078.mp3 differ diff --git a/SD-Karte/mp3/0079.mp3 b/SD-Karte/mp3/0079.mp3 new file mode 100644 index 0000000..e2ecf7c Binary files /dev/null and b/SD-Karte/mp3/0079.mp3 differ diff --git a/SD-Karte/mp3/0080.mp3 b/SD-Karte/mp3/0080.mp3 new file mode 100644 index 0000000..1cc4651 Binary files /dev/null and b/SD-Karte/mp3/0080.mp3 differ diff --git a/SD-Karte/mp3/0081.mp3 b/SD-Karte/mp3/0081.mp3 new file mode 100644 index 0000000..482bda1 Binary files /dev/null and b/SD-Karte/mp3/0081.mp3 differ diff --git a/SD-Karte/mp3/0082.mp3 b/SD-Karte/mp3/0082.mp3 new file mode 100644 index 0000000..43d1847 Binary files /dev/null and b/SD-Karte/mp3/0082.mp3 differ diff --git a/SD-Karte/mp3/0083.mp3 b/SD-Karte/mp3/0083.mp3 new file mode 100644 index 0000000..120126d Binary files /dev/null and b/SD-Karte/mp3/0083.mp3 differ diff --git a/SD-Karte/mp3/0084.mp3 b/SD-Karte/mp3/0084.mp3 new file mode 100644 index 0000000..6d7f92e Binary files /dev/null and b/SD-Karte/mp3/0084.mp3 differ diff --git a/SD-Karte/mp3/0085.mp3 b/SD-Karte/mp3/0085.mp3 new file mode 100644 index 0000000..6eff52e Binary files /dev/null and b/SD-Karte/mp3/0085.mp3 differ diff --git a/SD-Karte/mp3/0086.mp3 b/SD-Karte/mp3/0086.mp3 new file mode 100644 index 0000000..408f813 Binary files /dev/null and b/SD-Karte/mp3/0086.mp3 differ diff --git a/SD-Karte/mp3/0087.mp3 b/SD-Karte/mp3/0087.mp3 new file mode 100644 index 0000000..b52aa86 Binary files /dev/null and b/SD-Karte/mp3/0087.mp3 differ diff --git a/SD-Karte/mp3/0088.mp3 b/SD-Karte/mp3/0088.mp3 new file mode 100644 index 0000000..233620d Binary files /dev/null and b/SD-Karte/mp3/0088.mp3 differ diff --git a/SD-Karte/mp3/0089.mp3 b/SD-Karte/mp3/0089.mp3 new file mode 100644 index 0000000..2144a9f Binary files /dev/null and b/SD-Karte/mp3/0089.mp3 differ diff --git a/SD-Karte/mp3/0090.mp3 b/SD-Karte/mp3/0090.mp3 new file mode 100644 index 0000000..7679111 Binary files /dev/null and b/SD-Karte/mp3/0090.mp3 differ diff --git a/SD-Karte/mp3/0091.mp3 b/SD-Karte/mp3/0091.mp3 new file mode 100644 index 0000000..69ea839 Binary files /dev/null and b/SD-Karte/mp3/0091.mp3 differ diff --git a/SD-Karte/mp3/0092.mp3 b/SD-Karte/mp3/0092.mp3 new file mode 100644 index 0000000..5c080fe Binary files /dev/null and b/SD-Karte/mp3/0092.mp3 differ diff --git a/SD-Karte/mp3/0093.mp3 b/SD-Karte/mp3/0093.mp3 new file mode 100644 index 0000000..f9eb2db Binary files /dev/null and b/SD-Karte/mp3/0093.mp3 differ diff --git a/SD-Karte/mp3/0094.mp3 b/SD-Karte/mp3/0094.mp3 new file mode 100644 index 0000000..7711fd7 Binary files /dev/null and b/SD-Karte/mp3/0094.mp3 differ diff --git a/SD-Karte/mp3/0095.mp3 b/SD-Karte/mp3/0095.mp3 new file mode 100644 index 0000000..b8e98cd Binary files /dev/null and b/SD-Karte/mp3/0095.mp3 differ diff --git a/SD-Karte/mp3/0096.mp3 b/SD-Karte/mp3/0096.mp3 new file mode 100644 index 0000000..818fcb6 Binary files /dev/null and b/SD-Karte/mp3/0096.mp3 differ diff --git a/SD-Karte/mp3/0097.mp3 b/SD-Karte/mp3/0097.mp3 new file mode 100644 index 0000000..1daf98a Binary files /dev/null and b/SD-Karte/mp3/0097.mp3 differ diff --git a/SD-Karte/mp3/0098.mp3 b/SD-Karte/mp3/0098.mp3 new file mode 100644 index 0000000..1ff4331 Binary files /dev/null and b/SD-Karte/mp3/0098.mp3 differ diff --git a/SD-Karte/mp3/0099.mp3 b/SD-Karte/mp3/0099.mp3 new file mode 100644 index 0000000..af55b2f Binary files /dev/null and b/SD-Karte/mp3/0099.mp3 differ diff --git a/SD-Karte/mp3/0100.mp3 b/SD-Karte/mp3/0100.mp3 new file mode 100644 index 0000000..9a76b0b Binary files /dev/null and b/SD-Karte/mp3/0100.mp3 differ diff --git a/SD-Karte/mp3/0101.mp3 b/SD-Karte/mp3/0101.mp3 new file mode 100644 index 0000000..e1437cb Binary files /dev/null and b/SD-Karte/mp3/0101.mp3 differ diff --git a/SD-Karte/mp3/0102.mp3 b/SD-Karte/mp3/0102.mp3 new file mode 100644 index 0000000..59449e4 Binary files /dev/null and b/SD-Karte/mp3/0102.mp3 differ diff --git a/SD-Karte/mp3/0103.mp3 b/SD-Karte/mp3/0103.mp3 new file mode 100644 index 0000000..cb21355 Binary files /dev/null and b/SD-Karte/mp3/0103.mp3 differ diff --git a/SD-Karte/mp3/0104.mp3 b/SD-Karte/mp3/0104.mp3 new file mode 100644 index 0000000..9857a8e Binary files /dev/null and b/SD-Karte/mp3/0104.mp3 differ diff --git a/SD-Karte/mp3/0110.mp3 b/SD-Karte/mp3/0110.mp3 new file mode 100644 index 0000000..6f87e20 Binary files /dev/null and b/SD-Karte/mp3/0110.mp3 differ diff --git a/create-soundfiles.sh b/create-soundfiles.sh new file mode 100755 index 0000000..6c568a4 --- /dev/null +++ b/create-soundfiles.sh @@ -0,0 +1,40 @@ +#!/bin/bash + +for i in {01..99}; +do + i=$(printf "%02d" $i) + say -v anna $i -o $i.aiff + sox $i.aiff $i.wav pitch 800 + lame -b 128 $i.wav 00$i.mp3 +done + +say -v Anna "Oh, eine neue Karte! Verwende die Lautstärke Knöpfe um einen Order für die Karte auszuwählen. Drücke die Pause Taste um die Auswahl zu speichern." -o 0100.aiff +sox 0100.aiff 0100.wav pitch 800 +lame -b 128 0100.wav 0100.mp3 + +say -v Anna "OK, ich habe die Karte mit dem Ordner verknüpft. Wähle nun mit den Lautstärke Knöpfen den Wiedergabemodus aus." -o 0101.aiff +sox 0101.aiff 0101.wav pitch 800 +lame -b 128 0101.wav 0101.mp3 + +say -v Anna "Hörspielmodus: Ein zufälliges Lied aus dem Ordner wiedergeben" -o 0102.aiff +sox 0102.aiff 0102.wav pitch 800 +lame -b 128 0102.wav 0102.mp3 + +say -v Anna "Albummodus: Den kompletten Ordner wiedergeben" -o 0103.aiff +sox 0103.aiff 0103.wav pitch 800 +lame -b 128 0103.wav 0103.mp3 + +say -v Anna "Party Modus: Ordner zufällig wiedergeben." -o 0104.aiff +sox 0104.aiff 0104.wav pitch 800 +lame -b 128 0104.wav 0104.mp3 + +say -v Anna "Einzel Modus: Eine bestimmte Datei im Ordner wiedergeben." -o 0105.aiff +sox 0105.aiff 0105.wav pitch 800 +lame -b 128 0105.wav 0105.mp3 + +say -v Anna "OK. Ich habe die Karte konfiguriert." -o 0110.aiff +sox 0110.aiff 0110.wav pitch 800 +lame -b 128 0110.wav 0110.mp3 + +rm *.aiff +rm *.wav