{"id":26190881,"url":"https://github.com/codingabi/dfr0534","last_synced_at":"2025-04-15T02:10:49.662Z","repository":{"id":215503745,"uuid":"737599682","full_name":"codingABI/DFR0534","owner":"codingABI","description":"Arduino Uno/Nano/ATmega328p, ESP32 library to control a DFR0534 audio module with SoftwareSerial or HardwareSerial","archived":false,"fork":false,"pushed_at":"2024-10-21T16:18:14.000Z","size":5665,"stargazers_count":1,"open_issues_count":0,"forks_count":1,"subscribers_count":0,"default_branch":"main","last_synced_at":"2024-10-22T11:20:01.344Z","etag":null,"topics":["arduino","atmega328p","avr","dfr0534","esp32","jq8400"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-2-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/codingABI.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-12-31T17:29:33.000Z","updated_at":"2024-10-21T16:18:17.000Z","dependencies_parsed_at":"2024-01-04T20:32:04.532Z","dependency_job_id":"330bddcc-1527-4e8f-8033-82717dfe6f93","html_url":"https://github.com/codingABI/DFR0534","commit_stats":null,"previous_names":["codingabi/dfr0534"],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codingABI%2FDFR0534","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codingABI%2FDFR0534/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codingABI%2FDFR0534/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codingABI%2FDFR0534/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/codingABI","download_url":"https://codeload.github.com/codingABI/DFR0534/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248991557,"owners_count":21194894,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["arduino","atmega328p","avr","dfr0534","esp32","jq8400"],"created_at":"2025-03-12T00:58:30.496Z","updated_at":"2025-04-15T02:10:49.640Z","avatar_url":"https://github.com/codingABI.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# DFR0534\nAn Arduino Uno/Nano/ATmega328p, ESP32 library for a [DFR0534](https://wiki.dfrobot.com/Voice_Module_SKU__DFR0534) audio module. The library works with SoftwareSerial/HardwareSerial and is very similar to https://github.com/sleemanj/JQ8400_Serial, but is no fork.\n\n[PDF-Documentation](DFR0534.pdf)\n\nExamples, how to use the library\n- [playFileByName](/examples/playFileByName/playFileByName.ino)\n- [playFileByNumber](/examples/playFileByNumber/playFileByNumber.ino)\n- [playCombined](/examples/playCombined/playCombined.ino)\n\n## SoftwareSerial for Arduino Uno/Nano/ATmega328p\nTo create a DFR0534 object pass the SoftwareSerial object as a parameter to the DFR0534 constructor, for example\n\n```\n#include \u003cSoftwareSerial.h\u003e\n#include \u003cDFR0534.h\u003e\n\n#define TX_PIN A0\n#define RX_PIN A1\nSoftwareSerial g_serial(RX_PIN, TX_PIN);\nDFR0534 g_audio(g_serial);\n...\n```\n\n## HardwareSerial for ESP32\nTo create a DFR0534 object pass the HardwareSerial object as a parameter to the DFR0534 constructor, for example\n\n```\n#include \u003cDFR0534.h\u003e\n\n#define TX_PIN 19\n#define RX_PIN 23\nHardwareSerial g_serial(1);\n\nDFR0534 g_audio(g_serial);\n\nvoid setup() {\n  g_serial.begin(9600, SERIAL_8N1, RX_PIN, TX_PIN);\n...\n```\n\n## License and copyright\nThis library is licensed under the terms of the 2-Clause BSD License [Copyright (c) 2024 codingABI](LICENSE.txt). \n\n## Appendix\n\n### Supported functions\n\n\n| Function  | Notes |\n| ------------- | ------------- |\n| decreaseVolume |   |\n| fastBackwardDuration |   |\n| fastForwardDuration |   |\n| getDrive | Returns DFR0534::DRIVEUSB, DFR0534::DRIVESD, DFR0534::DRIVEFLASH or DFR0534::DRIVEUNKNOWN, Example [playFileByNumber](/examples/playFileByNumber/playFileByNumber.ino) |\n| getDrivesStates | Returns bitmask for DFR0534::DRIVEUSB, DFR0534::DRIVESD, DFR0534::DRIVEFLASH, Example [playFileByNumber](/examples/playFileByNumber/playFileByNumber.ino) |\n| getDuration |   |\n| getFileName | Example [playFileByNumber](/examples/playFileByNumber/playFileByNumber.ino)  |\n| getFileNumber | Example [playFileByNumber](/examples/playFileByNumber/playFileByNumber.ino)  |\n| getFirstFileNumberInCurrentDirectory | Example [playFileByNumber](/examples/playFileByNumber/playFileByNumber.ino)  |\n| getRuntime |   |\n| getStatus | Returns DFR0534::STOPPED, DFR0534::PLAYING, DFR0534::PAUSED or DFR0534::STATUSUNKNOWN, Example [playFileByNumber](/examples/playFileByNumber/playFileByNumber.ino)|\n| getTotalFiles | Example [playFileByNumber](/examples/playFileByNumber/playFileByNumber.ino)  |\n| getTotalFilesInCurrentDirectory | Example [playFileByNumber](/examples/playFileByNumber/playFileByNumber.ino)  |\n| increaseVolume |   |\n| insertFileByNumber |   |\n| pause |   |\n| play |   |\n| playCombined | The DFR0534 uses a special two char file name format and fixed folder /ZH for this function. Look at the example [playCombined](/examples/playCombined/playCombined.ino) or comments to this function in [DFR0534.cpp](src/DFR0534.cpp) for details |\n| playFileByName | The DFR0534 uses a special 8+3 file name format. Before using this function take a look at the example [playFileByName](/examples/playFileByName/playFileByName.ino) or the comments to this function in [DFR0534.cpp](src/DFR0534.cpp) for details |\n| playFileByNumber | Example [playFileByNumber](/examples/playFileByNumber/playFileByNumber.ino)  |\n| playLastInDirectory |   |\n| playNext |   |\n| playNextDirectory |   |\n| playPrevious |   |\n| prepareFileByNumber |   |\n| repeatPart |   |\n| setChannel | Seems make no sense on a DFR0534 audio module |\n| setDrive | Supports DFR0534::DRIVEUSB, DFR0534::DRIVESD and DFR0534::DRIVEFLASH |\n| setDirectory | Seems not to work |\n| setEqualizer | Supports DFR0534::NORMAL, DFR0534::POP, DFR0534::ROCK, DFR0534::JAZZ and DFR0534::CLASSIC  |\n| setLoopMode | Supports DFR0534::LOOPBACKALL, DFR0534::SINGLEAUDIOLOOP, DFR0534::SINGLEAUDIOSTOP, DFR0534::PLAYRANDOM, DFR0534::DIRECTORYLOOP, DFR0534::RANDOMINDIRECTORY, DFR0534::SEQUENTIALINDIRECTORY and DFR0534::SEQUENTIAL |\n| setRepeatLoops |   |\n| setVolume | Volume level (0 = mute, 30 = max), Example [playFileByNumber](/examples/playFileByNumber/playFileByNumber.ino)  |\n| startSendingRuntime |   |\n| stop |   |\n| stopCombined |   |\n| stopInsertedFile |   |\n| stopRepeatPart |   |\n| stopSendingRuntime |   |\n\nFor function details see comments in [DFR0534.cpp](src/DFR0534.cpp)\n\n### DFR0534 pinout\n\n![DFR0534 frontside](assets/images/DFR0534.jpg)\n![DFR0534 backside](assets/images/DFR0534_backside.jpg)\n\nMinimal schematic to use this library\n| Pin  | Connected to |\n| ------------- | ------------- |\n| TX | SoftwareSerial/HardwareSerial RX  |\n| RX | SoftwareSerial/HardwareSerial TX* |\n| GND | Ground  |\n| VCC | 3.3-5V  |\n| SP+ | Speaker + connector |\n| SP- | Speaker - connector |\n\n*If your microcontroller runs at 5V, use a 1k resistor between RX and SoftwareSerial/HardwareSerial TX.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcodingabi%2Fdfr0534","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcodingabi%2Fdfr0534","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcodingabi%2Fdfr0534/lists"}