forked from ambilight-4-mediaportal/AtmoWin
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathAtmoEntecSerialConnection.h
More file actions
67 lines (50 loc) · 2.17 KB
/
Copy pathAtmoEntecSerialConnection.h
File metadata and controls
67 lines (50 loc) · 2.17 KB
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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
/*
* AtmoEntecSerialConnection.h: Class for communication with the serial DMX Interface of ENTTEC
* http://www.enttec.com/index.php?main_menu=Products&pn=70303
*
* See the README.txt file for copyright information and how to reach the author(s).
*
* $Id: 53ef12a8702c0b1db5df453ec6e3f4e6577df813 $
*/
#ifndef _AtmoEntecSerialConnection_h_
#define _AtmoEntecSerialConnection_h_
#include "AtmoDefs.h"
#include "AtmoConnection.h"
#include "AtmoConfig.h"
#if defined(WIN32)
# include <windows.h>
#endif
class CAtmoEntecSerialConnection : public CAtmoConnection {
private:
HANDLE m_hComport;
// DMX Channel Buffer including some Control Bytes for up to 512 DMX Channels
unsigned char DMXout[513];
// contains the DMX Start Adress of each Atmo-Dmx-Channel
int *m_dmx_channels_base;
public:
CAtmoEntecSerialConnection(CAtmoConfig *cfg);
virtual ~CAtmoEntecSerialConnection(void);
virtual ATMO_BOOL OpenConnection();
virtual void CloseConnection();
virtual ATMO_BOOL isOpen(void);
virtual ATMO_BOOL SendData(pColorPacket data);
virtual ATMO_BOOL HardwareWhiteAdjust(int global_gamma,
int global_contrast,
int contrast_red,
int contrast_green,
int contrast_blue,
int gamma_red,
int gamma_green,
int gamma_blue,
ATMO_BOOL storeToEeprom);
virtual ATMO_BOOL setChannelColor(int channel, tRGBColor color);
virtual ATMO_BOOL setChannelValues(int numValues,unsigned char *channel_values);
virtual int getNumChannels();
#if !defined(_ATMO_VLC_PLUGIN_)
virtual char *getChannelName(int ch);
virtual ATMO_BOOL ShowConfigDialog(HINSTANCE hInst, HWND parent, CAtmoConfig *cfg);
#endif
virtual const char *getDevicePath() { return "enttec"; }
virtual ATMO_BOOL CreateDefaultMapping(CAtmoChannelAssignment *ca);
};
#endif