www.pudn.com > LEDShow.rar > LEDAPI.h, change:2014-04-01,size:23568b


#ifndef __ledsend__ 
#define __ledsend__ 
 
/* 
   参数说明 
    
*/ 
#include <windows.h> 
 
//IP地址、MAC地址长度定义 
#define     IP_ADDRESS_LENGTH      4 
#define     ETHER_ADDRESS_LENGTH   6 
 
#define DEVICE_TYPE_COM    0 
#define DEVICE_TYPE_UDP    1 
//#define DEVICE_TYPE_485    2 
 
#define SBR_9600           0 
#define SBR_14400          1 
#define SBR_19200          2 
#define SBR_38400          3 
#define SBR_57600          4 
#define SBR_115200         5 
 
//打开设备的Notify 
//不等待设备应答,立即返回,不发送窗体消息 
#define NOTIFY_MODE_NONE   0 
//不等待设备应答,立即返回,发送窗体消息 
#define NOTIFY_MODE_EVENT  1 
//等待设备应答后再返回,不发送窗体消息 
#define NOTIFY_MODE_SYNC   2 
 
#define ROOT_PLAY       0x11 
#define ROOT_DOWNLOAD   0x12 
#define ROOT_PLAY2      0x18 
#define ROOT_DOWNLOAD2  0x16 
 
#define SCREEN_UNICOLOR    1 
#define SCREEN_COLOR       2 
#define SCREEN_RGB         3 
#define SCREEN_FULL_4BIT   4 
#define SCREEN_FULL_10BIT  5 
 
#define LM_RX_COMPLETE     1 
#define LM_TX_COMPLETE     2 
#define LM_RESPOND         3 
#define LM_TIMEOUT         4 
#define LM_NOTIFY          5 
#define LM_PARAM           6 
#define LM_TX_PROGRESS     7 
#define LM_RX_PROGRESS     8 
 
#define DF_YMD             1      //年月日  "2004年12月31日" 
#define DF_HN              2      //时分    "19:20" 
#define DF_HNS             3      //时分秒  "19:20:30" 
#define DF_Y               4      //年      "2004" 
#define DF_M               5      //月      "12" "01" 注意:始终显示两位数字 
#define DF_D               6      //日 
#define DF_H               7      //时 
#define DF_N               8      //分 
#define DF_S               9      //秒 
#define DF_W               10     //星期    "星期三" 
 
//正计时、倒计时format参数 
#define CF_DAY             0      //天数 
#define CF_HOUR            1      //小时数 
#define CF_HMS             2      //时分秒 
#define CF_HM              3      //时分 
#define CF_MS              4      //分秒 
#define CF_S               5      //秒 
 
#define LED_POWER_ON       1 
#define LED_POWER_OFF      0 
 
//流控制常量 
#define FLOW_NONE          0 
#define FLOW_RTS_CTS       1 
 
//内码文字大小 
#define FONT_SET_16        0      //16点阵字符 
#define FONT_SET_24        1      //24点阵字符 
   
#define PKC_QUERY          4 
#define PKC_ADJUST_TIME    6 
#define PKC_GET_PARAM      7 
#define PKC_GET_POWER      9 
#define PKC_SET_POWER      10 
#define PKC_GET_BRIGHT     11 
#define PKC_SET_BRIGHT     12 
#define PKC_SET_SWITCH     20 
#define PKC_GET_AUTO_POWER  60 
#define PKC_SET_AUTO_POWER  61 
#define PKC_GET_AUTO_BRIGHT 62 
#define PKC_SET_AUTO_BRIGHT 63 
#define PKC_GET_IMPORT      64 
#define PKC_GET_LEAF        65 
#define PKC_SET_LEAF        66 
#define PKC_RESET_DISPLAY   99 
 
#define PKC_MODIFY_IP          7654 
#define PKC_GET_DISPLAY_BUFFER 8925 
 
//LED_GetOption, LED_SetOption索引值 
#define OPTION_TX_TIMER    1      //配置发送超时时间(以毫秒为单位) 
#define OPTION_REPEAT      2      //配置发送重试次数(1-64) 
#define OPTION_MOVE_WINDOW 3      //配置发送滑动窗口大小(1-8),如果配置为1,则通讯形式为停、等协议, 
                                  //既发出一个数据包后等待应答,然后再传送下一个数据包,这样传送效率比较低 
