123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126 |
- // 下列 ifdef 块是创建使从 DLL 导出更简单的
- // 宏的标准方法。此 DLL 中的所有文件都是用命令行上定义的 TCLCOMMAND_EXPORTS
- // 符号编译的。在使用此 DLL 的
- // 任何其他项目上不应定义此符号。这样,源文件中包含此文件的任何其他项目都会将
- // TCLCOMMAND_API 函数视为是从 DLL 导入的,而此 DLL 则将用此宏定义的
- // 符号视为是被导出的。
- #ifdef TCLCOMMAND_EXPORTS
- #define TCLCOMMAND_API __declspec(dllexport)
- #else
- #define TCLCOMMAND_API __declspec(dllimport)
- #endif
- #ifdef EXPORTS_CLASS
- //class TCLCommand;
- #include "CommandParam.h"
- // 此类是从 TCLCommand.dll 导出的
- class TCLCOMMAND_API CTCLCommand {
- public:
- CTCLCommand(void);
- // TODO: 在此添加您的方法。
- bool Open(int nPort, DWORD dwBaudrate, BYTE ByteSize, BYTE Parity, BYTE StopBits);
- void Close();
- bool IsOpen();
- void SetExternalCMDParams(LPCTSTR lpFileName);
- bool GetCommandParams(std::string name, CommandParam& cmdPara);
- void PackingCommand(CommandParam& cmdPara, LPVOID data = NULL, const int& dataLen = 0);
- bool SendCommand(std::string name, CommandParam& cmdPara, LPVOID data = NULL, int dataLen = 0);
- };
- extern TCLCOMMAND_API int nTCLCommand;
- TCLCOMMAND_API int fnTCLCommand(void);
- #else
- // 打开串口;
- TCLCOMMAND_API bool Open(int nPort, DWORD dwBaudrate, BYTE ByteSize, BYTE Parity, BYTE StopBits);
- // 关闭串口;
- TCLCOMMAND_API void Close();
- // 串口是否打开;
- TCLCOMMAND_API bool IsOpen();
- TCLCOMMAND_API void SetExternalCMDParams(LPCTSTR lpFileName);
- // 指令接口;
- TCLCOMMAND_API bool EnterFactory();
- TCLCOMMAND_API bool LeaveFactory();
- TCLCOMMAND_API bool GetProjectId(int &pid);
- TCLCOMMAND_API bool GetSoftVersion(std::string &strValue);
- TCLCOMMAND_API bool GetDeviceId(std::string &strValue);
- TCLCOMMAND_API bool GetClientType(std::string &strValue);
- TCLCOMMAND_API bool GetMAC(std::string &strValue);
- TCLCOMMAND_API bool GetHDCPKey(std::string &strValue);
- TCLCOMMAND_API bool GetHDCPKey22(std::string &strValue);
- TCLCOMMAND_API bool GetWidi(std::string &strValue);
- TCLCOMMAND_API bool GetNetflixESN(std::string &strValue);
- TCLCOMMAND_API bool GetWidevine(std::string &strValue);
- TCLCOMMAND_API bool GetCiKey(std::string &strValue);
- TCLCOMMAND_API bool GetOSDLanguage(std::string &strValue);
- TCLCOMMAND_API bool GetShopLanguage(std::string &strValue);
- TCLCOMMAND_API bool GetChannel(std::string &strValueTCLCOMMAND_API );
- TCLCOMMAND_API bool SetProjectId(int pid);
- TCLCOMMAND_API bool SetProjectId(LPCTSTR lpPid);
- TCLCOMMAND_API bool SetProjectId(const byte* pBuffer, const int& nLen);
- TCLCOMMAND_API bool SetDeviceId(LPCTSTR lpDeviceId);
- TCLCOMMAND_API bool SetDeviceId(const byte* pBuffer, const int &nLen);
- TCLCOMMAND_API bool SetMAC(LPCTSTR lpMac);
- TCLCOMMAND_API bool SetMAC(const byte* pBuffer, const int& nLen);
- TCLCOMMAND_API bool SetHDCPKey(LPCTSTR lpHDCP, bool bHasSpace = FALSE);
- TCLCOMMAND_API bool SetHDCPKey(const byte* pBuffer, const int& nLen);
- TCLCOMMAND_API bool SetHDCPKey22(LPCTSTR lpHDCP22, bool bHasSpace = FALSE);
- TCLCOMMAND_API bool SetHDCPKey22(const byte* pBuffer, const int& nLen);
- TCLCOMMAND_API bool SetNetflixESN(LPCTSTR lpESN, bool bHasSpace = FALSE);
- TCLCOMMAND_API bool SetNetflixESN(const byte* pBuffer, const int& nLen);
- TCLCOMMAND_API bool SetWidi(LPCTSTR lpWidi, bool bHasSpace = FALSE);
- TCLCOMMAND_API bool SetWidi(const byte* pBuffer, const int& nLen);
- TCLCOMMAND_API bool SetWidevine(LPCTSTR lpWidevine, bool bHasSpace = FALSE);
- TCLCOMMAND_API bool SetWidevine(const byte* pBuffer, const int& nLen);
- TCLCOMMAND_API bool SetCiKey(LPCTSTR lpCiKey, bool bHasSpace = FALSE);
- TCLCOMMAND_API bool SetCiKey(const byte* pBuffer, const int& nLen);
- TCLCOMMAND_API bool SetOSDLanguage(LPCTSTR lan, bool bHasSpace = TRUE);
- TCLCOMMAND_API bool SetOSDLanguage(const byte* pBuffer, const int& nLen);
- TCLCOMMAND_API bool SetShopLanguage(LPCTSTR lan, bool bHasSpace = TRUE);
- TCLCOMMAND_API bool SetShopLanguage(const byte* pBuffer, const int& nLen);
- TCLCOMMAND_API bool SetChannel(LPCTSTR channel, bool bHasSpace = TRUE);
- TCLCOMMAND_API bool SetChannel(const byte* pBuffer, const int& nLen);
- TCLCOMMAND_API bool SetWBNormal(LPCTSTR data);
- TCLCOMMAND_API bool SetWBNormal(const byte* pBuffer, const int& nLen);
- TCLCOMMAND_API bool SetWBCool(LPCTSTR data);
- TCLCOMMAND_API bool SetWBCool(const byte* pBuffer, const int& nLen);
- TCLCOMMAND_API bool SetWBWarm(LPCTSTR data);
- TCLCOMMAND_API bool SetWBWarm(const byte* pBuffer, const int& nLenTCLCOMMAND_API );
- TCLCOMMAND_API bool CheckDeviceId();
- TCLCOMMAND_API bool CheckMAC();
- TCLCOMMAND_API bool CheckHDCP();
- TCLCOMMAND_API bool CheckHDCP22();
- TCLCOMMAND_API bool CheckNetflixESN();
- TCLCOMMAND_API bool CheckWidi();
- TCLCOMMAND_API bool CheckWidevine();
- TCLCOMMAND_API bool CheckCikeyTCLCOMMAND_API ();
- TCLCOMMAND_API bool StarWarmUpMode();
- TCLCOMMAND_API bool StopWarmUpModeTCLCOMMAND_API ();
- // 工厂菜单显示与隐藏;
- TCLCOMMAND_API bool ShowFactoryMenu();
- TCLCOMMAND_API bool HideFactoryMenu();
- // 工厂信息内容显示与隐藏;
- TCLCOMMAND_API bool ShowFactoryInformation();
- TCLCOMMAND_API bool HideFactoryInformation();
- // 老化模式的开与关、老化时间读取;
- TCLCOMMAND_API bool EnterAgingModel();
- TCLCOMMAND_API bool LeaveAgingModel();
- TCLCOMMAND_API bool ReadAgingTime(int &min);
- // 红绿蓝增益;
- TCLCOMMAND_API bool SetRedGainRegister(int value);
- TCLCOMMAND_API bool SetGreenGainRegister(int value);
- TCLCOMMAND_API bool SetBlueGainRegister(int value);
- // 红绿蓝偏移;
- TCLCOMMAND_API bool SetRedOffsetRegister(int value);
- TCLCOMMAND_API bool SetGreenOffsetRegister(int value);
- TCLCOMMAND_API bool SetBlueOffsetRegister(int value);
- #endif
|