22 #ifndef PLUGINS_USBPRO_WIDGETDETECTORTHREAD_H_
23 #define PLUGINS_USBPRO_WIDGETDETECTORTHREAD_H_
31 #include "ola/io/Descriptor.h"
32 #include "ola/io/SelectServer.h"
33 #include "ola/thread/Thread.h"
34 #include "plugins/usbpro/BaseUsbProWidget.h"
35 #include "plugins/usbpro/RobeWidget.h"
36 #include "plugins/usbpro/RobeWidgetDetector.h"
37 #include "plugins/usbpro/UsbProWidgetDetector.h"
38 #include "plugins/usbpro/SerialWidgetInterface.h"
39 #include "plugins/usbpro/WidgetDetectorInterface.h"
72 virtual void NewWidget(
class RobeWidget *widget,
86 unsigned int usb_pro_timeout = 200,
87 unsigned int robe_timeout = 200);
102 bool Join(
void *ptr);
118 vector<WidgetDetectorInterface*> m_widget_detectors;
120 vector<string> m_prefixes;
121 set<string> m_ignored_devices;
124 unsigned int m_usb_pro_timeout;
125 unsigned int m_robe_timeout;
130 set<string> m_active_paths;
132 typedef std::pair<string, int> DescriptorInfo;
134 typedef map<ConnectedDescriptor*, DescriptorInfo>
137 ActiveDescriptors m_active_descriptors;
150 template<
typename W
idgetType,
typename InfoType>
151 void DispatchWidget(WidgetType *widget,
const InfoType *information);
154 template<
typename W
idgetType,
typename InfoType>
155 void SignalNewWidget(WidgetType *widget,
const InfoType *information);
157 void MarkAsRunning();
159 static const unsigned int SCAN_INTERVAL_MS = 20000;
166 static const uint16_t DMX_KING_DMX512_ID = 0;
167 static const uint16_t DMX_KING_ULTRA_ID = 1;
168 static const uint16_t DMX_KING_ULTRA_PRO_ID = 2;
169 static const uint16_t DMX_KING_ULTRA_MICRO_ID = 3;
170 static const uint16_t DMX_KING_ULTRA_RDM_ID = 4;
173 static const uint16_t JESE_DMX_TRI_MK1_ID = 1;
174 static const uint16_t JESE_RDM_TRI_MK1_ID = 2;
175 static const uint16_t JESE_RDM_TRI_MK2_ID = 3;
176 static const uint16_t JESE_RDM_TXI_MK2_ID = 4;
178 static const uint16_t JESE_DMX_TRI_MK1_SE_ID = 5;
181 static const uint16_t GODDARD_DMXTER4_ID = 0x444d;
182 static const uint16_t GODDARD_MINI_DMXTER4_ID = 0x4d49;
185 static const uint16_t OPEN_LIGHTING_PACKETHEADS_ID = 2;
186 static const uint16_t OPEN_LIGHTING_RGB_MIXER_ID = 1;
189 static const uint16_t DMX_KING_ESTA_ID = 0x6a6b;
190 static const uint16_t GODDARD_ESTA_ID = 0x4744;
191 static const uint16_t JESE_ESTA_ID = 0x6864;
196 #endif // PLUGINS_USBPRO_WIDGETDETECTORTHREAD_H_