typedef struct DEVICEPARAM{ 
  DWORD  devType; 
  DWORD  Speed; 
  DWORD  ComPort; 
  DWORD  FlowCon; 
  DWORD  locPort; 
  DWORD  rmtPort; 
  DWORD  memory; 
  WORD   src_udp_ident; 
  WORD   src_udp_port; 
  char   src_host[28]; 
  DWORD  Reserved[5]; 
}TDeviceParam, *PDeviceParam; 
 
typedef struct DEVINFO{ 
  char devName[32];     //设备名称 
  DWORD devID;          //设备标识 
  DWORD devIP;          //设备IP地址 
  WORD devAddr;         //设备地址 
  WORD devPort;         //设备端口 
  DWORD reserved[5];    //系统保留 
}TDevInfo, *PDevInfo; 
 
typedef struct DEVREPORT{ 
  TDevInfo devInfo; 
  double timeUpdate; 
}TDevReport, *PDevReport; 
 
typedef struct NOTIFYMESSAGE{ 
  long   Message; 
  long   Command; 
  long   Result; 
  long   Status; 
  long   Address; 
  long   Size; 
  char   *Buffer; 
  TDeviceParam param; 
  char   Host[16]; 
  long   port; 
}TNotifyMessage, *PNotifyMessage; 
 
typedef struct BOARDPARAM{ 
  WORD   width; 
  WORD   height; 
  WORD   type; 
  WORD   frequency; 
  DWORD  flag; 
  DWORD  uart; 
  BYTE   mac[ETHER_ADDRESS_LENGTH]; 
  BYTE   ip[IP_ADDRESS_LENGTH]; 
  BYTE   GateMAC[ETHER_ADDRESS_LENGTH]; 
  BYTE   host[IP_ADDRESS_LENGTH]; 
  DWORD  brightness; 
  DWORD  rom_size; 
  long   left; 
  long   top; 
  WORD   scan_mode; 
  WORD   remote_port; 
  WORD   line_order; 
  WORD   oe_time; 
  WORD   shift_freq; 
  WORD   refresh_freq; 
  BYTE   GateIP[IP_ADDRESS_LENGTH]; 
  BYTE   ipMask[IP_ADDRESS_LENGTH]; 
  BYTE   name[32]; 
  DWORD  ident; 
  DWORD  address; 
}TBoardParam, *PBoardParam; 
 
typedef struct TIMESTAMP{ 
  long   time; 
  long   date; 
}TTimeStamp, *PTimeStamp; 
 
typedef struct _AUTOPOWERTIME 
{ 
	DWORD enabled; 
	TTimeStamp opentime[7]; 
	TTimeStamp closetime[7]; 
}TAutoPowerTime, *PAutoPowerTime; 
 
typedef struct _BRIGHTTABLE 
{ 
	DWORD enabled; 
	BYTE bright[24]; 
}TBrightTable, *PBrightTable; 
 
void (_stdcall *LED_SetDebugMode)(void); 
long (_stdcall *LED_Open)(const PDeviceParam param, long Notify, long Window, long Message); 
long (_stdcall *LED_Open2)(long devType, long ComPort, long Speed, long locPort, long Notify, long Window, long Message); 
void (_stdcall *LED_Close)(long dev); 
void (_stdcall *LED_CloseAll)(void); 
void (_stdcall *LED_Query)(long dev, BYTE Address, char *Host, long port); 
void (_stdcall *LED_Reset)(long dev, BYTE Address, char *Host, long port); 
void (_stdcall *LED_AdjustTime)(long dev, BYTE Address, char *Host, long port); 
void (_stdcall *LED_AdjustTimeEx)(long dev, BYTE Address, char *Host, long port, LPSYSTEMTIME psystime); 
void (_stdcall *LED_AdjustTimeEx2)(long dev, BYTE Address, char *Host, long port, WORD Year, WORD Month, WORD Day, WORD Hour, WORD Minute, WORD Second); 
void (_stdcall *LED_SendToScreen)(long dev, BYTE Address, char *Host, long port); 
long (_stdcall *LED_SendToScreenByName)(long dev, char *name); 
void (_stdcall *LED_GetPower)(long dev, BYTE Address, char *Host, long port); 
void (_stdcall *LED_SetPower)(long dev, BYTE Address, char *Host, long port, int Power); 
void (_stdcall *LED_GetLeaf)(long dev, BYTE Address, char *Host, long port); 
void (_stdcall *LED_SetLeaf)(long dev, BYTE Address, char *Host, long port, int value); 
void (_stdcall *LED_SetSwitch)(long dev, BYTE Address, char *Host, long port, int Value); 
void (_stdcall *LED_GetImport)(long dev, BYTE Address, char *Host, long port, int Index); 
void (_stdcall *LED_GetBrightness)(long dev, BYTE Address, char *Host, long port); 
void (_stdcall *LED_SetBrightness)(long dev, BYTE Address, char *Host, long port, int Brightness); 
void (_stdcall *LED_GetAutoPowerList)(long dev, BYTE Address, char *Host, long port); 
void (_stdcall *LED_SetAutoPowerList)(long dev, BYTE Address, char *Host, long port, PAutoPowerTime value); 
void (_stdcall *LED_GetAutoBrightTable)(long dev, BYTE Address, char *Host, long port); 
void (_stdcall *LED_SetAutoBrightTable)(long dev, BYTE Address, char *Host, long port, PBrightTable value); 
void (_stdcall *LED_GetDisplayBuffer)(long dev, BYTE Address, char *Host, long port); 
void (_stdcall *LED_SetIP)(long dev, BYTE Address, char *Host, long port, char* IP); 
void (_stdcall *LED_SetOption)(long optionid, DWORD value); 
void (_stdcall *LED_GetLEDParam)(long dev, BYTE Address, char *Host, long port); 
void (_stdcall *LED_SetLEDParam)(long dev, BYTE Address, char *Host, long port, PBoardParam param); 
 
