Makeblock-library-for-Arduino  V3.2.4
It's a library for arduino application developers
MeBuzzer.h
Go to the documentation of this file.
1 
43 #ifndef MeBuzzer_H
44 #define MeBuzzer_H
45 
46 #include <stdint.h>
47 #include <stdbool.h>
48 #include <Arduino.h>
49 #include "MeConfig.h"
50 
51 #ifdef ME_PORT_DEFINED
52 #include "MePort.h"
53 #endif // ME_PORT_DEFINED
54 
60 class MeBuzzer : public MePort
61 {
62 public:
63 #ifdef ME_PORT_DEFINED
64 
70  MeBuzzer();
71 
78  MeBuzzer(uint8_t port);
79 
88  MeBuzzer(uint8_t port, uint8_t slot);
89 #else // ME_PORT_DEFINED
90 
95  MeBuzzer(int pin);
96 #endif // ME_PORT_DEFINED
97 
111  void setpin(int pin);
112 
131  void tone(int pin, uint16_t frequency, uint32_t duration);
132 
149  void tone(uint16_t frequency, uint32_t duration = 0);
150 
165  void noTone(int pin);
166 
181  void noTone();
182 };
183 #endif
Configuration file of library.
Port Mapping for RJ25.
Definition: MePort.h:118
void tone(int pin, uint16_t frequency, uint32_t duration)
Definition: MeBuzzer.cpp:142
MeBuzzer()
Definition: MeBuzzer.cpp:57
Driver for Me Buzzer module.
Definition: MeBuzzer.h:60
void noTone()
Definition: MeBuzzer.cpp:224
void setpin(int pin)
Definition: MeBuzzer.cpp:119
uint8_t pin(void)
Definition: MePort.cpp:427
Header for MePort.cpp module.