forked from MCUapps/Garan-Arduino
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathGaran.h
46 lines (43 loc) · 1.27 KB
/
Garan.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
/*
Garan.h - Library for controlling Garan Audio Module
Released into the public domain.
*/
#ifndef Garan_h
#define Garan_h
#include <SoftwareSerial.h>
class Garan
{
private:
SoftwareSerial &_serial;
unsigned char _commandBuff[13];
void sendCommand(uint8_t command[]);
inline void buildHead(uint8_t len, uint8_t cmd);
public:
Garan(SoftwareSerial &theSerial);
bool available();
void singlePlay(uint16_t number);
void sequencePlay(uint16_t number);
void singleLoopPlay(uint16_t number);
void singlePlayName(char *name);
void sequencePlayName(char *name);
void singleLoopName(char *name);
void stop();
void pausePlay();
void next();
void prev();
void volumeUp();
void volumeDown();
void setVolume(uint8_t volume);
void eqChange();
void setEQ(uint8_t eq);
void standbyMode();
void setTime(uint16_t year, uint8_t month, uint8_t day, uint8_t hour, uint8_t minute, uint8_t second);
void getPlayingName();
void getMusicNumbers();
void getPlayingOrder();
void getTime();
void feedbackAtEnd();
void NoFeedbackAtEnd();
void getVersion();
};
#endif // Garan_h