void (_stdcall *LED_GetNotifyMessage)(PNotifyMessage Notify); 
long (_stdcall *LED_GetNotifyMessageIdent)(void); 
long (_stdcall *LED_GetNotifyMessageCommand)(void); 
long (_stdcall *LED_GetDeviceStatus)(long dev); 
long (_stdcall *LED_GetDeviceNotifyMessage)(long dev, PNotifyMessage Notify); 
 
long (_stdcall *RtfToBitmap)(char* bmpfilename, char *rtffilename, long width, long wordwrap); 
 
long (_stdcall *MakeRoot)(long RootType, long ScreenType); 
long (_stdcall *MakeRootEx)(long RootType, long ScreenType, long survive); 
long (_stdcall *MakeRootEx_4Byte)(long RootType, long ScreenType, long survive); 
long (_stdcall *AddLeaf)(long DisplayTime); //DisplayTime单位为毫秒 
long (_stdcall *AddWindow)(HDC dc,short width, short height, LPRECT rect, long method, long speed, long transparent); 
long (_stdcall *AddWindow2)(HDC dc,short width, short height, long X, long Y, long CX, long CY, long method, long speed, long transparent); 
long (_stdcall *AddPicture)(char *filename, LPRECT rect, long method, long speed, long transparent, long stretch); 
long (_stdcall *AddPicture2)(char *filename, long X, long Y, long CX, long CY, long method, long speed, long transparent, long stretch); 
long (_stdcall *AddRtf)(char *filename, LPRECT rect, long method, long speed, long transparent, long wordwrap); 
long (_stdcall *AddRtf2)(char *filename, long X, long Y, long CX, long CY, long method, long speed, long transparent, long wordwrap); 
long (_stdcall *AddDateTime)(LPRECT rect, long transparent, char *fontname, long fontsize, long fontcolor, long format, long fontstyle); 
long (_stdcall *AddDateTime2)(long X, long Y, long CX, long CY, long transparent, char *fontname, long fontsize, long fontcolor, long format, long fontstyle); 
long (_stdcall *AddString)(char *str, LPRECT rect, long method, long speed, long transparent, long fontset, long fontcolor); 
long (_stdcall *AddString2)(char *str, long X, long Y, long CX, long CY, long method, long speed, long transparent, long fontset, long fontcolor); 
long (_stdcall *AddText)(char *str, LPRECT rect, long method, long speed, long transparent, char *fontname, long fontsize, long fontcolor, long fontstyle); 
long (_stdcall *AddText2)(char *str, long X, long Y, long CX, long CY, long method, long speed, long transparent, char *fontname, long fontsize, long fontcolor, long fontstyle); 
long (_stdcall *AddTextEx)(char *str, LPRECT rect, long method, long speed, long transparent, char *fontname, long fontsize, long fontcolor, long fontstyle , long wordwrap); 
long (_stdcall *AddTextEx2)(char *str, long X, long Y, long CX, long CY, long method, long speed, long transparent, char *fontname, long fontsize, long fontcolor, long fontstyle, long wordwrap); 
long (_stdcall *AddTextVSplit)(char *str, LPRECT rect, long method, long speed, long transparent, long count_a, char *fontname_a, long fontsize_a, long fontcolor_a, long fontstyle_a, char *fontname_b, long fontsize_b, long fontcolor_b, long fontstyle_b); 
long (_stdcall *AddTextVSplit2)(char *str, long X, long Y, long CX, long CY, long method, long speed, long transparent, long count_a, char *fontname_a, long fontsize_a, long fontcolor_a, long fontstyle_a, char *fontname_b, long fontsize_b, long fontcolor_b, long fontstyle_b); 
long (_stdcall *AddMovie)(char *filename, LPRECT rect, long stretch); 
long (_stdcall *AddMovie2)(char *filename, long X, long Y, long CX, long CY, long stretch); 
long (_stdcall *AddCountUp)(LPRECT rect, long transparent, char *fontname, long fontsize, long fontcolor, long format, LPSYSTEMTIME starttime, long fontstyle); 
long (_stdcall *AddCountDown)(LPRECT rect, long transparent, char *fontname, long fontsize, long fontcolor, long format, LPSYSTEMTIME endtime, long fontstyle); 
long (_stdcall *AddCampaignTime)(LPRECT rect, long transparent, char *fontname, long fontsize, long fontcolor, long format, LPSYSTEMTIME starttime, LPSYSTEMTIME endtime, LPSYSTEMTIME campaigntime, long step, long fontstyle); 
 
