stageprofi.h
Go to the documentation of this file.
1 /*
2  * Copyright 2017 Fraunhofer Institute for Manufacturing Engineering and Automation (IPA)
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9 
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 
18 #ifndef COB_DRIVER_STAGE_PROFI_H
19 #define COB_DRIVER_STAGE_PROFI_H
20 
21 #include <iColorO.h>
22 
23 #include <serialIO.h>
24 #include <colorUtils.h>
25 #include <sstream>
26 
27 class StageProfi : public IColorO
28 {
29 public:
30  StageProfi(SerialIO* serialIO, unsigned int leds, int led_offset);
31  virtual ~StageProfi();
32 
33  bool init();
34 
36  void setColorMulti(std::vector<color::rgba> &colors);
37 
38 private:
40  std::stringstream _ssOut;
42  static const unsigned int HEADER_SIZE = 4;
43  static const unsigned int MAX_CHANNELS = 255;
44 
45  bool recover();
46  bool sendDMX(uint16_t start, const char* buf, unsigned int length);
47 };
48 
49 #endif
std::stringstream _ssOut
Definition: stageprofi.h:40
StageProfi(SerialIO *serialIO, unsigned int leds, int led_offset)
Definition: stageprofi.cpp:24
int _led_offset
Definition: stageprofi.h:41
static const unsigned int HEADER_SIZE
Definition: stageprofi.h:42
bool sendDMX(uint16_t start, const char *buf, unsigned int length)
Definition: stageprofi.cpp:142
SerialIO * _serialIO
Definition: stageprofi.h:39
void setColor(color::rgba color)
Definition: stageprofi.cpp:55
void setColorMulti(std::vector< color::rgba > &colors)
Definition: stageprofi.cpp:94
bool init()
Definition: stageprofi.cpp:35
bool recover()
Definition: stageprofi.cpp:166
virtual ~StageProfi()
Definition: stageprofi.cpp:31
static const unsigned int MAX_CHANNELS
Definition: stageprofi.h:43


cob_light
Author(s): Benjamin Maidel
autogenerated on Wed Apr 7 2021 02:11:39