update 2016-11-03 b1

1. resolved key words issues
This commit is contained in:
strawmanbobi
2016-11-03 22:53:45 +08:00
parent 2d43854e21
commit 8a4294381e
25 changed files with 365 additions and 870 deletions

View File

@@ -2,7 +2,7 @@
<module type="CPP_MODULE" version="4">
<component name="NewModuleRootManager">
<content url="file://$MODULE_DIR$">
<sourceFolder url="file://$MODULE_DIR$/ucon_decode.h" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/irda_parse_forbidden_info.h" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/irda_parse_forbidden_info.c" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/irda_irframe.h" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/CMakeLists.txt" isTestSource="false" />
@@ -12,16 +12,14 @@
<sourceFolder url="file://$MODULE_DIR$/irda_parse_frame_parameter.h" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/irda_defs.h" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/irda_parse_ac_parameter.h" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/ucon_decode.c" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/irda_parse_frame_parameter.c" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/irda_lib.h" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/bc_parse_parameter.h" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/irda_parse_ac_parameter.c" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/irda_apply.h" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/bc_parse_parameter.c" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/irda_parse_forbidden_info.h" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/irda_lib.h" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/irda_decode.h" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/irda_apply.c" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/irda_lib.c" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/irda_decode.c" isTestSource="false" />
</content>
<orderEntry type="sourceFolder" forTests="false" />
<orderEntry type="module-library">

View File

