From 19b17df578142b02b2a0b9428444f4ae8f472969 Mon Sep 17 00:00:00 2001 From: strawmanbobi Date: Sun, 1 Feb 2026 11:59:18 +0800 Subject: [PATCH] updated win32 example readme --- README.md | 63 ++++++++++++++++++++++++++++---- win32-example/DecodeTestWin.cpp | 2 +- win32-example/README.md | Bin 0 -> 4348 bytes win32-example/ReadMe.txt | 39 -------------------- 4 files changed, 57 insertions(+), 47 deletions(-) create mode 100644 win32-example/README.md delete mode 100644 win32-example/ReadMe.txt diff --git a/README.md b/README.md index 4ca62aa..efbd1f4 100644 --- a/README.md +++ b/README.md @@ -1,10 +1,59 @@ -# IRext decode algorithm porting examples +# IRext Win32 Example -This repository contails various of example which show you how to port IRext decode algorithm to different OS and platforms +A Windows desktop example demonstrating the IRext infrared decoder library. -Version 1.5.0 +## Overview -- Android example -- Java web example with JNI -- Windows example -- Arduino example (TBD) +IRext is an open-source infrared remote control library. This example provides a command-line application to test IR decoding functionality on Windows. + +## Features + +- Decode IR binary files for air conditioners (AC) +- Decode IR binary files for TV devices +- Query supported AC modes, wind speeds, swing options, and temperature ranges +- Generate IR timing data for remote control signals + +## Requirements + +- Operating System: Windows 10 or later +- IDE: Visual Studio 2019 or later +- Build Tools: MSVC v142 (VS2019) or v143 (VS2022) + +## Building + +1. Open win32-example/IRextWin32Example.sln in Visual Studio. + +2. If you encounter build error MSB8020 (Platform Toolset not found), retarget the solution: + - Right-click the solution in Solution Explorer + - Select Retarget solution + - Choose an installed Windows SDK and Platform Toolset + +3. Select the desired configuration (Debug or Release) and platform (x86 or x64). + +4. Build the solution (Ctrl+Shift+B or Build > Build Solution). + +## Usage + +1. Run the compiled executable from the command line. +2. The program will prompt you to input key codes to simulate remote control actions. +3. Key code reference: https://site.irext.net/doc#keymap +4. Enter 99 to exit the program. + +### Example Key Codes + +| Key Code | Function | +|----------|----------| +| 14 | Query supported modes | +| 15 | Query supported wind speeds | +| 16 | Query temperature range | +| 99 | Exit program | + +## Related Links + +- IRext Official Site: https://irext.net +- IRext Documentation: https://site.irext.net/doc +- IRext GitHub: https://github.com/irext + +## License + +Please refer to the IRext repository for license information. diff --git a/win32-example/DecodeTestWin.cpp b/win32-example/DecodeTestWin.cpp index 06d26b8..605539d 100644 --- a/win32-example/DecodeTestWin.cpp +++ b/win32-example/DecodeTestWin.cpp @@ -261,7 +261,7 @@ static INT8 decode_as_tv(char *file_name, UINT8 ir_hex_encode) if (1 == first_time) { printf("Please input valid key code " - "(Key code could be referenced from https://irext.net/doc#keymap) : \n"); + "(Key code could be referenced from https://site.irext.net/doc#keymap) : \n"); first_time = 0; } else diff --git a/win32-example/README.md b/win32-example/README.md new file mode 100644 index 0000000000000000000000000000000000000000..982eb249848dddd47d9c56ca4c17218fed001172 GIT binary patch literal 4348 zcmbuDT~Av_5Qg_UQvbtB+(1%H_-NGRqEbUhh0>@gcIib`)einB#n_I0LO|lTw|$=( zkIy*IJ-MLGyBdvGkf^&-;I>haXLx8be#&l|DMj%DD9^`y&q|=lP=RF4YmG6 z&yNdkYqNBr-D62+(^T&A^-HadBvquTG!|xKAlV}QE%~|!*zcR%RBPS2 zg)?cu(p2N2_J5p9+@ywiwvjl=FX_r;t|ZZufB0NI-MM+(k%esD_Vl)`xpDd|eP`N} z&9}OJ{NMzIt>ekaPBNA!cfHA}rBk^jP_1Gyk(IH0JfEYMwVGvjEd7^yA8CHu&Nnh! z9U%((=aO;Uunlfw`wj9$jWasZjuRMyZ(rvcX)lPgvtzo7bfY!b#MA^(y27T z6EG&8_>I@U>Ks_&~z*UlG#SYr}XY8y%TYli;O_SximyHyA}@^6R1AS%$ar$=27?fd6t~W(kEd+ zMDP&Xh0YWaewv;tlS;qCepBedH})X&N}kmDlhbZ`ZkTwU!XHlMF<{TJ_;a+_eJUS_ z2E5FvDe2F`7_Mejpy$%|@}P2m3mXw(t0Ir$j70i+mc69mQSm2@QmCu zE60j^Rt%_C)LAl{ccKT%Syhp!Iv&hWZJ2K-uy~!m7pCBf<<0a#l0?Yabg8)#!=C1| zG*k7QZ`kPy5BLvn3hkX5i;;**PAwhEi^zyq!YJEA7M{qvfvRJnoIH~pIePKH?!c$H zq}6*9m67u~!%8bn%}{@+d)e3kSnN z{cgU4^>rA-p?!;P-Rr>9tC43a`n-NpVFyAvx~bRlO~sY!3=0Mp!XZ zna~J|brzuKT3mTi({Ziwfo8Vm9rwVzE^}fv2jE&;c}Vvkre|Uz{jsm{GjS3wx}U_L zs_zG_RL9FKKt8li1?+&mE)L@y8pL8`L%C=j4a!xmWE5qcm6=gA(jqP{cw zw0C~0HaY4U+S19`>wSJ;@j(Nf1kS_?_TgsaviEcNH8C%;vZ80b3U8eQ_(5Hys$WXV zqlPsyVDMR(T*PMQ*RpjizN5PhUCex z9r-%e&W*YMU^Njs&XprcMWt%1vcI(0`>D`_-V*IPhULvm*5Lvz;(sg2 z<&|u+Z;cb>y~u0F`ro&vbz9YI`MJF_vn;WC>{{ua2lBZ3aDsI=7a|`Fsqb|JcGGt? zosPgdtuXfP-G{xQ^~D;kMEc>|Pw8!Fg%jm0Zy-Rlof~yd)FtnZ&>Fq_gSa|Q|Hvor z3fwiOVgVz+mmy1!dTa-0&+7h7zScV;mBnk%W9(hY(`)6DpQ0_B>+FVXoOszPog%7B zOYd|x?`93nb3YC%@0G=VPoXY=8@Fig&&(DJ+^7eC85cwE)anIaRyzxA%ik(~a{(pd z;NM{3E8hiio2IgMOgrBTWn{g#`Aw5*{?F_!_QKPq=J?rMFDz?tOY-su(XPxYzC zRJ-_Asq25Elh8}zUX5p7eIKhos_Ff9$~z~0vBa*<^!se`#X=;jnBP~;t9M^eB{uBx z{{?Wfi5o?=cSN6xu31NijsbJLi_rIP(%1P|ehvA3GJK3Ld2G;!A_{bpZ}js&@kP%e literal 0 HcmV?d00001 diff --git a/win32-example/ReadMe.txt b/win32-example/ReadMe.txt deleted file mode 100644 index ea4d203..0000000 --- a/win32-example/ReadMe.txt +++ /dev/null @@ -1,39 +0,0 @@ -======================================================================== - 控制台应用程序:DecodeTestWin 项目概述 -======================================================================== - -应用程序向导已为您创建了此 DecodeTestWin 应用程序。 - -本文件概要介绍组成 DecodeTestWin 应用程序的每个文件的内容。 - - -DecodeTestWin.vcxproj - 这是使用应用程序向导生成的 VC++ 项目的主项目文件,其中包含生成该文件的 Visual C++ 的版本信息,以及有关使用应用程序向导选择的平台、配置和项目功能的信息。 - -DecodeTestWin.vcxproj.filters - 这是使用“应用程序向导”生成的 VC++ 项目筛选器文件。它包含有关项目文件与筛选器之间的关联信息。在 IDE 中,通过这种关联,在特定节点下以分组形式显示具有相似扩展名的文件。例如,“.cpp”文件与“源文件”筛选器关联。 - -DecodeTestWin.cpp - 这是主应用程序源文件。 - -///////////////////////////////////////////////////////////////////////////// -应用程序向导创建了下列资源: - -DecodeTestWin.rc - 这是程序使用的所有 Microsoft Windows 资源的列表。它包括 RES 子目录中存储的图标、位图和光标。此文件可以直接在 Microsoft Visual C++ 中进行编辑。 - -Resource.h - 这是标准头文件,可用于定义新的资源 ID。Microsoft Visual C++ 将读取并更新此文件。 - -///////////////////////////////////////////////////////////////////////////// -其他标准文件: - -StdAfx.h, StdAfx.cpp - 这些文件用于生成名为 DecodeTestWin.pch 的预编译头 (PCH) 文件和名为 StdAfx.obj 的预编译类型文件。 - -///////////////////////////////////////////////////////////////////////////// -其他注释: - -应用程序向导使用“TODO:”注释来指示应添加或自定义的源代码部分。 - -/////////////////////////////////////////////////////////////////////////////