This repository has been archived on 2024-08-19. You can view files and clone it, but cannot push or open issues or pull requests.
Arduino/JQ6500.ino
2023-06-20 16:39:05 +03:00

22 lines
568 B
C++
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

#include <Arduino.h>
#include <SoftwareSerial.h>
#include <JQ6500_Serial.h>
// Arduino Pin 8 подключен к TX JQ6500
// Arduino Pin 9 подключен к RX JQ6500 через резистор 1кОм,
// Если у Вас Arduino питается 3v3 можно подключать без резистора
JQ6500_Serial mp3(8,9);
void setup() {
mp3.begin(9600);
mp3.reset();
mp3.setVolume(3);
mp3.setLoopMode(MP3_LOOP_NONE);
}
void loop() {
mp3.playFileByIndexNumber(1); // проигрывание файла с номером 1
}