@@ -32,48 +32,149 @@
</component>
<component name="FileEditorManager">
<leaf SIDE_TABS_SIZE_LIMIT_KEY="300">
<file leaf-file-name="ucon_decode.c" pinned="false" current-in-tab="true">
<entry file="file://$PROJECT_DIR$/ucon_decode.c">
<file leaf-file-name="irda_decode.c" pinned="false" current-in-tab="true">
<entry file="file://$PROJECT_DIR$/irda_decode.c">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="288">
<caret line="457" column="21" selection-start-line="457" selection-start-column="21" selection-end-line="457" selection-end-column="21" />
<state relative-caret-position="5184">
<caret line="1550" column="0" selection-start-line="1550" selection-start-column="0" selection-end-line="1550" selection-end-column="0" />
<folding>
<element signature="e#423#441#0" expanded="true" />
<element signature="e#512#534#0" expanded="true" />
<element signature="e#582#601#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
</file>
<file leaf-file-name="irda_decode.h" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/irda_decode.h">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="129">
<caret line="17" column="0" selection-start-line="17" selection-start-column="0" selection-end-line="17" selection-end-column="0" />
<folding />
</state>
</provider>
</entry>
</file>
<file leaf-file-name="irda_lib.c" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/irda_lib.c">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="-2015">
<caret line="22" column="0" selection-start-line="22" selection-start-column="0" selection-end-line="22" selection-end-column="0" />
<folding>
<element signature="e#726#744#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
</file>
<file leaf-file-name="irda_lib.h" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/irda_lib.h">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="368">
<caret line="249" column="0" selection-start-line="249" selection-start-column="0" selection-end-line="249" selection-end-column="0" />
<folding />
</state>
</provider>
</entry>
</file>
<file leaf-file-name="irda_parse_forbidden_info.c" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/irda_parse_forbidden_info.c">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="80">
<caret line="5" column="49" selection-start-line="5" selection-start-column="49" selection-end-line="5" selection-end-column="49" />
<folding />
</state>
</provider>
</entry>
</file>
<file leaf-file-name="irda_parse_forbidden_info.h" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/irda_parse_forbidden_info.h">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="80">
<caret line="5" column="49" selection-start-line="5" selection-start-column="49" selection-end-line="5" selection-end-column="49" />
<folding />
</state>
</provider>
</entry>
</file>
<file leaf-file-name="irda_parse_frame_parameter.c" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/irda_parse_frame_parameter.c">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="80">
<caret line="5" column="49" selection-start-line="5" selection-start-column="49" selection-end-line="5" selection-end-column="49" />
<folding />
</state>
</provider>
</entry>
</file>
<file leaf-file-name="irda_parse_frame_parameter.h" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/irda_parse_frame_parameter.h">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="80">
<caret line="5" column="49" selection-start-line="5" selection-start-column="49" selection-end-line="5" selection-end-column="49" />
<folding />
</state>
</provider>
</entry>
</file>
<file leaf-file-name="irda_utils.c" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/irda_utils.c">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="80">
<caret line="5" column="52" selection-start-line="5" selection-start-column="52" selection-end-line="5" selection-end-column="52" />
<folding />
</state>
</provider>
</entry>
</file>
<file leaf-file-name="irda_utils.h" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/irda_utils.h">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="80">
<caret line="5" column="68" selection-start-line="5" selection-start-column="68" selection-end-line="5" selection-end-column="68" />
<folding>
<element signature="e#417#439#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
</file>
</leaf>
</component>
<component name="IdeDocumentHistory">
<option name="CHANGED_PATHS">
<list>
<option value="$PROJECT_DIR$/irda_parse_forbidden_info.h" />
<option value="$PROJECT_DIR$/irda_parse_frame_parameter.h" />
<option value="$PROJECT_DIR$/irda_parse_ac_parameter.h" />
<option value="$PROJECT_DIR$/irda_apply.h" />
<option value="$PROJECT_DIR$/irda_parse_forbidden_info.c" />
<option value="$PROJECT_DIR$/test.c" />
<option value="$PROJECT_DIR$/irda_decode.h" />
<option value="$PROJECT_DIR$/irda_decode.c" />
<option value="$PROJECT_DIR$/yk_decode.h" />
<option value="$PROJECT_DIR$/yk_decode.c" />
<option value="$PROJECT_DIR$/irda_apply.c" />
<option value="$PROJECT_DIR$/irda_ac_decode.h" />
<option value="$PROJECT_DIR$/irda_utils.c" />
<option value="$PROJECT_DIR$/irda_utils.h" />
<option value="$PROJECT_DIR$/bc_parse_parameter.h" />
<option value="$PROJECT_DIR$/bc_parse_parameter.c" />
<option value="$PROJECT_DIR$/CMakeLists.txt" />
<option value="$PROJECT_DIR$/include/ucon_decode_jni.h" />
<option value="$PROJECT_DIR$/ucon_decode.h" />
<option value="$PROJECT_DIR$/irda_defs.h" />
<option value="$PROJECT_DIR$/ucon_decode_jni.c" />
<option value="$PROJECT_DIR$/irda_parse_ac_parameter.c" />
<option value="$PROJECT_DIR$/irda_irframe.c" />
<option value="$PROJECT_DIR$/irda_parse_frame_parameter.c" />
<option value="$PROJECT_DIR$/ucon_decode.c" />
<option value="$PROJECT_DIR$/Android.mk" />
<option value="$PROJECT_DIR$/irda_apply.c" />
<option value="$PROJECT_DIR$/irda_apply.h" />
<option value="$PROJECT_DIR$/irda_decode_jni.c" />
<option value="$PROJECT_DIR$/irda_defs.h" />
<option value="$PROJECT_DIR$/irda_irframe.c" />
<option value="$PROJECT_DIR$/irda_irframe.h" />
<option value="$PROJECT_DIR$/irda_parse_ac_parameter.c" />
<option value="$PROJECT_DIR$/irda_parse_ac_parameter.h" />
<option value="$PROJECT_DIR$/irda_parse_forbidden_info.c" />
<option value="$PROJECT_DIR$/irda_parse_forbidden_info.h" />
<option value="$PROJECT_DIR$/irda_parse_frame_parameter.c" />
<option value="$PROJECT_DIR$/irda_parse_frame_parameter.h" />
<option value="$PROJECT_DIR$/irda_utils.c" />
<option value="$PROJECT_DIR$/irda_utils.h" />
<option value="$PROJECT_DIR$/irda_decode.h" />
<option value="$PROJECT_DIR$/irda_lib.c" />
<option value="$PROJECT_DIR$/irda_lib.h" />
<option value="$PROJECT_DIR$/irda_decode.c" />
</list>
</option>
</component>
@@ -149,6 +250,20 @@
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
</PATH>
<PATH>
<PATH_ELEMENT>
<option name="myItemId" value="irda_decoder" />
<option name="myItemType" value="com.jetbrains.cidr.projectView.CidrFilesViewHelper$MyProjectTreeStructure$1" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="ir_decoder" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
<PATH_ELEMENT>
<option name="myItemId" value="include" />
<option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
</PATH_ELEMENT>
</PATH>
</subPane>
</pane>
</panes>
@@ -358,21 +473,23 @@
<workItem from="1470732659162" duration="1236000" />
<workItem from="1470792404312" duration="7000" />
<workItem from="1478095215915" duration="826000" />
<workItem from="1478182519665" duration="2121000" />
</task>
<servers />
</component>
<component name="TimeTrackingManager">
<option name="totallyTimeSpent" value="18044000" />
<option name="totallyTimeSpent" value="20165000" />
</component>
<component name="ToolWindowManager">
<frame x="-8" y="-8" width="1936" height="1065" extended-state="6" />
<editor active="false" />
<editor active="true" />
<layout>
<window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.11801897" sideWeight="0.5" order="0" side_tool="false" content_ui="combo" />
<window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.12697576" sideWeight="0.5" order="0" side_tool="false" content_ui="combo" />
<window_info id="TODO" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="6" side_tool="false" content_ui="tabs" />
<window_info id="Messages" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.26077348" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
<window_info id="CMake" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.27403316" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
<window_info id="Event Log" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="7" side_tool="true" content_ui="tabs" />
<window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.37900552" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
<window_info id="Version Control" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
<window_info id="Structure" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
<window_info id="Terminal" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.32928178" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
@@ -383,7 +500,6 @@
<window_info id="Inspection" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="5" side_tool="false" content_ui="tabs" />
<window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.24198896" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
<window_info id="Hierarchy" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="2" side_tool="false" content_ui="combo" />
<window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.20883977" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
<window_info id="Ant Build" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
<window_info id="Debug" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.28176796" sideWeight="0.5" order="3" side_tool="false" content_ui="tabs" />
</layout>
@@ -431,13 +547,6 @@
<watches-manager />
</component>
<component name="editorHistoryManager">
<entry file="file://$PROJECT_DIR$/ucon_decode.c">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="146" column="37" selection-start-line="146" selection-start-column="37" selection-end-line="146" selection-end-column="37" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_parse_ac_parameter.c">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
@@ -452,7 +561,7 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/ucon_decode.c">
<entry file="file://$PROJECT_DIR$/irda_decode.c">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="0" column="0" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
@@ -487,14 +596,14 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/ucon_decode.h">
<entry file="file://$PROJECT_DIR$/irda_decode.h">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="28" column="14" selection-start-line="28" selection-start-column="13" selection-end-line="28" selection-end-column="14" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/ucon_decode.c">
<entry file="file://$PROJECT_DIR$/irda_decode.c">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="605" column="21" selection-start-line="605" selection-start-column="21" selection-end-line="605" selection-end-column="21" />
@@ -557,14 +666,14 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/ucon_decode.h">
<entry file="file://$PROJECT_DIR$/irda_decode.h">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="70" column="21" selection-start-line="70" selection-start-column="21" selection-end-line="70" selection-end-column="21" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/ucon_decode.c">
<entry file="file://$PROJECT_DIR$/irda_decode.c">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="537" column="48" selection-start-line="537" selection-start-column="48" selection-end-line="537" selection-end-column="48" />
@@ -606,43 +715,8 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_parse_ac_parameter.h">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="79" column="0" selection-start-line="79" selection-start-column="0" selection-end-line="79" selection-end-column="0" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_parse_forbidden_info.h">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="37" column="11" selection-start-line="37" selection-start-column="11" selection-end-line="37" selection-end-column="11" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_parse_frame_parameter.h">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="53" column="18" selection-start-line="53" selection-start-column="18" selection-end-line="53" selection-end-column="18" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_irframe.h">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="10" column="37" selection-start-line="10" selection-start-column="37" selection-end-line="10" selection-end-column="37" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_ac_decode.c" />
<entry file="file://$PROJECT_DIR$/irda_ac_decode.h" />
<entry file="file://$PROJECT_DIR$/irda_utils.c">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="311">
<caret line="89" column="24" selection-start-line="89" selection-start-column="24" selection-end-line="89" selection-end-column="24" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/bc_parse_parameter.h">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="509">
@@ -650,13 +724,6 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/CMakeLists.txt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="384">
<caret line="24" column="20" selection-start-line="24" selection-start-column="20" selection-end-line="24" selection-end-column="20" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/bc_parse_parameter.c">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="560">
@@ -671,13 +738,6 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_utils.h">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="137">
<caret line="13" column="0" selection-start-line="13" selection-start-column="0" selection-end-line="13" selection-end-column="0" />
</state>
</provider>
</entry>
<entry file="file://D:/cygwin64/usr/src/debug/cygwin-2.2.1-1/winsup/cygwin/fhandler_console.cc">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="207">
@@ -685,95 +745,182 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_parse_forbidden_info.c">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="-1026">
<caret line="41" column="23" selection-start-line="41" selection-start-column="23" selection-end-line="41" selection-end-column="23" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_apply.c">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="157">
<caret line="622" column="49" selection-start-line="622" selection-start-column="49" selection-end-line="622" selection-end-column="49" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_apply.h">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="416">
<caret line="27" column="12" selection-start-line="27" selection-start-column="10" selection-end-line="27" selection-end-column="12" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_defs.h">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="845">
<caret line="72" column="26" selection-start-line="72" selection-start-column="26" selection-end-line="72" selection-end-column="26" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_parse_frame_parameter.c">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="205">
<caret line="254" column="48" selection-start-line="254" selection-start-column="48" selection-end-line="254" selection-end-column="48" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_parse_ac_parameter.c">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="93">
<caret line="1360" column="33" selection-start-line="1360" selection-start-column="33" selection-end-line="1360" selection-end-column="33" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/ucon_decode.h">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="408">
<caret line="614" column="52" selection-start-line="614" selection-start-column="52" selection-end-line="614" selection-end-column="52" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_irframe.c">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="572">
<caret line="177" column="0" selection-start-line="177" selection-start-column="0" selection-end-line="177" selection-end-column="0" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/ucon_decode_jni.c">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="224">
<caret line="14" column="36" selection-start-line="14" selection-start-column="36" selection-end-line="14" selection-end-column="36" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/include/ucon_decode_jni.h">
<entry file="file://$PROJECT_DIR$/include/irda_decode_jni.h">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="421">
<caret line="130" column="54" selection-start-line="130" selection-start-column="54" selection-end-line="130" selection-end-column="54" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/CMakeLists.txt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="256">
<caret line="16" column="33" selection-start-line="16" selection-start-column="33" selection-end-line="16" selection-end-column="33" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/Android.mk">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="64">
<caret line="4" column="33" selection-start-line="4" selection-start-column="33" selection-end-line="4" selection-end-column="33" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_apply.c">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="64">
<caret line="4" column="0" selection-start-line="4" selection-start-column="0" selection-end-line="4" selection-end-column="0" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_apply.h">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="64">
<caret line="4" column="0" selection-start-line="4" selection-start-column="0" selection-end-line="4" selection-end-column="0" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_decode_jni.c">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="16">
<caret line="1" column="20" selection-start-line="1" selection-start-column="20" selection-end-line="1" selection-end-column="20" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_defs.h">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="80">
<caret line="5" column="49" selection-start-line="5" selection-start-column="49" selection-end-line="5" selection-end-column="49" />
<folding>
<element signature="e#555#613#0" expanded="true" />
<element signature="e#915#1230#0" expanded="true" />
<element signature="e#1258#1566#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_irframe.c">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="80">
<caret line="5" column="64" selection-start-line="5" selection-start-column="64" selection-end-line="5" selection-end-column="64" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_irframe.h">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="80">
<caret line="5" column="67" selection-start-line="5" selection-start-column="67" selection-end-line="5" selection-end-column="67" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_parse_ac_parameter.c">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="80">
<caret line="5" column="49" selection-start-line="5" selection-start-column="49" selection-end-line="5" selection-end-column="49" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_parse_ac_parameter.h">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="80">
<caret line="5" column="49" selection-start-line="5" selection-start-column="49" selection-end-line="5" selection-end-column="49" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_parse_forbidden_info.c">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="80">
<caret line="5" column="49" selection-start-line="5" selection-start-column="49" selection-end-line="5" selection-end-column="49" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_parse_forbidden_info.h">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="80">
<caret line="5" column="49" selection-start-line="5" selection-start-column="49" selection-end-line="5" selection-end-column="49" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_parse_frame_parameter.c">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="80">
<caret line="5" column="49" selection-start-line="5" selection-start-column="49" selection-end-line="5" selection-end-column="49" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_parse_frame_parameter.h">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="80">
<caret line="5" column="49" selection-start-line="5" selection-start-column="49" selection-end-line="5" selection-end-column="49" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_utils.c">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="80">
<caret line="5" column="52" selection-start-line="5" selection-start-column="52" selection-end-line="5" selection-end-column="52" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_utils.h">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="80">
<caret line="5" column="68" selection-start-line="5" selection-start-column="68" selection-end-line="5" selection-end-column="68" />
<folding>
<element signature="e#417#439#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_decode.h">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="129">
<caret line="17" column="0" selection-start-line="17" selection-start-column="0" selection-end-line="17" selection-end-column="0" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_lib.c">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="22">
<caret line="298" column="9" selection-start-line="298" selection-start-column="9" selection-end-line="298" selection-end-column="9" />
<state relative-caret-position="-2015">
<caret line="22" column="0" selection-start-line="22" selection-start-column="0" selection-end-line="22" selection-end-column="0" />
<folding>
<element signature="e#726#744#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/irda_lib.h">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="688">
<caret line="93" column="0" selection-start-line="93" selection-start-column="0" selection-end-line="93" selection-end-column="0" />
<state relative-caret-position="368">
<caret line="249" column="0" selection-start-line="249" selection-start-column="0" selection-end-line="249" selection-end-column="0" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/ucon_decode.c">
<entry file="file://$PROJECT_DIR$/irda_decode.c">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="288">
<caret line="457" column="21" selection-start-line="457" selection-start-column="21" selection-end-line="457" selection-end-column="21" />
<folding />
<state relative-caret-position="5184">
<caret line="1550" column="0" selection-start-line="1550" selection-start-column="0" selection-end-line="1550" selection-end-column="0" />
<folding>
<element signature="e#423#441#0" expanded="true" />
<element signature="e#512#534#0" expanded="true" />
<element signature="e#582#601#0" expanded="true" />
</folding>
</state>
</provider>
</entry>