//发送多行文本,可以自动换行,当文字超出显示范围,按照指定动作方式动作,否则静态显示 
//  RangeMode为超出范围方式 
//      =0表示始终使用指定动作方式 
//      =1表示长度超出显示范围时,使用指定动作方式,否则按照HAlign指定的对齐方式显示 
//      =2表示高度超出显示范围时,使用指定动作方式,否则按照VAlign指定的对齐方式显示 
long (_stdcall *AddTextRange)(char *str, LPRECT rect, long method, long speed, long transparent, long halign, long valign, long rangemode, char *fontname, long fontsize, long fontcolor, long fontstyle, long wordwrap); 
 
/*{ 
  ('DotM|整点半径'); ('DotH|3,6,9点半径'); 
  ('ColorH|小时指针颜色'); ('ColorM|分钟指针颜色'); ('ColorS|秒指针颜色'); 
  ('ColorD|3,6,9点颜色'); ('ColorN|整点颜色'); 
  ('WidthH|小时指针宽度'); ('WidthM|分钟指针宽度'); 
}*/ 
long (_stdcall *AddClock)(LPRECT rect, long transparent, long WidthH, long WidthM, long DotH, long DotM, DWORD ColorH, DWORD ColorM, DWORD ColorS, DWORD ColorD, DWORD ColorN); 
long (_stdcall *AddClock2)(long X, long Y, long CX, long CY, long transparent, long WidthH, long WidthM, long DotH, long DotM, DWORD ColorH, DWORD ColorM, DWORD ColorS, DWORD ColorD, DWORD ColorN); 
 
long (_stdcall *ConstructerOpen)(char* filename); 
long (_stdcall *ConstructerClose)(void); 
long (_stdcall *ConstructerMakeRoot)(char* ledname, long RootType, long ScreenType); 
 
void (_stdcall *LED_CreateReportServer)(WORD port); 
void (_stdcall *LED_ReleaseReportServer)(void); 
long (_stdcall *LED_GetOnlineCount)(void); 
long (_stdcall *LED_GetOnlineList)(BYTE* obuffer); 
void (_stdcall *LED_CreateReportServerEx)(long index, WORD port); 
void (_stdcall *LED_ReleaseReportServerEx)(long index); 
long (_stdcall *LED_GetOnlineCountEx)(long index); 
long (_stdcall *LED_GetOnlineListEx)(long index, BYTE* obuffer); 
 
//////////////////////////////////////////////////////////////////////////////// 
long (_stdcall *LED_GetOnlineList_Java)(void); 
long (_stdcall *LED_GetOnlineItemIP_Java)(long index); 
long (_stdcall *LED_GetOnlineItemPort_Java)(long index); 
long (_stdcall *LED_GetOnlineItemAddr_Java)(long index); 
char* (_stdcall *LED_GetOnlineItemName_Java)(long index); 
//////////////////////////////////////////////////////////////////////////////// 
 
