IDE:visual C 6语言visual c执行IDE:仙盟创梦IDE工程目录核心代码完整代码// TestDLL2Dlg.cpp : implementation file // #include stdafx.h #include TestDLL2.h #include TestDLL2Dlg.h #include stdlib.h #include stdio.h #ifdef _DEBUG #define new DEBUG_NEW #undef THIS_FILE static char THIS_FILE[] __FILE__; #endif ///////////////////////////////////////////////////////////////////////////// // CAboutDlg dialog used for App About class CAboutDlg : public CDialog { public: CAboutDlg(); // Dialog Data //{{AFX_DATA(CAboutDlg) enum { IDD IDD_ABOUTBOX }; //}}AFX_DATA // ClassWizard generated virtual function overrides //{{AFX_VIRTUAL(CAboutDlg) protected: virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support //}}AFX_VIRTUAL // Implementation protected: //{{AFX_MSG(CAboutDlg) //}}AFX_MSG DECLARE_MESSAGE_MAP() }; CAboutDlg::CAboutDlg() : CDialog(CAboutDlg::IDD) { //{{AFX_DATA_INIT(CAboutDlg) //}}AFX_DATA_INIT } //Application global variables unsigned char LastRFID[4]; unsigned char LastHandID[2]; unsigned char c_hex[]{0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F}; void CAboutDlg::DoDataExchange(CDataExchange* pDX) { CDialog::DoDataExchange(pDX); //{{AFX_DATA_MAP(CAboutDlg) //}}AFX_DATA_MAP } BEGIN_MESSAGE_MAP(CAboutDlg, CDialog) //{{AFX_MSG_MAP(CAboutDlg) // No message handlers //}}AFX_MSG_MAP END_MESSAGE_MAP() ///////////////////////////////////////////////////////////////////////////// // CTestDLL2Dlg dialog CTestDLL2Dlg::CTestDLL2Dlg(CWnd* pParent /*NULL*/) : CDialog(CTestDLL2Dlg::IDD, pParent) { //{{AFX_DATA_INIT(CTestDLL2Dlg) m_txtRFID _T(); m_txtHandId _T(); m_DoorID 5; m_StatusList _T(); m_txtRTC _T(); m_txtStatus _T(); m_CardType -1; m_txtCustomer _T(); //}}AFX_DATA_INIT // Note that LoadIcon does not require a subsequent DestroyIcon in Win32 m_hIcon AfxGetApp()-LoadIcon(IDR_MAINFRAME); } void CTestDLL2Dlg::DoDataExchange(CDataExchange* pDX) { CDialog::DoDataExchange(pDX); //{{AFX_DATA_MAP(CTestDLL2Dlg) DDX_Control(pDX, IDC_SetOffCard2Btn, m_SetOffCard2Btn); DDX_Control(pDX, IDC_SetOnCard2Btn, m_SetOnCard2Btn); DDX_Control(pDX, IDC_MangerCardBtn, m_MangerCard); DDX_Control(pDX, IDC_GetTypeBtn, m_GetType); DDX_Control(pDX, IDC_COMBO2, m_CardTypeCMB); DDX_Control(pDX, IDC_SetRTCBtn, m_SetRTCBtn); DDX_Control(pDX, IDC_GetRTCBtn, m_GetRTCBtn); DDX_Control(pDX, IDC_SetHandId, m_SetHandIdBtn); DDX_Control(pDX, IDC_COMBO1, m_DoorCMB); DDX_Control(pDX, IDC_GetHandIdBtn, m_GetHandId); DDX_Control(pDX, IDC_ReadRFIDBtn, m_ReadRFIDBtn); DDX_Control(pDX, IDC_ClearCardBtn, m_ClearCardBtn); DDX_Control(pDX, IDC_SetCardBtn, m_SetCardBtn); DDX_Control(pDX, IDC_CloseReader, m_CloseReaderBtn); DDX_Control(pDX, IDC_OpenReader, m_OpenReaderBtn); DDX_Text(pDX, IDC_txtRFID, m_txtRFID); DDX_Text(pDX, IDC_txtHandId, m_txtHandId); DDV_MaxChars(pDX, m_txtHandId, 4); DDX_CBIndex(pDX, IDC_COMBO1, m_DoorID); DDX_Text(pDX, IDC_txtRTC, m_txtRTC); DDX_Text(pDX, IDC_txtStatus, m_txtStatus); DDX_CBIndex(pDX, IDC_COMBO2, m_CardType); DDX_Text(pDX, IDC_txtCustomer, m_txtCustomer); //}}AFX_DATA_MAP } BEGIN_MESSAGE_MAP(CTestDLL2Dlg, CDialog) //{{AFX_MSG_MAP(CTestDLL2Dlg) ON_WM_SYSCOMMAND() ON_WM_PAINT() ON_WM_QUERYDRAGICON() ON_BN_CLICKED(IDC_OpenReader, OnOpenReader) ON_BN_CLICKED(IDC_CloseReader, OnCloseReader) ON_BN_CLICKED(IDC_ReadRFIDBtn, OnReadRFIDBtn) ON_BN_CLICKED(IDC_SetCardBtn, OnSetCardBtn) ON_BN_CLICKED(IDC_ClearCardBtn, OnClearCardBtn) ON_WM_CLOSE() ON_BN_CLICKED(IDC_GetHandIdBtn, OnGetHandId) ON_BN_CLICKED(IDC_SetHandId, OnSetHandId) ON_CBN_EDITCHANGE(IDC_COMBO1, OnEditchangeCombo1) ON_BN_CLICKED(IDC_GetRTCBtn, OnGetRTCBtn) ON_BN_CLICKED(IDC_SetRTCBtn, OnSetRTCBtn) ON_BN_CLICKED(IDC_GetTypeBtn, OnGetTypeBtn) // ON_BN_CLICKED(IDC_MangerCardBtn, OnMangerCardBtn) ON_BN_CLICKED(IDC_SetOnCard2Btn, OnSetOnCard2Btn) ON_BN_CLICKED(IDC_SetOffCard2Btn, OnSetOffCard2Btn) ON_EN_CHANGE(IDC_txtCustomer, OnChangetxtCustomer) //}}AFX_MSG_MAP END_MESSAGE_MAP() ///////////////////////////////////////////////////////////////////////////// // CTestDLL2Dlg message handlers BOOL CTestDLL2Dlg::OnInitDialog() { CDialog::OnInitDialog(); // Add About... menu item to system menu. // IDM_ABOUTBOX must be in the system command range. ASSERT((IDM_ABOUTBOX 0xFFF0) IDM_ABOUTBOX); ASSERT(IDM_ABOUTBOX 0xF000); CMenu* pSysMenu GetSystemMenu(FALSE); if (pSysMenu ! NULL) { CString strAboutMenu; strAboutMenu.LoadString(IDS_ABOUTBOX); if (!strAboutMenu.IsEmpty()) { pSysMenu-AppendMenu(MF_SEPARATOR); pSysMenu-AppendMenu(MF_STRING, IDM_ABOUTBOX, strAboutMenu); } } // Set the icon for this dialog. The framework does this automatically // when the applications main window is not a dialog SetIcon(m_hIcon, TRUE); // Set big icon SetIcon(m_hIcon, FALSE); // Set small icon // TODO: Add extra initialization here //hDLLLoadLibrary(RF002Reader.DLL); hDLLLoadLibrary(RF003Reader.DLL); m_CloseReaderBtn.EnableWindow(false); return TRUE; // return TRUE unless you set the focus to a control } void CTestDLL2Dlg::OnSysCommand(UINT nID, LPARAM lParam) { if ((nID 0xFFF0) IDM_ABOUTBOX) { CAboutDlg dlgAbout; dlgAbout.DoModal(); } else { CDialog::OnSysCommand(nID, lParam); } } // If you add a minimize button to your dialog, you will need the code below // to draw the icon. For MFC applications using the document/view model, // this is automatically done for you by the framework. void CTestDLL2Dlg::OnPaint() { if (IsIconic()) { CPaintDC dc(this); // device context for painting SendMessage(WM_ICONERASEBKGND, (WPARAM) dc.GetSafeHdc(), 0); // Center icon in client rectangle int cxIcon GetSystemMetrics(SM_CXICON); int cyIcon GetSystemMetrics(SM_CYICON); CRect rect; GetClientRect(rect); int x (rect.Width() - cxIcon 1) / 2; int y (rect.Height() - cyIcon 1) / 2; // Draw the icon dc.DrawIcon(x, y, m_hIcon); } else { CDialog::OnPaint(); } } // The system calls this to obtain the cursor to display while the user drags // the minimized window. HCURSOR CTestDLL2Dlg::OnQueryDragIcon() { return (HCURSOR) m_hIcon; } unsigned char CharToHexChar(unsigned char ch) { if((ch0)(ch9)) { return ch-0x30; } else if((chA)(chF)) { return ch-A10; } else if((cha)(chf)) { return ch-a10; } else { return 0; } } void CTestDLL2Dlg::OnOpenReader() { // TODO: Add your control notification handler code here CString str; typedef HANDLE (__stdcall *MYPROC1)(int lpt); MYPROC1 ProcAdd1; ProcAdd1 (MYPROC1)GetProcAddress(hDLL, OpenReader); Hcomm(ProcAdd1)(1); //RF003读卡器端口号码固定传1 if (Hcomm0) { m_OpenReaderBtn.EnableWindow(false); m_CloseReaderBtn.EnableWindow(true); m_txtStatus找到USB RF003读卡器; } else { m_txtStatusUSB接口上未找到RF003读卡器; } UpdateData(false); } void CTestDLL2Dlg::OnCloseReader() { // TODO: Add your control notification handler code here typedef void (__stdcall *MYPROC2)(void); MYPROC2 ProcAdd2; ProcAdd2 (MYPROC2)GetProcAddress(hDLL,CloseReader); (ProcAdd2)(); UpdateData(false); m_OpenReaderBtn.EnableWindow(true); m_CloseReaderBtn.EnableWindow(false); } void CTestDLL2Dlg::OnReadRFIDBtn() { // TODO: Add your control notification handler code here unsigned char c_hex[]{0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F}; typedef DWORD (__stdcall *MYPROC3)(unsigned char *RFID); DWORD ret; unsigned char RFID[4]; int i; MYPROC3 ProcAdd3; ProcAdd3(MYPROC3)GetProcAddress(hDLL,ReadRFID); m_ReadRFIDBtn.EnableWindow(false); ret(ProcAdd3)(RFID); if (ret0) { m_txtRFID; for (i0;i4;i) { m_txtRFIDm_txtRFIDCString(c_hex[RFID[i]/16])CString(c_hex[RFID[i]%16]); LastRFID[i]RFID[i]; } m_txtStatusRead RFID OK; }else{ m_txtStatusRead RFID Err: 0xCString(c_hex[ret/16])CString(c_hex[ret%16]); } UpdateData(false); m_ReadRFIDBtn.EnableWindow(true); } void CTestDLL2Dlg::OnSetCardBtn() { // TODO: Add your control notification handler code here //unsigned char c_hex[]{0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F}; typedef DWORD (__stdcall *MYPROC4)(unsigned char* RFID); DWORD ret; unsigned char RFID[4]; int i; MYPROC4 ProcAdd4; ProcAdd4(MYPROC4)GetProcAddress(hDLL,SetCard); m_SetCardBtn.EnableWindow(false); //将最后读到的RFID码传输到发卡器,发卡指令需要验证RFID码 RFID[0]LastRFID[0]; RFID[1]LastRFID[1]; RFID[2]LastRFID[2]; RFID[3]LastRFID[3]; ret(ProcAdd4)(RFID); if (ret0) { m_txtRFID; for (i0;i4;i) { m_txtRFIDm_txtRFIDCString(c_hex[RFID[i]/16])CString(c_hex[RFID[i]%16]); } m_txtStatusSetCard OK; }else{ if (ret7) { m_txtStatus发卡异常发现读卡器内部时间有误请更新读卡器时间; }else m_txtStatusSetCard Err: 0xCString(c_hex[ret/16])CString(c_hex[ret%16]); } UpdateData(false); m_SetCardBtn.EnableWindow(true); } void CTestDLL2Dlg::OnClearCardBtn() { // TODO: Add your control notification handler code here //unsigned char c_hex[]{0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F}; typedef DWORD (__stdcall *MYPROC5)(unsigned char* RFID); DWORD ret; unsigned char RFID[4]; int i; MYPROC5 ProcAdd5; ProcAdd5(MYPROC5)GetProcAddress(hDLL,ClearCard); m_ClearCardBtn.EnableWindow(false); ret(ProcAdd5)(RFID); if (ret0) { m_txtRFID; for (i0;i4;i) { m_txtRFIDm_txtRFIDCString(c_hex[RFID[i]/16])CString(c_hex[RFID[i]%16]); } m_txtStatusClear OK; }else{ m_txtStatusClear Err: 0xCString(c_hex[ret/16])CString(c_hex[ret%16]); } UpdateData(false); m_ClearCardBtn.EnableWindow(true); } void CTestDLL2Dlg::OnOK() { // TODO: Add extra validation here CDialog::OnOK(); } void CTestDLL2Dlg::OnClose() { // TODO: Add your message handler code here and/or call default CDialog::OnClose(); FreeLibrary(hDLL); } void CTestDLL2Dlg::OnGetHandId() { // TODO: Add your control notification handler code here //unsigned char c_hex[]{0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F}; typedef DWORD (__stdcall *MYPROC6)(unsigned char* HandId); DWORD ret; unsigned char HandId[4]; MYPROC6 ProcAdd6; ProcAdd6(MYPROC6)GetProcAddress(hDLL,GetHandId); m_GetHandId.EnableWindow(false); ret(ProcAdd6)(HandId); if (ret0) { m_txtHandIdCString(c_hex[HandId[0]/16])CString(c_hex[HandId[0]%16])CString(c_hex[HandId[1]/16])CString(c_hex[HandId[1]%16]); LastHandID[0]HandId[0]; //保存最后读到的手牌码供发卡指令调用 LastHandID[1]HandId[1]; if (HandId[2]5) m_DoorID5; else m_DoorIDHandId[2]; m_txtStatusRead HandID OK; }else{ m_txtStatusRead HandID Err: 0xCString(c_hex[ret/16])CString(c_hex[ret%16]); } UpdateData(false); m_GetHandId.EnableWindow(true); } void CTestDLL2Dlg::OnSetHandId() { // TODO: Add your control notification handler code here CString HandIdtext; unsigned int HandIdVal; typedef DWORD (__stdcall *MYPROC7)(unsigned char* HandId); DWORD ret; CEdit* m_HandId (CEdit*) GetDlgItem(IDC_txtHandId); m_HandId-GetWindowText(HandIdtext); // Convert the hex string in the edit box to an integer. HandIdVal strtoul(0x HandIdtext, 0, 16); unsigned char HandId[4]; int i; MYPROC7 ProcAdd7; ProcAdd7(MYPROC7)GetProcAddress(hDLL,SetHandId); m_SetHandIdBtn.EnableWindow(false); //将最后读到的RFID码传输到发卡器,发卡指令需要验证RFID码 UpdateData(true); HandId[0]HandIdVal/256; HandId[1]HandIdVal%256; HandId[2]m_DoorID; HandId[3]HandId[0]^HandId[1]^HandId[2]; ret(ProcAdd7)(HandId); //m_txtHandIdCString(c_hex[HandId[1]/16])CString(c_hex[HandId[1]%16]); //UpdateData(false); //* if (ret0) { m_txtHandId; for (i0;i2;i) { m_txtHandIdm_txtHandIdCString(c_hex[HandId[i]/16])CString(c_hex[HandId[i]%16]); } m_txtStatusSet HandId OK; }else{ m_txtStatusSet HandId Err: 0xCString(c_hex[ret/16])CString(c_hex[ret%16]); } UpdateData(false); //*/ m_SetHandIdBtn.EnableWindow(true); } void CTestDLL2Dlg::OnEditchangeCombo1() { // TODO: Add your control notification handler code here UpdateData(true); } void CTestDLL2Dlg::OnGetRTCBtn() { // TODO: Add your control notification handler code here //unsigned char c_hex[]{0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F}; typedef DWORD (__stdcall *MYPROC8)(unsigned char* RTC); DWORD ret; unsigned char RTCBuf[8]; MYPROC8 ProcAdd8; ProcAdd8(MYPROC8)GetProcAddress(hDLL,GetRTC); m_GetRTCBtn.EnableWindow(false); ret(ProcAdd8)(RTCBuf); if (ret0) { m_txtRTCCString(c_hex[RTCBuf[0]/16])CString(c_hex[RTCBuf[0]%16])/CString(c_hex[RTCBuf[1]/16])CString(c_hex[RTCBuf[1]%16])/ CString(c_hex[RTCBuf[2]/16])CString(c_hex[RTCBuf[2]%16]) CString(c_hex[RTCBuf[3]/16])CString(c_hex[RTCBuf[3]%16]): CString(c_hex[RTCBuf[4]/16])CString(c_hex[RTCBuf[4]%16]):CString(c_hex[RTCBuf[5]/16])CString(c_hex[RTCBuf[5]%16]); m_txtStatusRead RTC OK; }else{ m_txtStatusRead RTC Err; } UpdateData(false); m_GetRTCBtn.EnableWindow(true); } //读卡器内部时间与电脑时间同步 void CTestDLL2Dlg::OnSetRTCBtn() { // TODO: Add your control notification handler code here CTime time CTime::GetCurrentTime(); int m_nYear time.GetYear(); ///年 int m_nMonth time.GetMonth(); ///月 int m_nDay time.GetDay(); ///日 int m_nHour time.GetHour(); ///小时 int m_nMinute time.GetMinute(); ///分钟 int m_nSecond time.GetSecond(); ///秒 //还可以用CTime::Format函数将CTime对象转换为字符串对象 //CString m_strTime time.Format(%Y-%m-%d %H:%M:%S); typedef DWORD (__stdcall *MYPROC9)(unsigned char* RTC); DWORD ret; unsigned char RTCBuf[6]; MYPROC9 ProcAdd9; ProcAdd9(MYPROC9)GetProcAddress(hDLL,SetRTC); m_SetRTCBtn.EnableWindow(false); m_nYearm_nYear-2000; RTCBuf[0](m_nYear/10)*16(m_nYear%10); RTCBuf[1](m_nMonth/10)*16(m_nMonth%10); RTCBuf[2](m_nDay/10)*16(m_nDay%10); RTCBuf[3](m_nHour/10)*16(m_nHour%10); RTCBuf[4](m_nMinute/10)*16(m_nMinute%10); RTCBuf[5](m_nSecond/10)*16(m_nSecond%10); ret(ProcAdd9)(RTCBuf); if (ret0) { m_txtStatusSet RTC DATE OK; }else{ m_txtStatusSetRTC DATE Err; } UpdateData(false); m_SetRTCBtn.EnableWindow(true); } void CTestDLL2Dlg::OnGetTypeBtn() { typedef DWORD (__stdcall *MYPROC)(unsigned char* CardType); DWORD ret; unsigned char CardType[4]; MYPROC ProcAdd; ProcAdd(MYPROC)GetProcAddress(hDLL,GetHandType); m_GetType.EnableWindow(false); ret(ProcAdd)(CardType); m_CardType0; if (ret0) { m_txtCustomerCString(c_hex[CardType[0]/16])CString(c_hex[CardType[0]%16])CString(c_hex[CardType[1]/16])CString(c_hex[CardType[1]%16]); if (CardType[2]0x45) m_CardType1; if (CardType[2]0x42) m_CardType2; if (CardType[2]0x52) m_CardType3; if (CardType[2]0x80) m_CardType4; if (CardType[2]0x90) m_CardType5; if (CardType[2]0xA0) m_CardType6; if (CardType[2]0xB0) m_CardType7; m_txtStatusRead Type OK; }else{ m_txtStatusRead Type Err: 0xCString(c_hex[ret/16])CString(c_hex[ret%16]); } UpdateData(false); m_GetType.EnableWindow(true); } //配对手牌码发卡模式 void CTestDLL2Dlg::OnSetOnCard2Btn() { typedef DWORD (__stdcall *MYPROC)(unsigned char* HandId); DWORD ret; unsigned char HandId[4]; MYPROC ProcAdd; ProcAdd(MYPROC)GetProcAddress(hDLL,SetCard2); m_SetOnCard2Btn.EnableWindow(false); //将最后读到的手牌码码传输到发卡器,发卡指令需要验证手牌码 HandId[0]LastHandID[0]; HandId[1]LastHandID[1]; HandId[2]0; HandId[3]0; ret(ProcAdd)(HandId); if (ret0) { m_txtHandId; m_txtHandIdCString(c_hex[HandId[0]/16])CString(c_hex[HandId[0]%16])CString(c_hex[HandId[1]/16])CString(c_hex[HandId[1]%16]); m_txtStatus配对手牌码发卡成功...; }else{ if (ret7) { m_txtStatus发卡异常发现读卡器内部时间有误请更新读卡器时间; }else m_txtStatusSetCard Err: 0xCString(c_hex[ret/16])CString(c_hex[ret%16]); } UpdateData(false); m_SetOnCard2Btn.EnableWindow(true); } void CTestDLL2Dlg::OnSetOffCard2Btn() { // TODO: Add your control notification handler code here typedef DWORD (__stdcall *MYPROC)(unsigned char* HandId); DWORD ret; unsigned char HandId[4]; int i; MYPROC ProcAdd; ProcAdd(MYPROC)GetProcAddress(hDLL,ClearCard2); m_SetOffCard2Btn.EnableWindow(false); ret(ProcAdd)(HandId); if (ret0) { m_txtHandIdCString(c_hex[HandId[0]/16])CString(c_hex[HandId[0]%16])CString(c_hex[HandId[1]/16])CString(c_hex[HandId[1]%16]); m_txtStatusClear Return HandId OK; }else{ m_txtStatusClear Err: 0xCString(c_hex[ret/16])CString(c_hex[ret%16]); } UpdateData(false); m_SetOffCard2Btn.EnableWindow(true); } void CTestDLL2Dlg::OnChangetxtCustomer() { // TODO: If this is a RICHEDIT control, the control will not // send this notification unless you override the CDialog::OnInitDialog() // function and call CRichEditCtrl().SetEventMask() // with the ENM_CHANGE flag ORed into the mask. // TODO: Add your control notification handler code here }人人皆为创造者共创方能共成长每个人都是使用者也是创造者是数字世界的消费者更是价值的生产者与分享者。在智能时代的浪潮里单打独斗的发展模式早已落幕唯有开放连接、创意共创、利益共享才能让个体价值汇聚成生态合力让技术与创意双向奔赴实现平台与伙伴的快速成长、共赢致远。原创永久分成共赴星辰大海原创创意共创、永久收益分成是东方仙盟始终坚守的核心理念。我们坚信每一份原创智慧都值得被尊重与回馈以永久分成锚定共创初心让创意者长期享有价值红利携手万千伙伴向着科技星辰大海笃定前行拥抱硅基 生命与数字智能交融的未来共筑跨越时代的数字文明共同体。东方仙盟拥抱知识开源共筑数字新生态在全球化与数字化浪潮中东方仙盟始终秉持开放协作、知识共享的理念积极拥抱开源技术与开放标准。我们相信唯有打破技术壁垒、汇聚全球智慧才能真正推动行业的可持续发展。开源赋能中小商户通过将前端异常检测、跨系统数据互联等核心能力开源化东方仙盟为全球中小商户提供了低成本、高可靠的技术解决方案让更多商家能够平等享受数字转型的红利。共建行业标准我们积极参与国际技术社区与全球开发者、合作伙伴共同制定开放协议 与技术规范推动跨境零售、文旅、餐饮等多业态的系统互联互通构建更加公平、高效的数字生态。知识普惠共促发展通过开源社区 、技术文档与培训体系东方仙盟致力于将前沿技术转化为可落地的行业实践赋能全球合作伙伴共同培育创新人才推动数字经济 的普惠式增长阿雪技术观在科技发展浪潮中我们不妨积极投身技术共享。不满足于做受益者更要主动担当贡献者 。无论是分享代码、撰写技术博客还是参与开源项目 维护改进每一个微小举动都可能蕴含推动技术进步的巨大能量。东方仙盟是汇聚力量的天地我们携手在此探索硅基 生命为科技进步添砖加瓦。Hey folks, in this wild tech - driven world, why not dive headfirst into the whole tech - sharing scene? Dont just be the one reaping all the benefits; step up and be a contributor too. Whether youre tossing out your code snippets , hammering out some tech blogs, or getting your hands dirty with maintaining and sprucing up open - source projects, every little thing you do might just end up being a massive force that pushes tech forward. And guess what? The Eastern FairyAlliance is this awesome place where we all come together. Were gonna team up and explore the whole silicon - based life thing, and in the process, well be fueling the growth of technology
游泳馆柜锁参数8.5接口VC-幽冥大陆(一百32)—东方仙盟
IDE:visual C 6语言visual c执行IDE:仙盟创梦IDE工程目录核心代码完整代码// TestDLL2Dlg.cpp : implementation file // #include stdafx.h #include TestDLL2.h #include TestDLL2Dlg.h #include stdlib.h #include stdio.h #ifdef _DEBUG #define new DEBUG_NEW #undef THIS_FILE static char THIS_FILE[] __FILE__; #endif ///////////////////////////////////////////////////////////////////////////// // CAboutDlg dialog used for App About class CAboutDlg : public CDialog { public: CAboutDlg(); // Dialog Data //{{AFX_DATA(CAboutDlg) enum { IDD IDD_ABOUTBOX }; //}}AFX_DATA // ClassWizard generated virtual function overrides //{{AFX_VIRTUAL(CAboutDlg) protected: virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support //}}AFX_VIRTUAL // Implementation protected: //{{AFX_MSG(CAboutDlg) //}}AFX_MSG DECLARE_MESSAGE_MAP() }; CAboutDlg::CAboutDlg() : CDialog(CAboutDlg::IDD) { //{{AFX_DATA_INIT(CAboutDlg) //}}AFX_DATA_INIT } //Application global variables unsigned char LastRFID[4]; unsigned char LastHandID[2]; unsigned char c_hex[]{0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F}; void CAboutDlg::DoDataExchange(CDataExchange* pDX) { CDialog::DoDataExchange(pDX); //{{AFX_DATA_MAP(CAboutDlg) //}}AFX_DATA_MAP } BEGIN_MESSAGE_MAP(CAboutDlg, CDialog) //{{AFX_MSG_MAP(CAboutDlg) // No message handlers //}}AFX_MSG_MAP END_MESSAGE_MAP() ///////////////////////////////////////////////////////////////////////////// // CTestDLL2Dlg dialog CTestDLL2Dlg::CTestDLL2Dlg(CWnd* pParent /*NULL*/) : CDialog(CTestDLL2Dlg::IDD, pParent) { //{{AFX_DATA_INIT(CTestDLL2Dlg) m_txtRFID _T(); m_txtHandId _T(); m_DoorID 5; m_StatusList _T(); m_txtRTC _T(); m_txtStatus _T(); m_CardType -1; m_txtCustomer _T(); //}}AFX_DATA_INIT // Note that LoadIcon does not require a subsequent DestroyIcon in Win32 m_hIcon AfxGetApp()-LoadIcon(IDR_MAINFRAME); } void CTestDLL2Dlg::DoDataExchange(CDataExchange* pDX) { CDialog::DoDataExchange(pDX); //{{AFX_DATA_MAP(CTestDLL2Dlg) DDX_Control(pDX, IDC_SetOffCard2Btn, m_SetOffCard2Btn); DDX_Control(pDX, IDC_SetOnCard2Btn, m_SetOnCard2Btn); DDX_Control(pDX, IDC_MangerCardBtn, m_MangerCard); DDX_Control(pDX, IDC_GetTypeBtn, m_GetType); DDX_Control(pDX, IDC_COMBO2, m_CardTypeCMB); DDX_Control(pDX, IDC_SetRTCBtn, m_SetRTCBtn); DDX_Control(pDX, IDC_GetRTCBtn, m_GetRTCBtn); DDX_Control(pDX, IDC_SetHandId, m_SetHandIdBtn); DDX_Control(pDX, IDC_COMBO1, m_DoorCMB); DDX_Control(pDX, IDC_GetHandIdBtn, m_GetHandId); DDX_Control(pDX, IDC_ReadRFIDBtn, m_ReadRFIDBtn); DDX_Control(pDX, IDC_ClearCardBtn, m_ClearCardBtn); DDX_Control(pDX, IDC_SetCardBtn, m_SetCardBtn); DDX_Control(pDX, IDC_CloseReader, m_CloseReaderBtn); DDX_Control(pDX, IDC_OpenReader, m_OpenReaderBtn); DDX_Text(pDX, IDC_txtRFID, m_txtRFID); DDX_Text(pDX, IDC_txtHandId, m_txtHandId); DDV_MaxChars(pDX, m_txtHandId, 4); DDX_CBIndex(pDX, IDC_COMBO1, m_DoorID); DDX_Text(pDX, IDC_txtRTC, m_txtRTC); DDX_Text(pDX, IDC_txtStatus, m_txtStatus); DDX_CBIndex(pDX, IDC_COMBO2, m_CardType); DDX_Text(pDX, IDC_txtCustomer, m_txtCustomer); //}}AFX_DATA_MAP } BEGIN_MESSAGE_MAP(CTestDLL2Dlg, CDialog) //{{AFX_MSG_MAP(CTestDLL2Dlg) ON_WM_SYSCOMMAND() ON_WM_PAINT() ON_WM_QUERYDRAGICON() ON_BN_CLICKED(IDC_OpenReader, OnOpenReader) ON_BN_CLICKED(IDC_CloseReader, OnCloseReader) ON_BN_CLICKED(IDC_ReadRFIDBtn, OnReadRFIDBtn) ON_BN_CLICKED(IDC_SetCardBtn, OnSetCardBtn) ON_BN_CLICKED(IDC_ClearCardBtn, OnClearCardBtn) ON_WM_CLOSE() ON_BN_CLICKED(IDC_GetHandIdBtn, OnGetHandId) ON_BN_CLICKED(IDC_SetHandId, OnSetHandId) ON_CBN_EDITCHANGE(IDC_COMBO1, OnEditchangeCombo1) ON_BN_CLICKED(IDC_GetRTCBtn, OnGetRTCBtn) ON_BN_CLICKED(IDC_SetRTCBtn, OnSetRTCBtn) ON_BN_CLICKED(IDC_GetTypeBtn, OnGetTypeBtn) // ON_BN_CLICKED(IDC_MangerCardBtn, OnMangerCardBtn) ON_BN_CLICKED(IDC_SetOnCard2Btn, OnSetOnCard2Btn) ON_BN_CLICKED(IDC_SetOffCard2Btn, OnSetOffCard2Btn) ON_EN_CHANGE(IDC_txtCustomer, OnChangetxtCustomer) //}}AFX_MSG_MAP END_MESSAGE_MAP() ///////////////////////////////////////////////////////////////////////////// // CTestDLL2Dlg message handlers BOOL CTestDLL2Dlg::OnInitDialog() { CDialog::OnInitDialog(); // Add About... menu item to system menu. // IDM_ABOUTBOX must be in the system command range. ASSERT((IDM_ABOUTBOX 0xFFF0) IDM_ABOUTBOX); ASSERT(IDM_ABOUTBOX 0xF000); CMenu* pSysMenu GetSystemMenu(FALSE); if (pSysMenu ! NULL) { CString strAboutMenu; strAboutMenu.LoadString(IDS_ABOUTBOX); if (!strAboutMenu.IsEmpty()) { pSysMenu-AppendMenu(MF_SEPARATOR); pSysMenu-AppendMenu(MF_STRING, IDM_ABOUTBOX, strAboutMenu); } } // Set the icon for this dialog. The framework does this automatically // when the applications main window is not a dialog SetIcon(m_hIcon, TRUE); // Set big icon SetIcon(m_hIcon, FALSE); // Set small icon // TODO: Add extra initialization here //hDLLLoadLibrary(RF002Reader.DLL); hDLLLoadLibrary(RF003Reader.DLL); m_CloseReaderBtn.EnableWindow(false); return TRUE; // return TRUE unless you set the focus to a control } void CTestDLL2Dlg::OnSysCommand(UINT nID, LPARAM lParam) { if ((nID 0xFFF0) IDM_ABOUTBOX) { CAboutDlg dlgAbout; dlgAbout.DoModal(); } else { CDialog::OnSysCommand(nID, lParam); } } // If you add a minimize button to your dialog, you will need the code below // to draw the icon. For MFC applications using the document/view model, // this is automatically done for you by the framework. void CTestDLL2Dlg::OnPaint() { if (IsIconic()) { CPaintDC dc(this); // device context for painting SendMessage(WM_ICONERASEBKGND, (WPARAM) dc.GetSafeHdc(), 0); // Center icon in client rectangle int cxIcon GetSystemMetrics(SM_CXICON); int cyIcon GetSystemMetrics(SM_CYICON); CRect rect; GetClientRect(rect); int x (rect.Width() - cxIcon 1) / 2; int y (rect.Height() - cyIcon 1) / 2; // Draw the icon dc.DrawIcon(x, y, m_hIcon); } else { CDialog::OnPaint(); } } // The system calls this to obtain the cursor to display while the user drags // the minimized window. HCURSOR CTestDLL2Dlg::OnQueryDragIcon() { return (HCURSOR) m_hIcon; } unsigned char CharToHexChar(unsigned char ch) { if((ch0)(ch9)) { return ch-0x30; } else if((chA)(chF)) { return ch-A10; } else if((cha)(chf)) { return ch-a10; } else { return 0; } } void CTestDLL2Dlg::OnOpenReader() { // TODO: Add your control notification handler code here CString str; typedef HANDLE (__stdcall *MYPROC1)(int lpt); MYPROC1 ProcAdd1; ProcAdd1 (MYPROC1)GetProcAddress(hDLL, OpenReader); Hcomm(ProcAdd1)(1); //RF003读卡器端口号码固定传1 if (Hcomm0) { m_OpenReaderBtn.EnableWindow(false); m_CloseReaderBtn.EnableWindow(true); m_txtStatus找到USB RF003读卡器; } else { m_txtStatusUSB接口上未找到RF003读卡器; } UpdateData(false); } void CTestDLL2Dlg::OnCloseReader() { // TODO: Add your control notification handler code here typedef void (__stdcall *MYPROC2)(void); MYPROC2 ProcAdd2; ProcAdd2 (MYPROC2)GetProcAddress(hDLL,CloseReader); (ProcAdd2)(); UpdateData(false); m_OpenReaderBtn.EnableWindow(true); m_CloseReaderBtn.EnableWindow(false); } void CTestDLL2Dlg::OnReadRFIDBtn() { // TODO: Add your control notification handler code here unsigned char c_hex[]{0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F}; typedef DWORD (__stdcall *MYPROC3)(unsigned char *RFID); DWORD ret; unsigned char RFID[4]; int i; MYPROC3 ProcAdd3; ProcAdd3(MYPROC3)GetProcAddress(hDLL,ReadRFID); m_ReadRFIDBtn.EnableWindow(false); ret(ProcAdd3)(RFID); if (ret0) { m_txtRFID; for (i0;i4;i) { m_txtRFIDm_txtRFIDCString(c_hex[RFID[i]/16])CString(c_hex[RFID[i]%16]); LastRFID[i]RFID[i]; } m_txtStatusRead RFID OK; }else{ m_txtStatusRead RFID Err: 0xCString(c_hex[ret/16])CString(c_hex[ret%16]); } UpdateData(false); m_ReadRFIDBtn.EnableWindow(true); } void CTestDLL2Dlg::OnSetCardBtn() { // TODO: Add your control notification handler code here //unsigned char c_hex[]{0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F}; typedef DWORD (__stdcall *MYPROC4)(unsigned char* RFID); DWORD ret; unsigned char RFID[4]; int i; MYPROC4 ProcAdd4; ProcAdd4(MYPROC4)GetProcAddress(hDLL,SetCard); m_SetCardBtn.EnableWindow(false); //将最后读到的RFID码传输到发卡器,发卡指令需要验证RFID码 RFID[0]LastRFID[0]; RFID[1]LastRFID[1]; RFID[2]LastRFID[2]; RFID[3]LastRFID[3]; ret(ProcAdd4)(RFID); if (ret0) { m_txtRFID; for (i0;i4;i) { m_txtRFIDm_txtRFIDCString(c_hex[RFID[i]/16])CString(c_hex[RFID[i]%16]); } m_txtStatusSetCard OK; }else{ if (ret7) { m_txtStatus发卡异常发现读卡器内部时间有误请更新读卡器时间; }else m_txtStatusSetCard Err: 0xCString(c_hex[ret/16])CString(c_hex[ret%16]); } UpdateData(false); m_SetCardBtn.EnableWindow(true); } void CTestDLL2Dlg::OnClearCardBtn() { // TODO: Add your control notification handler code here //unsigned char c_hex[]{0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F}; typedef DWORD (__stdcall *MYPROC5)(unsigned char* RFID); DWORD ret; unsigned char RFID[4]; int i; MYPROC5 ProcAdd5; ProcAdd5(MYPROC5)GetProcAddress(hDLL,ClearCard); m_ClearCardBtn.EnableWindow(false); ret(ProcAdd5)(RFID); if (ret0) { m_txtRFID; for (i0;i4;i) { m_txtRFIDm_txtRFIDCString(c_hex[RFID[i]/16])CString(c_hex[RFID[i]%16]); } m_txtStatusClear OK; }else{ m_txtStatusClear Err: 0xCString(c_hex[ret/16])CString(c_hex[ret%16]); } UpdateData(false); m_ClearCardBtn.EnableWindow(true); } void CTestDLL2Dlg::OnOK() { // TODO: Add extra validation here CDialog::OnOK(); } void CTestDLL2Dlg::OnClose() { // TODO: Add your message handler code here and/or call default CDialog::OnClose(); FreeLibrary(hDLL); } void CTestDLL2Dlg::OnGetHandId() { // TODO: Add your control notification handler code here //unsigned char c_hex[]{0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F}; typedef DWORD (__stdcall *MYPROC6)(unsigned char* HandId); DWORD ret; unsigned char HandId[4]; MYPROC6 ProcAdd6; ProcAdd6(MYPROC6)GetProcAddress(hDLL,GetHandId); m_GetHandId.EnableWindow(false); ret(ProcAdd6)(HandId); if (ret0) { m_txtHandIdCString(c_hex[HandId[0]/16])CString(c_hex[HandId[0]%16])CString(c_hex[HandId[1]/16])CString(c_hex[HandId[1]%16]); LastHandID[0]HandId[0]; //保存最后读到的手牌码供发卡指令调用 LastHandID[1]HandId[1]; if (HandId[2]5) m_DoorID5; else m_DoorIDHandId[2]; m_txtStatusRead HandID OK; }else{ m_txtStatusRead HandID Err: 0xCString(c_hex[ret/16])CString(c_hex[ret%16]); } UpdateData(false); m_GetHandId.EnableWindow(true); } void CTestDLL2Dlg::OnSetHandId() { // TODO: Add your control notification handler code here CString HandIdtext; unsigned int HandIdVal; typedef DWORD (__stdcall *MYPROC7)(unsigned char* HandId); DWORD ret; CEdit* m_HandId (CEdit*) GetDlgItem(IDC_txtHandId); m_HandId-GetWindowText(HandIdtext); // Convert the hex string in the edit box to an integer. HandIdVal strtoul(0x HandIdtext, 0, 16); unsigned char HandId[4]; int i; MYPROC7 ProcAdd7; ProcAdd7(MYPROC7)GetProcAddress(hDLL,SetHandId); m_SetHandIdBtn.EnableWindow(false); //将最后读到的RFID码传输到发卡器,发卡指令需要验证RFID码 UpdateData(true); HandId[0]HandIdVal/256; HandId[1]HandIdVal%256; HandId[2]m_DoorID; HandId[3]HandId[0]^HandId[1]^HandId[2]; ret(ProcAdd7)(HandId); //m_txtHandIdCString(c_hex[HandId[1]/16])CString(c_hex[HandId[1]%16]); //UpdateData(false); //* if (ret0) { m_txtHandId; for (i0;i2;i) { m_txtHandIdm_txtHandIdCString(c_hex[HandId[i]/16])CString(c_hex[HandId[i]%16]); } m_txtStatusSet HandId OK; }else{ m_txtStatusSet HandId Err: 0xCString(c_hex[ret/16])CString(c_hex[ret%16]); } UpdateData(false); //*/ m_SetHandIdBtn.EnableWindow(true); } void CTestDLL2Dlg::OnEditchangeCombo1() { // TODO: Add your control notification handler code here UpdateData(true); } void CTestDLL2Dlg::OnGetRTCBtn() { // TODO: Add your control notification handler code here //unsigned char c_hex[]{0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F}; typedef DWORD (__stdcall *MYPROC8)(unsigned char* RTC); DWORD ret; unsigned char RTCBuf[8]; MYPROC8 ProcAdd8; ProcAdd8(MYPROC8)GetProcAddress(hDLL,GetRTC); m_GetRTCBtn.EnableWindow(false); ret(ProcAdd8)(RTCBuf); if (ret0) { m_txtRTCCString(c_hex[RTCBuf[0]/16])CString(c_hex[RTCBuf[0]%16])/CString(c_hex[RTCBuf[1]/16])CString(c_hex[RTCBuf[1]%16])/ CString(c_hex[RTCBuf[2]/16])CString(c_hex[RTCBuf[2]%16]) CString(c_hex[RTCBuf[3]/16])CString(c_hex[RTCBuf[3]%16]): CString(c_hex[RTCBuf[4]/16])CString(c_hex[RTCBuf[4]%16]):CString(c_hex[RTCBuf[5]/16])CString(c_hex[RTCBuf[5]%16]); m_txtStatusRead RTC OK; }else{ m_txtStatusRead RTC Err; } UpdateData(false); m_GetRTCBtn.EnableWindow(true); } //读卡器内部时间与电脑时间同步 void CTestDLL2Dlg::OnSetRTCBtn() { // TODO: Add your control notification handler code here CTime time CTime::GetCurrentTime(); int m_nYear time.GetYear(); ///年 int m_nMonth time.GetMonth(); ///月 int m_nDay time.GetDay(); ///日 int m_nHour time.GetHour(); ///小时 int m_nMinute time.GetMinute(); ///分钟 int m_nSecond time.GetSecond(); ///秒 //还可以用CTime::Format函数将CTime对象转换为字符串对象 //CString m_strTime time.Format(%Y-%m-%d %H:%M:%S); typedef DWORD (__stdcall *MYPROC9)(unsigned char* RTC); DWORD ret; unsigned char RTCBuf[6]; MYPROC9 ProcAdd9; ProcAdd9(MYPROC9)GetProcAddress(hDLL,SetRTC); m_SetRTCBtn.EnableWindow(false); m_nYearm_nYear-2000; RTCBuf[0](m_nYear/10)*16(m_nYear%10); RTCBuf[1](m_nMonth/10)*16(m_nMonth%10); RTCBuf[2](m_nDay/10)*16(m_nDay%10); RTCBuf[3](m_nHour/10)*16(m_nHour%10); RTCBuf[4](m_nMinute/10)*16(m_nMinute%10); RTCBuf[5](m_nSecond/10)*16(m_nSecond%10); ret(ProcAdd9)(RTCBuf); if (ret0) { m_txtStatusSet RTC DATE OK; }else{ m_txtStatusSetRTC DATE Err; } UpdateData(false); m_SetRTCBtn.EnableWindow(true); } void CTestDLL2Dlg::OnGetTypeBtn() { typedef DWORD (__stdcall *MYPROC)(unsigned char* CardType); DWORD ret; unsigned char CardType[4]; MYPROC ProcAdd; ProcAdd(MYPROC)GetProcAddress(hDLL,GetHandType); m_GetType.EnableWindow(false); ret(ProcAdd)(CardType); m_CardType0; if (ret0) { m_txtCustomerCString(c_hex[CardType[0]/16])CString(c_hex[CardType[0]%16])CString(c_hex[CardType[1]/16])CString(c_hex[CardType[1]%16]); if (CardType[2]0x45) m_CardType1; if (CardType[2]0x42) m_CardType2; if (CardType[2]0x52) m_CardType3; if (CardType[2]0x80) m_CardType4; if (CardType[2]0x90) m_CardType5; if (CardType[2]0xA0) m_CardType6; if (CardType[2]0xB0) m_CardType7; m_txtStatusRead Type OK; }else{ m_txtStatusRead Type Err: 0xCString(c_hex[ret/16])CString(c_hex[ret%16]); } UpdateData(false); m_GetType.EnableWindow(true); } //配对手牌码发卡模式 void CTestDLL2Dlg::OnSetOnCard2Btn() { typedef DWORD (__stdcall *MYPROC)(unsigned char* HandId); DWORD ret; unsigned char HandId[4]; MYPROC ProcAdd; ProcAdd(MYPROC)GetProcAddress(hDLL,SetCard2); m_SetOnCard2Btn.EnableWindow(false); //将最后读到的手牌码码传输到发卡器,发卡指令需要验证手牌码 HandId[0]LastHandID[0]; HandId[1]LastHandID[1]; HandId[2]0; HandId[3]0; ret(ProcAdd)(HandId); if (ret0) { m_txtHandId; m_txtHandIdCString(c_hex[HandId[0]/16])CString(c_hex[HandId[0]%16])CString(c_hex[HandId[1]/16])CString(c_hex[HandId[1]%16]); m_txtStatus配对手牌码发卡成功...; }else{ if (ret7) { m_txtStatus发卡异常发现读卡器内部时间有误请更新读卡器时间; }else m_txtStatusSetCard Err: 0xCString(c_hex[ret/16])CString(c_hex[ret%16]); } UpdateData(false); m_SetOnCard2Btn.EnableWindow(true); } void CTestDLL2Dlg::OnSetOffCard2Btn() { // TODO: Add your control notification handler code here typedef DWORD (__stdcall *MYPROC)(unsigned char* HandId); DWORD ret; unsigned char HandId[4]; int i; MYPROC ProcAdd; ProcAdd(MYPROC)GetProcAddress(hDLL,ClearCard2); m_SetOffCard2Btn.EnableWindow(false); ret(ProcAdd)(HandId); if (ret0) { m_txtHandIdCString(c_hex[HandId[0]/16])CString(c_hex[HandId[0]%16])CString(c_hex[HandId[1]/16])CString(c_hex[HandId[1]%16]); m_txtStatusClear Return HandId OK; }else{ m_txtStatusClear Err: 0xCString(c_hex[ret/16])CString(c_hex[ret%16]); } UpdateData(false); m_SetOffCard2Btn.EnableWindow(true); } void CTestDLL2Dlg::OnChangetxtCustomer() { // TODO: If this is a RICHEDIT control, the control will not // send this notification unless you override the CDialog::OnInitDialog() // function and call CRichEditCtrl().SetEventMask() // with the ENM_CHANGE flag ORed into the mask. // TODO: Add your control notification handler code here }人人皆为创造者共创方能共成长每个人都是使用者也是创造者是数字世界的消费者更是价值的生产者与分享者。在智能时代的浪潮里单打独斗的发展模式早已落幕唯有开放连接、创意共创、利益共享才能让个体价值汇聚成生态合力让技术与创意双向奔赴实现平台与伙伴的快速成长、共赢致远。原创永久分成共赴星辰大海原创创意共创、永久收益分成是东方仙盟始终坚守的核心理念。我们坚信每一份原创智慧都值得被尊重与回馈以永久分成锚定共创初心让创意者长期享有价值红利携手万千伙伴向着科技星辰大海笃定前行拥抱硅基 生命与数字智能交融的未来共筑跨越时代的数字文明共同体。东方仙盟拥抱知识开源共筑数字新生态在全球化与数字化浪潮中东方仙盟始终秉持开放协作、知识共享的理念积极拥抱开源技术与开放标准。我们相信唯有打破技术壁垒、汇聚全球智慧才能真正推动行业的可持续发展。开源赋能中小商户通过将前端异常检测、跨系统数据互联等核心能力开源化东方仙盟为全球中小商户提供了低成本、高可靠的技术解决方案让更多商家能够平等享受数字转型的红利。共建行业标准我们积极参与国际技术社区与全球开发者、合作伙伴共同制定开放协议 与技术规范推动跨境零售、文旅、餐饮等多业态的系统互联互通构建更加公平、高效的数字生态。知识普惠共促发展通过开源社区 、技术文档与培训体系东方仙盟致力于将前沿技术转化为可落地的行业实践赋能全球合作伙伴共同培育创新人才推动数字经济 的普惠式增长阿雪技术观在科技发展浪潮中我们不妨积极投身技术共享。不满足于做受益者更要主动担当贡献者 。无论是分享代码、撰写技术博客还是参与开源项目 维护改进每一个微小举动都可能蕴含推动技术进步的巨大能量。东方仙盟是汇聚力量的天地我们携手在此探索硅基 生命为科技进步添砖加瓦。Hey folks, in this wild tech - driven world, why not dive headfirst into the whole tech - sharing scene? Dont just be the one reaping all the benefits; step up and be a contributor too. Whether youre tossing out your code snippets , hammering out some tech blogs, or getting your hands dirty with maintaining and sprucing up open - source projects, every little thing you do might just end up being a massive force that pushes tech forward. And guess what? The Eastern FairyAlliance is this awesome place where we all come together. Were gonna team up and explore the whole silicon - based life thing, and in the process, well be fueling the growth of technology