View File

@@ -4,8 +4,8 @@ include $(CLEAR_VARS)
LOCAL_CFLAGS := -DBOARD_MT6580
LOCAL_MODULE := libirdecode
LOCAL_SRC_FILES := ucon_decode_jni.c \
ucon_decode.c \
LOCAL_SRC_FILES := irda_decode_jni.c \
irda_decode.c \
bc_parse_parameter.c \
irda_lib.c \
irda_apply.c \

View File

@@ -4,10 +4,8 @@ project(irda_decoder)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
add_definitions(-DBOARD_PC)
set(SOURCE_FILES
ucon_decode.c
ucon_decode.h
bc_parse_parameter.c
bc_parse_parameter.h
irda_decode.c
irda_decode.h
irda_lib.c
irda_lib.h
irda_apply.c

View File

@@ -1,192 +0,0 @@
/**************************************************************************************************
Filename: bc_parse_parameter.c
Revised: Date: 2016-02-25
Revision: Revision: 1.0
Description: This file provides algorithms for UCON BLE Central decode
Copyright 2014-2016 UCON Tech all rights reserved
Revision log:
* 2016-02-25: created by strawmanbobi
**************************************************************************************************/
/*
*inclusion
*/
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include "irda_defs.h"
#include "irda_utils.h"
#include "bc_parse_parameter.h"
/*
* global vars
*/
/*
* external vars
*/
/*
* function declaration
*/
INT8 parse_ble_command(UINT8 *data, UINT16 *trav_offset, t_bc_command *bc_command);
/*
* function definition
*/
INT8 parse_ble_name(UINT8 *data, UINT8 length, char *name)
{
if (NULL == data || NULL == name || 0 == length)
{
return IR_DECODE_FAILED;
}
irda_memcpy(name, data, length);
return IR_DECODE_SUCCEEDED;
}
INT8 parse_ble_need_conn_ack(UINT8 *data, UINT8 *nca)
{
if (NULL == data || NULL == nca)
{
return IR_DECODE_FAILED;
}
if (*data == '0')
{
*nca = 0;
}
else if (*data == '1')
{
*nca = 1;
}
else
{
*nca = 0;
}
return IR_DECODE_SUCCEEDED;
}
INT8 parse_ble_name_essential_length(UINT8 *data, UINT8 *nel)
{
if (NULL == data || NULL == nel)
{
return IR_DECODE_FAILED;
}
// must be 2 bytes
*nel = ((data[0] - '0') * 10) + (data[1] - '0');
return IR_DECODE_SUCCEEDED;
}
INT8 parse_ble_name_length(UINT8 *data, UINT8 *nl)
{
if (NULL == data || NULL == nl)
{
return IR_DECODE_FAILED;
}
// must be 2 bytes
*nl = ((data[0] - '0') * 10) + (data[1] - '0');
return IR_DECODE_SUCCEEDED;
}
INT8 parse_ble_command(UINT8 *data, UINT16 *trav_offset, t_bc_command *bc_command)
{
UINT8 command_len = 0;
if (NULL == data || NULL == bc_command || NULL == trav_offset)
{
return IR_DECODE_FAILED;
}
command_len = data[*trav_offset];
if (0 == command_len || command_len > BLE_GAP_MTU)
{
// reset data structure of bc_command in case of invalid command_len is found
bc_command->length = 0;
bc_command->handle = 0x0000;
irda_memset(bc_command->command, 0x00, BLE_GAP_MTU);
return IR_DECODE_SUCCEEDED;
}
bc_command->length = command_len;
(*trav_offset)++;
bc_command->handle = data[*trav_offset] * 0x0100;
(*trav_offset)++;
bc_command->handle += data[*trav_offset];
(*trav_offset)++;
// prepare commands
irda_memset(bc_command->command, 0x00, BLE_GAP_MTU);
irda_memcpy(bc_command->command, &data[*trav_offset], bc_command->length);
(*trav_offset) += bc_command->length;
return IR_DECODE_SUCCEEDED;
}
INT8 parse_ble_commands(t_tag_head *tag, t_bc_commands *bc_commands)
{
UINT16 hex_len = 0;
#if (defined BOARD_PC) || (defined BOARD_MT6580)
UINT16 i = 0;
#endif
UINT16 trav_offset = 0;
UINT8 seg_index = 0;
UINT8 *hex_data = NULL;
if (NULL == tag || NULL == bc_commands)
{
return IR_DECODE_FAILED;
}
hex_len = tag->len >> 1;
hex_data = (UINT8 *) irda_malloc(hex_len);
if (NULL == hex_data)
{
return IR_DECODE_FAILED;
}
string_to_hex_common(tag->pdata, hex_data, hex_len);
bc_commands->seg_count = hex_data[0];
bc_commands->commands = (t_bc_command*)irda_malloc(bc_commands->seg_count * sizeof(t_bc_command));
for (seg_index = 0; seg_index < bc_commands->seg_count; seg_index++)
{
// trav_offset + 1 indicates the cursor pointing to internal data slice marked by trav_offset, considering
// the total length of a single byte
if (IR_DECODE_FAILED == parse_ble_command(&hex_data[trav_offset + 1],
&trav_offset,
&bc_commands->commands[seg_index]))
{
irda_free(hex_data);
hex_data = NULL;
return IR_DECODE_FAILED;
}
#if (defined BOARD_PC) || (defined BOARD_MT6580)
IR_PRINTF("command length = %d\n", bc_commands->commands[seg_index].length);
IR_PRINTF("command handle = 0x%02x\n", bc_commands->commands[seg_index].handle);
for(i = 0; i < bc_commands->commands[seg_index].length; i++)
{
IR_PRINTF("[%02X] ", bc_commands->commands[seg_index].command[i]);
}
IR_PRINTF("\n");
#endif
if (trav_offset >= hex_len)
{
break;
}
}
irda_free(hex_data);
hex_data = NULL;
return IR_DECODE_SUCCEEDED;
}

View File

@@ -1,53 +0,0 @@
/**************************************************************************************************
Filename: bc_parse_parameter.h
Revised: Date: 2016-02-25
Revision: Revision: 1.0
Description: This file provides algorithms for UCON BLE Central decode
Copyright 2014-2016 UCON Tech all rights reserved
Revision log:
* 2016-02-25: created by strawmanbobi
**************************************************************************************************/
/*
*inclusion
*/
#include "ucon_decode.h"
#ifndef _BC_PARSE_PARAMETER_H_
#define _BC_PARSE_PARAMETER_H_
#ifdef __cplusplus
extern "C"
{
#endif
/*
* public macros
*/
/*
* public type definition
*/
/*
* public function declaration
*/
extern INT8 parse_ble_name(UINT8 *data, UINT8 length, char *name);
extern INT8 parse_ble_need_conn_ack(UINT8 *data, UINT8 *nca);
extern INT8 parse_ble_name_essential_length(UINT8 *data, UINT8 *nel);
extern INT8 parse_ble_name_length(UINT8 *data, UINT8 *nl);
extern INT8 parse_ble_commands(t_tag_head *tag, t_bc_commands *bc_commands);
#ifdef __cplusplus
}
#endif
#endif // _IRDA_PARSE_AC_PARAMETER_H_

View File

@@ -3,9 +3,9 @@ Filename: irda_apply.c
Revised: Date: 2015-08-12
Revision: Revision: 1.0
Description: This file provides methods for UCON applying functionalities
Description: This file provides methods for AC IR applying functionalities
Copyright 2014-2016 UCON Tech all rights reserved
Revision log:
* 2015-08-12: created by strawmanbobi
@@ -15,7 +15,7 @@ Revision log:
*/
#include "irda_utils.h"
#include "ucon_decode.h"
#include "irda_decode.h"
#include "irda_apply.h"
#if defined BOARD_CC254X
#include "npi.h"

View File

@@ -3,9 +3,9 @@ Filename: irda_apply.h
Revised: Date: 2015-08-12
Revision: Revision: 1.0
Description: This file provides methods for UCON applying functionalities
Description: This file provides methods for AC IR applying functionalities
Copyright 2014-2016 UCON Tech all rights reserved
Revision log:
* 2015-08-12: created by strawmanbobi
@@ -14,7 +14,7 @@ Revision log:
/*
*inclusion
*/
#include "ucon_decode.h"
#include "irda_decode.h"
#ifndef _IRDA_APPLY_H_
#define _IRDA_APPLY_H_

View File

@@ -1,11 +1,11 @@
/**************************************************************************************************
Filename: ucon_decode.c
Filename: irda_decode.c
Revised: Date: 2015-08-01
Revision: Revision: 1.0
Description: This file provides algorithms for UCON IR decode (status type)
Description: This file provides algorithms for IR decode (status type)
Copyright 2014-2016 UCON Tech all rights reserved
Revision log:
* 2015-08-01: created by strawmanbobi
@@ -21,7 +21,7 @@ Revision log:
#include <string.h>
#include "ucon_decode.h"
#include "irda_decode.h"
#include "irda_utils.h"
#include "irda_parse_frame_parameter.h"
#include "irda_parse_ac_parameter.h"
@@ -29,19 +29,6 @@ Revision log:
#include "irda_irframe.h"
#include "irda_apply.h"
#include "irda_lib.h"
#include "bc_parse_parameter.h"
#if defined BOARD_CC254X
#include "ucon_data.h"
#include "ucon_remote.h"
#include "ucon_public.h"
#include "ucon_irda.h"
#include "npi.h"
#endif
#if defined BOARD_MC200
#include "yk_irda.h"
#endif
struct ir_bin_buffer binaryfile;
struct ir_bin_buffer *pirda_buffer = &binaryfile;
@@ -87,7 +74,7 @@ protocol *context = (protocol *) byteArray;
t_bc_protocol *context_bc = (t_bc_protocol *) byteArray;
// ban function table
// fixed swing should not be counted in case of UCON
// fixed swing should not be counted in case of AC
INT8 apply_power(remote_ac_status_t ac_status, UINT8 function_code);
INT8 apply_mode(remote_ac_status_t ac_status, UINT8 function_code);
INT8 apply_wind_speed(remote_ac_status_t ac_status, UINT8 function_code);
@@ -1332,324 +1319,6 @@ UINT16 irda_tv_lib_close()
///////////////////////////////////////////////// TV End /////////////////////////////////////////////////
///////////////////////////////////////////////// BLE Central Begin /////////////////////////////////////////////////
#if (defined BOARD_PC) || (defined BOARD_MT6580)
INT8 binary_ble_open(const char *file)
{
FILE *stream = fopen(file, "rb");
if (stream == NULL)
{
return IR_DECODE_FAILED;
}
fseek(stream, 0, SEEK_END);
pirda_buffer->len = ftell(stream);
fseek(stream, 0, SEEK_SET);
fread(pirda_buffer->data, pirda_buffer->len, 1, stream);
fclose(stream);
return IR_DECODE_SUCCEEDED;
}
#endif
INT8 binary_bc_parse_offset()
{
int i = 0;
UINT16 *phead = (UINT16 *) &pirda_buffer->data[1];
tag_count = pirda_buffer->data[0];
if(TAG_COUNT_FOR_BC_PROTOCOL != tag_count)
{
return IR_DECODE_FAILED;
}
tag_head_offset = (tag_count << 1) + 1;
tags = (t_tag_head *) irda_malloc(tag_count * sizeof(t_tag_head));
if (NULL == tags)
{
return IR_DECODE_FAILED;
}
for (i = 0; i < tag_count; i++)
{
tags[i].tag = bc_tag_index[i];
tags[i].offset = *(phead + i);
if (tags[i].offset == TAG_INVALID)
{
tags[i].len = 0;
}
}
return IR_DECODE_SUCCEEDED;
}
// might be merged with function binary_parse_len
INT8 binary_bc_parse_len()
{
UINT16 i = 0, j = 0;
for (i = 0; i < (tag_count - 1); i++)
{
if (tags[i].offset == TAG_INVALID)
{
continue;
}
for (j = (i + 1); j < tag_count; j++)
{
if (tags[j].offset != TAG_INVALID)
{
break;
}
}
if (j < tag_count)
{
tags[i].len = tags[j].offset - tags[i].offset;
}
else
{
tags[i].len = pirda_buffer->len - tags[i].offset - tag_head_offset;
return IR_DECODE_SUCCEEDED;
}
}
if (tags[tag_count - 1].offset != TAG_INVALID)
{
tags[tag_count - 1].len = pirda_buffer->len - tag_head_offset - tags[tag_count - 1].offset;
}
return IR_DECODE_SUCCEEDED;
}
// might be merged with function binary_parse_data
INT8 binary_bc_parse_data()
{
UINT16 i = 0;
for (i = 0; i < tag_count; i++)
{
tags[i].pdata = pirda_buffer->data + tags[i].offset + tag_head_offset;
}
return IR_DECODE_SUCCEEDED;
}
INT8 free_bc_context()
{
UINT8 i = 0;
if (NULL != context_bc->device_name)
{
irda_free(context_bc->device_name);
context_bc->device_name = NULL;
}
if (NULL != context_bc->conn_ack.commands)
{
irda_free(context_bc->conn_ack.commands);
context_bc->conn_ack.commands = NULL;
}
context_bc->conn_ack.seg_count = 0;
for (i = 0; i < KEY_COUNT; i++)
{
if (NULL != context_bc->generic_command[i].commands)
{
irda_free(context_bc->generic_command[i].commands);
context_bc->generic_command[i].commands = NULL;
}
context_bc->generic_command[i].seg_count = 0;
}
return IR_DECODE_SUCCEEDED;
}
#if (defined BOARD_PC) || (defined BOARD_MT6580)
INT8 bc_lib_open(const char *file_name)
{
return binary_ble_open(file_name);
}
#else
INT8 bc_lib_open(UINT8 *binary_file, UINT16 binary_length)
{
// load bin to buffer
pirda_buffer->data = binary_file;
pirda_buffer->len = binary_length;
pirda_buffer->offset = 0;
return IR_DECODE_SUCCEEDED;
}
#endif
INT8 bc_context_init()
{
irda_memset(context_bc, 0, sizeof(t_bc_protocol));
return IR_DECODE_SUCCEEDED;
}
INT8 bc_lib_parse()
{
UINT16 i = 0;
// suggest not to call init function here for de-couple purpose
#if defined BOARD_CC254X
bc_context_init();
#endif
if (IR_DECODE_FAILED == binary_bc_parse_offset())
{
return IR_DECODE_FAILED;
}
if (IR_DECODE_FAILED == binary_bc_parse_len())
{
return IR_DECODE_FAILED;
}
if (IR_DECODE_FAILED == binary_bc_parse_data())
{
return IR_DECODE_FAILED;
}
#if (defined BOARD_PC)|| (defined BOARD_MT6580)
binary_tags_info();
#endif
// parse tags
for (i = 0; i < tag_count; i++)
{
if (tags[i].len == 0)
{
continue;
}
if (tags[i].tag == TAG_BC_BLE_NAME)
{
context_bc->device_name = (char*)irda_malloc(tags[i].len + 1);
irda_memset(context_bc->device_name, 0x00, tags[i].len + 1);
if (IR_DECODE_FAILED == parse_ble_name(tags[i].pdata, tags[i].len, context_bc->device_name))
{
return IR_DECODE_FAILED;
}
}
else if (tags[i].tag == TAG_BC_NEED_CONN_ACK)
{
if (IR_DECODE_FAILED == parse_ble_need_conn_ack(tags[i].pdata, &context_bc->need_connection_ack))
{
return IR_DECODE_FAILED;
}
}
else if (tags[i].tag == TAG_BC_NAME_LENGTH)
{
if (IR_DECODE_FAILED == parse_ble_name_length(tags[i].pdata, &context_bc->name_length))
{
return IR_DECODE_FAILED;
}
}
else if (tags[i].tag == TAG_BC_NAME_ESS_LENGTH)
{
if (IR_DECODE_FAILED == parse_ble_name_essential_length(tags[i].pdata, &context_bc->name_essential_length))
{
return IR_DECODE_FAILED;
}
}
else if (tags[i].tag == TAG_BC_CONN_ACK_CMD)
{
if (IR_DECODE_FAILED == parse_ble_commands(&tags[i],
&context_bc->conn_ack))
{
return IR_DECODE_FAILED;
}
}
else if (tags[i].tag >= TAG_BC_KEY_0_CMD && tags[i].tag <= TAG_BC_KEY_14_CMD)
{
if (IR_DECODE_FAILED == parse_ble_commands(&tags[i],
&context_bc->generic_command[tags[i].tag - TAG_BC_KEY_0_CMD]))
{
return IR_DECODE_FAILED;
}
}
}
#if (defined BOARD_PC)|| (defined BOARD_MT6580)
IR_PRINTF("\n=====================================\n");
{
IR_PRINTF("\n");
IR_PRINTF("device name = %s\n", context_bc->device_name);
IR_PRINTF("need ack per connected = %d\n", context_bc->need_connection_ack);
IR_PRINTF("length of name = %d\n", context_bc->name_length);
IR_PRINTF("essential length of name = %d\n", context_bc->name_essential_length);
IR_PRINTF("conn ack segment count = %d\n", context_bc->conn_ack.seg_count);
};
IR_PRINTF("\n=====================================\n");
#endif
if(NULL != tags)
{
irda_free(tags);
tags = NULL;
}
return IR_DECODE_SUCCEEDED;
}
UINT16 bc_lib_control(int key_code, t_bc_commands* bc_commands)
{
#if (defined BOARD_PC)|| (defined BOARD_MT6580)
UINT8 seg_index = 0;
UINT8 i = 0;
t_bc_commands key_command = context_bc->generic_command[key_code];
for (seg_index = 0; seg_index < key_command.seg_count; seg_index++)
{
IR_PRINTF("send %d bytes of command with handle 0x%04X\n",
key_command.commands[seg_index].length,
key_command.commands[seg_index].handle);
for(i = 0; i < key_command.commands[seg_index].length; i++)
{
IR_PRINTF("[%02X] ", key_command.commands[seg_index].command[i]);
}
}
IR_PRINTF("\n");
return 0;
#else
if (NULL == bc_commands)
{
return IR_DECODE_FAILED;
}
// CC254X would load some data from flash to complete this procedure
// TODO:
return IR_DECODE_SUCCEEDED;
#endif
}
void bc_lib_close()
{
if (NULL != tags)
{
irda_free(tags);
tags = NULL;
}
// free context
free_bc_context();
return;
}
// utils
int get_valid_keys(int *valid_keys)
{
int i = 0;
for (i = 0; i < KEY_COUNT; i++)
{
if (context_bc->generic_command[i].seg_count != 0)
{
valid_keys[i] = 1;
}
else
{
valid_keys[i] = 0;
}
}
return KEY_COUNT;
}
///////////////////////////////////////////////// BLE Central End /////////////////////////////////////////////////
///////////////////////////////////////////////// Decode Test Begin /////////////////////////////////////////////////
#if (defined BOARD_PC) || (defined BOARD_MT6580)
@@ -1841,52 +1510,6 @@ UINT8 decode_as_tv(char *file_name, UINT8 irda_hex_encode)
return IR_DECODE_SUCCEEDED;
}
UINT8 decode_as_ble_central(char *file_name)
{
// keyboard input
int in_char = 0;
int count = 0;
int key_code = -1;
BOOL op_match = TRUE;
if (IR_DECODE_FAILED == bc_lib_open(file_name))
{
bc_lib_close();
return IR_DECODE_FAILED;
}
// no need to verify return value
bc_context_init();
if (IR_DECODE_FAILED == bc_lib_parse())
{
bc_lib_close();
return IR_DECODE_FAILED;
}
do
{
in_char = getchar();
if (in_char >= '0' && in_char <= '9')
{
key_code = in_char - '0';
bc_lib_control(key_code, NULL);
}
else if (in_char >= 'a' && in_char <= 'f')
{
key_code = 10 + (in_char - 'a');
bc_lib_control(key_code, NULL);
}
else
{
// do nothing
}
} while('Q' != in_char);
bc_lib_close();
return IR_DECODE_SUCCEEDED;
}
#endif
#if defined BOARD_PC
@@ -1918,11 +1541,6 @@ int main(int argc, char *argv[])
decode_as_tv(argv[2], irda_hex_encode);
break;
case '2':
IR_PRINTF("decode binary file as BLE CENTRAL\n");
decode_as_ble_central(argv[2]);
break;
default:
IR_PRINTF("decode functionality error !\n");
break;

View File

@@ -1,11 +1,11 @@
/**************************************************************************************************
Filename: ucon_decode.h
Filename: irda_decode.h
Revised: Date: 2015-08-01
Revision: Revision: 1.0
Description: This file provides algorithms for UCON IR decode
Description: This file provides algorithms for IR decode
Copyright 2014-2016 UCON Tech all rights reserved
Revision log:
* 2015-08-01: created by strawmanbobi
@@ -16,15 +16,6 @@ Revision log:
#include <stdio.h>
#include "irda_defs.h"
#if defined BOARD_CC2541
#include "osal.h"
#include "ucon_remote.h"
#endif
#if defined BOARD_MC200
#include "wmstdio.h"
#include "wm_os.h"
#endif
#define TAG_COUNT_FOR_PROTOCOL 29
#define TAG_COUNT_FOR_BC_PROTOCOL 20

View File

@@ -1,20 +1,20 @@
/**************************************************************************************************
Filename: ucon_decode_jni.c
Filename: irda_decode_jni.c
Revised: Date: 2016-03-21
Revision: Revision: 1.0
Description: This file links to java layer for Android application
Copyright 2014-2016 UCON Tech all rights reserved
Revision log:
* 2016-03-21: created by strawmanbobi
**************************************************************************************************/
#include <jni.h>
#include <stdio.h>
#include "include/ucon_decode_jni.h"
#include "include/irda_decode_jni.h"
#include "irda_defs.h"
#include "ucon_decode.h"
#include "irda_decode.h"
// function declaration
void FillBCCommandValuesToJni(JNIEnv* env, jobject j_bc_command, jclass bccommand_class, t_bc_command bc_command);

View File

@@ -3,9 +3,9 @@ Filename: irda_defs.h
Revised: Date: 2015-08-26
Revision: Revision: 1.0
Description: This file provides algorithms for UCON IR decode
Description: This file provides algorithms for IR decode
Copyright 2014-2016 UCON Tech all rights reserved
Revision log:
* 2015-08-01: created by strawmanbobi
@@ -21,7 +21,7 @@ Revision log:
#if defined BOARD_MT6580
#include <android/log.h>
#define LOG_TAG "ucon_decode"
#define LOG_TAG "irda_decode"
#endif
#ifndef PARSE_IR_DEFS_H
@@ -49,7 +49,7 @@ typedef unsigned char BOOL;
#define IR_PRINTF(A)
#if !defined BOARD_CC254X
#define USER_DATA_SIZE UCON_USER_DATA_SIZE
#define USER_DATA_SIZE IRDA_USER_DATA_SIZE
#endif
#elif defined BOARD_MC200

View File

@@ -3,9 +3,9 @@ Filename: irda_irframe.c
Revised: Date: 2015-08-01
Revision: Revision: 1.0
Description: This file provides algorithms for UCON IR decode
Description: This file provides algorithms for IR frame build
Copyright 2014-2016 UCON Tech all rights reserved
Revision log:
* 2015-08-01: created by strawmanbobi
@@ -13,7 +13,7 @@ Revision log:
#include <stdio.h>
#include "irda_irframe.h"
#include "ucon_decode.h"
#include "irda_decode.h"
extern protocol* context;

View File

@@ -3,9 +3,9 @@ Filename: irda_utils.c
Revised: Date: 2015-08-26
Revision: Revision: 1.0
Description: This file provides generic utils for UCON IRDA algorithms
Description: This file provides generic utils for IR frame build
Copyright 2014-2016 UCON Tech all rights reserved
Revision log:
* 2015-08-01: created by strawmanbobi

View File

@@ -3,9 +3,9 @@ Filename: irda_lib.c
Revised: Date: 2016-01-21
Revision: Revision: 1.0
Description: This file provides algorithms for UCON IR decode (command type)
Description: This file provides algorithms for IR decode (compressed command type)
Copyright 2014-2016 UCON Tech all rights reserved
Revision log:
* 2016-01-21: created by strawmanbobi
@@ -21,14 +21,6 @@ Revision log:
#include "irda_lib.h"
#include "string.h"
#if defined BOARD_CC254X
#include "ucon_public.h"
#include "ucon_data.h"
#include "ucon_remote.h"
#include "OSAL.h"
#include "npi.h"
#endif
/**************************************************************************************************
* MACROS

View File

@@ -3,9 +3,9 @@ Filename: irda_lib.h
Revised: Date: 2016-02-23
Revision: Revision: 1.0
Description: This file provides algorithms for UCON IR decode (command type)
Description: This file provides algorithms for IR decode (compressed command type)
Copyright 2014-2016 UCON Tech all rights reserved
Revision log:
* 2016-01-21: created by strawmanbobi
@@ -21,10 +21,6 @@ Revision log:
#include "irda_defs.h"
#if defined BOARD_CC254X
#include "ucon_remote.h"
#endif
/**************************************************************************************************
* MACROS
**************************************************************************************************/

View File

@@ -3,9 +3,9 @@ Filename: irda_parse_ac_parameter.c
Revised: Date: 2015-08-12
Revision: Revision: 1.0
Description: This file provides algorithms for UCON IR decode for AC functionality parameters
Description: This file provides algorithms for IR decode for AC functionality parameters
Copyright 2014-2016 UCON Tech all rights reserved
Revision log:
* 2015-08-12: created by strawmanbobi
@@ -18,7 +18,7 @@ Revision log:
#include <string.h>
#include "irda_utils.h"
#include "irda_parse_ac_parameter.h"
#include "ucon_decode.h"
#include "irda_decode.h"
/*
* global vars

View File

@@ -3,9 +3,9 @@ Filename: irda_parse_ac_parameter.h
Revised: Date: 2015-08-12
Revision: Revision: 1.0
Description: This file provides algorithms for UCON IR decode for AC functionality parameters
Description: This file provides algorithms for IR decode for AC functionality parameters
Copyright 2014-2016 UCON Tech all rights reserved
Revision log:
* 2015-08-12: created by strawmanbobi
@@ -14,7 +14,7 @@ Revision log:
/*
*inclusion
*/
#include "ucon_decode.h"
#include "irda_decode.h"
#ifndef _IRDA_PARSE_AC_PARAMETER_H_
#define _IRDA_PARSE_AC_PARAMETER_H_

View File

@@ -3,9 +3,9 @@ Filename: irda_parse_forbidden_info.c
Revised: Date: 2015-08-05
Revision: Revision: 1.0
Description: This file provides algorithms for UCON IR decode for TAG 150x
Description: This file provides algorithms for IR decode for TAG 150x
Copyright 2014-2016 UCON Tech all rights reserved
Revision log:
* 2015-08-05: created by strawmanbobi
@@ -14,7 +14,7 @@ Revision log:
/*
*inclusion
*/
#include "ucon_decode.h"
#include "irda_decode.h"
#include "irda_utils.h"
#include "irda_parse_forbidden_info.h"
#include <stdio.h>

View File

@@ -3,9 +3,9 @@ Filename: irda_parse_forbidden_info.h
Revised: Date: 2015-08-05
Revision: Revision: 1.0
Description: This file provides algorithms for UCON IR decode for TAG 1002
Description: This file provides algorithms for IR decode for TAG 1002
Copyright 2014-2016 UCON Tech all rights reserved
Revision log:
* 2015-08-05: created by strawmanbobi
@@ -14,7 +14,7 @@ Revision log:
/*
*inclusion
*/
#include "ucon_decode.h"
#include "irda_decode.h"
#ifndef _IRDA_PARSE_PARSE_150X_H_
#define _IRDA_PARSE_PARSE_150X_H_

View File

@@ -3,9 +3,9 @@ Filename: irda_parse_frame_parameter.c
Revised: Date: 2015-08-11
Revision: Revision: 1.0
Description: This file provides algorithms for UCON IR decode for AC frame parameters
Description: This file provides algorithms for IR decode for AC frame parameters
Copyright 2014-2016 UCON Tech all rights reserved
Revision log:
* 2015-08-11: created by strawmanbobi
@@ -19,7 +19,7 @@ Revision log:
#include <string.h>
#include "irda_utils.h"
#include "irda_parse_frame_parameter.h"
#include "ucon_decode.h"
#include "irda_decode.h"
/*
* global vars

View File

@@ -3,9 +3,9 @@ Filename: irda_parse_frame_parameter.h
Revised: Date: 2015-08-11
Revision: Revision: 1.0
Description: This file provides algorithms for UCON IR decode for AC frame parameters
Description: This file provides algorithms for IR decode for AC frame parameters
Copyright 2014-2016 UCON Tech all rights reserved
Revision log:
* 2015-08-11: created by strawmanbobi
@@ -14,7 +14,7 @@ Revision log:
/*
*inclusion
*/
#include "ucon_decode.h"
#include "irda_decode.h"
#ifndef _IRDA_PARSE_FRAME_PARAMETER_H_
#define _IRDA_PARSE_FRAME_PARAMETER_H_

View File

@@ -3,9 +3,9 @@ Filename: irda_utils.c
Revised: Date: 2015-08-26
Revision: Revision: 1.0
Description: This file provides generic utils for UCON IRDA algorithms
Description: This file provides generic utils for IRDA algorithms
Copyright 2014-2016 UCON Tech all rights reserved
Revision log:
* 2015-08-01: created by strawmanbobi
@@ -15,7 +15,7 @@ Revision log:
#include <stdlib.h>
#include "irda_utils.h"
#include "ucon_decode.h"
#include "irda_decode.h"
/*
*0123456789abcdef/0123456789ABCDEF

View File

@@ -3,15 +3,15 @@ Filename: irda_utils.c
Revised: Date: 2015-08-26
Revision: Revision: 1.0
Description: This file provides generic utils for UCON IRDA algorithms
Description: This file provides generic utils for IRDA algorithms
Copyright 2014-2016 UCON Tech all rights reserved
Revision log:
* 2015-08-01: created by strawmanbobi
**************************************************************************************************/
#include "irda_defs.h"
#include "ucon_decode.h"
#include "irda_decode.h"
#ifndef _IRDA_UTILS_H_
#define _IRDA_UTILS_H_