hyperion.ng
LedDeviceUdpH801.h
1 #pragma once
2 
3 // hyperion includes
4 #include "ProviderUdp.h"
5 
10 {
11 protected:
12  QList<int> _ids;
13  QByteArray _message;
14  const int _prefix_size = 2;
15  const int _colors = 5;
16  const int _id_size = 3;
17  const int _suffix_size = 1;
18 
19 public:
25  LedDeviceUdpH801(const QJsonObject &deviceConfig);
26 
32  bool init(const QJsonObject &deviceConfig);
33 
35  static LedDevice* construct(const QJsonObject &deviceConfig);
36 
37 private:
44  virtual int write(const std::vector<ColorRgb> &ledValues);
45 };
Implementation of the LedDevice interface for sending led colors via udp.
Definition: LedDeviceUdpH801.h:9
The ProviderUdp implements an abstract base-class for LedDevices using UDP packets.
Definition: ProviderUdp.h:15
Interface (pure virtual base class) for LedDevices.
Definition: LedDevice.h:32
LedDeviceUdpH801(const QJsonObject &deviceConfig)
Constructs specific LedDevice.
Definition: LedDeviceUdpH801.cpp:3
static LedDevice * construct(const QJsonObject &deviceConfig)
constructs leddevice
Definition: LedDeviceUdpH801.cpp:40
bool init(const QJsonObject &deviceConfig)
Sets configuration.
Definition: LedDeviceUdpH801.cpp:9