forked from sowbug/G35Arduino
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Stereo.h
30 lines (23 loc) · 799 Bytes
/
Stereo.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
/*
G35: An Arduino library for GE Color Effects G-35 holiday lights.
Copyright © 2011 The G35 Authors. Use, modification, and distribution are
subject to the BSD license as described in the accompanying LICENSE file.
By Mike Tsao <https://github.com/sowbug>.
See README for complete attributions.
*/
#ifndef INCLUDE_G35_PROGRAMS_STEREO_H
#define INCLUDE_G35_PROGRAMS_STEREO_H
#include <LightProgram.h>
// Stereo was inspired by SparkFun's "FAKE MUSIC!" demo for their
// Bargraph Breakout board. Thanks, guys!
class Stereo : public LightProgram {
public:
Stereo(G35& g35);
uint32_t Do();
private:
const uint8_t light_count_;
const float half_light_count_;
const float level0_, level1_, level2_, level3_;
float step_, peak_;
};
#endif // INCLUDE_G35_PROGRAMS_STEREO_H