HINSTANCE hInstance; 
 
void LED_Initialize(void) 
{ 
  if ((hInstance=LoadLibrary("LEDSender.Dll"))!=NULL) 
  { 
    LED_SetDebugMode=(void (_stdcall *)(void))GetProcAddress(hInstance,"LED_SetDebugMode"); 
    LED_Open=(long (_stdcall *)(const PDeviceParam, long, long, long))GetProcAddress(hInstance,"LED_Open"); 
    LED_Open2=(long (_stdcall *)(long, long, long, long, long, long, long))GetProcAddress(hInstance,"LED_Open2"); 
    LED_Close=(void (_stdcall *)(long))GetProcAddress(hInstance,"LED_Close"); 
    LED_CloseAll=(void (_stdcall *)(void))GetProcAddress(hInstance,"LED_CloseAll"); 
    LED_Query=(void (_stdcall *)(long, BYTE, char *, long))GetProcAddress(hInstance,"LED_Query"); 
    LED_Reset=(void (_stdcall *)(long, BYTE, char *, long))GetProcAddress(hInstance,"LED_Reset"); 
    LED_AdjustTime=(void (_stdcall *)(long, BYTE, char *, long))GetProcAddress(hInstance,"LED_AdjustTime"); 
    LED_AdjustTimeEx=(void (_stdcall *)(long, BYTE, char *, long, LPSYSTEMTIME))GetProcAddress(hInstance,"LED_AdjustTimeEx"); 
    LED_AdjustTimeEx2=(void (_stdcall *)(long, BYTE, char *, long, WORD, WORD, WORD, WORD, WORD, WORD))GetProcAddress(hInstance,"LED_AdjustTimeEx2"); 
    LED_SendToScreen=(void (_stdcall *)(long, BYTE, char *, long))GetProcAddress(hInstance,"LED_SendToScreen"); 
    LED_SendToScreenByName=(long (_stdcall *)(long, char *))GetProcAddress(hInstance,"LED_SendToScreenByName"); 
    LED_GetPower=(void (_stdcall *)(long, BYTE, char *, long))GetProcAddress(hInstance,"LED_GetPower"); 
    LED_SetPower=(void (_stdcall *)(long, BYTE, char *, long, int))GetProcAddress(hInstance,"LED_SetPower"); 
    LED_GetLeaf=(void (_stdcall *)(long, BYTE, char *, long))GetProcAddress(hInstance,"LED_GetLeaf"); 
    LED_SetLeaf=(void (_stdcall *)(long, BYTE, char *, long, int))GetProcAddress(hInstance,"LED_SetLeaf"); 
    LED_SetSwitch=(void (_stdcall *)(long, BYTE, char *, long, int))GetProcAddress(hInstance,"LED_SetSwitch"); 
    LED_GetImport=(void (_stdcall *)(long, BYTE, char *, long, int))GetProcAddress(hInstance,"LED_GetImport"); 
    LED_GetBrightness=(void (_stdcall *)(long, BYTE, char *, long))GetProcAddress(hInstance,"LED_GetBrightness"); 
    LED_SetBrightness=(void (_stdcall *)(long, BYTE, char *, long, int))GetProcAddress(hInstance,"LED_SetBrightness"); 
    LED_GetAutoPowerList=(void (_stdcall *)(long, BYTE, char *, long))GetProcAddress(hInstance,"LED_GetAutoPowerList"); 
    LED_SetAutoPowerList=(void (_stdcall *)(long, BYTE, char *, long, PAutoPowerTime))GetProcAddress(hInstance,"LED_SetAutoPowerList"); 
    LED_GetAutoBrightTable=(void (_stdcall *)(long, BYTE, char *, long))GetProcAddress(hInstance,"LED_GetAutoBrightTable"); 
    LED_SetAutoBrightTable=(void (_stdcall *)(long, BYTE, char *, long, PBrightTable))GetProcAddress(hInstance,"LED_SetAutoBrightTable"); 
    LED_GetDisplayBuffer=(void (_stdcall *)(long, BYTE, char *, long))GetProcAddress(hInstance,"LED_GetDisplayBuffer"); 
    LED_SetIP=(void (_stdcall *)(long, BYTE, char *, long, char*))GetProcAddress(hInstance,"LED_SetIP"); 
    LED_GetLEDParam=(void (_stdcall *)(long, BYTE, char *, long))GetProcAddress(hInstance,"LED_GetLEDParam"); 
    LED_SetLEDParam=(void (_stdcall *)(long, BYTE, char *, long, PBoardParam))GetProcAddress(hInstance,"LED_SetLEDParam"); 
	LED_SetOption=(void (_stdcall *)(long, DWORD))GetProcAddress(hInstance,"LED_SetOption"); 
 
    LED_GetNotifyMessage=(void (_stdcall *)(PNotifyMessage))GetProcAddress(hInstance,"LED_GetNotifyMessage"); 
    LED_GetNotifyMessageIdent=(long (_stdcall *)(void))GetProcAddress(hInstance,"LED_GetNotifyMessageIdent"); 
    LED_GetNotifyMessageCommand=(long (_stdcall *)(void))GetProcAddress(hInstance,"LED_GetNotifyMessageCommand"); 
    LED_GetDeviceStatus=(long (_stdcall *)(long))GetProcAddress(hInstance,"LED_GetDeviceStatus"); 
    LED_GetDeviceNotifyMessage=(long (_stdcall *)(long, PNotifyMessage))GetProcAddress(hInstance,"LED_GetDeviceNotifyMessage"); 
 
	RtfToBitmap=(long (_stdcall *)(char*, char*, long, long))GetProcAddress(hInstance,"RtfToBitmap"); 
 
    MakeRoot=(long (_stdcall *)(long, long))GetProcAddress(hInstance,"MakeRoot"); 
    MakeRootEx=(long (_stdcall *)(long, long, long))GetProcAddress(hInstance,"MakeRootEx"); 
    MakeRootEx_4Byte=(long (_stdcall *)(long, long, long))GetProcAddress(hInstance,"MakeRootEx_4Byte"); 
    AddLeaf=(long (_stdcall *)(long))GetProcAddress(hInstance,"AddLeaf"); 
    AddWindow=(long (_stdcall *)(HDC, short, short, LPRECT, long, long, long))GetProcAddress(hInstance,"AddWindow"); 
    AddWindow2=(long (_stdcall *)(HDC, short, short, long, long, long, long, long, long, long))GetProcAddress(hInstance,"AddWindow2"); 
    AddPicture=(long (_stdcall *)(char*, LPRECT, long, long, long, long))GetProcAddress(hInstance,"AddPicture"); 
    AddPicture2=(long (_stdcall *)(char*, long, long, long, long, long, long, long, long))GetProcAddress(hInstance,"AddPicture2"); 
    AddRtf=(long (_stdcall *)(char*, LPRECT, long, long, long, long))GetProcAddress(hInstance,"AddRtf"); 
    AddRtf2=(long (_stdcall *)(char*, long, long, long, long, long, long, long, long))GetProcAddress(hInstance,"AddRtf2"); 
    AddDateTime=(long (_stdcall *)(LPRECT, long, char *, long, long, long, long))GetProcAddress(hInstance,"AddDateTime"); 
    AddDateTime2=(long (_stdcall *)(long, long, long, long, long, char *, long, long, long, long))GetProcAddress(hInstance,"AddDateTime2"); 
    AddString=(long (_stdcall *)(char *, LPRECT, long, long, long, long, long))GetProcAddress(hInstance,"AddString"); 
    AddString2=(long (_stdcall *)(char *, long, long, long, long, long, long, long, long, long))GetProcAddress(hInstance,"AddString2"); 
    AddText=(long (_stdcall *)(char *, LPRECT, long, long, long, char *, long, long, long))GetProcAddress(hInstance,"AddText"); 
    AddText2=(long (_stdcall *)(char *, long, long, long, long, long, long, long, char *, long, long, long))GetProcAddress(hInstance,"AddText2"); 
    AddTextEx=(long (_stdcall *)(char *, LPRECT, long, long, long, char *, long, long, long, long))GetProcAddress(hInstance,"AddTextEx"); 
    AddTextEx2=(long (_stdcall *)(char *, long, long, long, long, long, long, long, char *, long, long, long, long))GetProcAddress(hInstance,"AddTextEx2"); 
    AddTextRange=(long (_stdcall *)(char *, LPRECT, long, long, long, long, long, long, char *, long, long, long, long))GetProcAddress(hInstance,"AddTextRange"); 
    AddTextVSplit=(long (_stdcall *)(char *, LPRECT, long, long, long, long, char *, long, long, long, char *, long, long, long))GetProcAddress(hInstance,"AddTextVSplit"); 
    AddTextVSplit2=(long (_stdcall *)(char *, long, long, long, long, long, long, long, long, char *, long, long, long, char *, long, long, long))GetProcAddress(hInstance,"AddTextVSplit2"); 
    AddMovie=(long (_stdcall *)(char *, LPRECT, long))GetProcAddress(hInstance,"AddMovie"); 
    AddMovie2=(long (_stdcall *)(char *, long, long, long, long, long))GetProcAddress(hInstance,"AddMovie2"); 
    AddCountUp=(long (_stdcall *)(LPRECT, long, char *, long, long, long, LPSYSTEMTIME, long))GetProcAddress(hInstance,"AddCountUp"); 
    AddCountDown=(long (_stdcall *)(LPRECT, long, char *, long, long, long, LPSYSTEMTIME, long))GetProcAddress(hInstance,"AddCountDown"); 
    AddCampaignTime=(long (_stdcall *)(LPRECT, long, char *, long, long, long, LPSYSTEMTIME, LPSYSTEMTIME, LPSYSTEMTIME, long, long))GetProcAddress(hInstance,"AddCampaignTime"); 
    AddClock=(long (_stdcall *)(LPRECT, long, long, long, long, long, DWORD, DWORD, DWORD, DWORD, DWORD))GetProcAddress(hInstance,"AddClock"); 
    AddClock2=(long (_stdcall *)(long, long, long, long, long, long, long, long, long, DWORD, DWORD, DWORD, DWORD, DWORD))GetProcAddress(hInstance,"AddClock2"); 
 
    ConstructerOpen=(long (_stdcall *)(char*))GetProcAddress(hInstance,"ConstructerOpen"); 
    ConstructerClose=(long (_stdcall *)(void))GetProcAddress(hInstance,"ConstructerClose"); 
    ConstructerMakeRoot=(long (_stdcall *)(char*, long, long))GetProcAddress(hInstance,"ConstructerMakeRoot"); 
 
    LED_CreateReportServer=(void (_stdcall *)(WORD))GetProcAddress(hInstance,"LED_CreateReportServer"); 
    LED_ReleaseReportServer=(void (_stdcall *)(void))GetProcAddress(hInstance,"LED_ReleaseReportServer"); 
    LED_GetOnlineCount=(long (_stdcall *)(void))GetProcAddress(hInstance,"LED_GetOnlineCount"); 
    LED_GetOnlineList=(long (_stdcall *)(BYTE*))GetProcAddress(hInstance,"LED_GetOnlineList"); 
    LED_CreateReportServerEx=(void (_stdcall *)(long, WORD))GetProcAddress(hInstance,"LED_CreateReportServerEx"); 
    LED_ReleaseReportServerEx=(void (_stdcall *)(long))GetProcAddress(hInstance,"LED_ReleaseReportServerEx"); 
    LED_GetOnlineCountEx=(long (_stdcall *)(long))GetProcAddress(hInstance,"LED_GetOnlineCountEx"); 
    LED_GetOnlineListEx=(long (_stdcall *)(long, BYTE*))GetProcAddress(hInstance,"LED_GetOnlineListEx"); 
 
    //////////////////////////////////////////////////////////////////////////////// 
    LED_GetOnlineList_Java=(long (_stdcall *)(void))GetProcAddress(hInstance,"LED_GetOnlineList_Java"); 
    LED_GetOnlineItemIP_Java=(long (_stdcall *)(long))GetProcAddress(hInstance,"LED_GetOnlineItemIP_Java"); 
    LED_GetOnlineItemPort_Java=(long (_stdcall *)(long))GetProcAddress(hInstance,"LED_GetOnlineItemPort_Java"); 
    LED_GetOnlineItemAddr_Java=(long (_stdcall *)(long))GetProcAddress(hInstance,"LED_GetOnlineItemAddr_Java"); 
    LED_GetOnlineItemName_Java=(char* (_stdcall *)(long))GetProcAddress(hInstance,"LED_GetOnlineItemName_Java"); 
    //////////////////////////////////////////////////////////////////////////////// 
 
    //启动在线控制卡监听服务 
    LED_CreateReportServer(8888); 
  } 
} 
 
void LED_Destroy(void) 
{ 
  LED_ReleaseReportServer(); 
  if (hInstance!=NULL) FreeLibrary(hInstance); 
} 
 
#endif