summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--IR-Data/lg-air-15kHz.txt84
-rw-r--r--IR-Data/test-suite.sh1
-rw-r--r--README.txt4
-rw-r--r--irmp.c81
-rw-r--r--irmp.h8
-rw-r--r--irmpconfig.h3
-rw-r--r--irmpprotocols.h15
7 files changed, 184 insertions, 12 deletions
diff --git a/IR-Data/lg-air-15kHz.txt b/IR-Data/lg-air-15kHz.txt
new file mode 100644
index 0000000..3d747be
--- /dev/null
+++ b/IR-Data/lg-air-15kHz.txt
@@ -0,0 +1,84 @@
+# ON1 (23C)
+0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001111111111111111111111111111111111111111111111111111111111111110000000011111111111111111111111000000001111111100000000111111110000000011111110000000011111111111111111111111100000000111111100000000111111110000000001111111000000001111111000000000111111100000000011111110000000011111110000000001111111000000000111111100000000111111100000000011111110000000001111111111111111111111000000000111111100000000011111110000000011111111000000001111111000000000111111111111111111111110000000011111110000000001111111000000000111111111111111111111100000000011111111111111111111111000000001111111100000000111111100000000011111111111111111111
+# OFF1
+0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001111111111111111111111111111111111111111111111111111111111111100000000011111111111111111111111000000000111111100000000111111110000000011111110000000001111111111111111111111100000000111111100000000011111110000000001111111000000001111111111111111111111100000000011111111111111111111110000000001111111000000000111111100000000111111100000000011111110000000011111111000000001111111000000000111111100000000011111110000000011111111000000001111111000000000111111100000000111111111111111111111110000000001111111000000001111111111111111111111100000000011111110000000001111111000000001111111000000001111111111111111111111110000000011111111111111111111
+# ON2 (23C)
+000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000111111111111111111111111111111111111111111111111111111111111110000000011111111111111111111111100000000111111110000000011111110000000001111111000000000111111111111111111111100000000011111110000000001111111000000001111111000000000111111100000000111111110000000011111110000000001111111000000000111111100000000111111100000000011111110000000001111111000000001111111111111111111111100000000111111110000000011111111000000001111111000000000111111100000000111111111111111111111110000000001111111000000000111111100000000111111111111111111111110000000001111111111111111111111000000001111111100000000111111110000000011111111111111111111
+# OFF2
+0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000111111111111111111111111111111111111111111111111111111111111100000000011111111111111111111111000000000111111100000000111111100000000011111110000000001111111111111111111111000000000111111100000000111111110000000011111110000000001111111111111111111111100000000111111111111111111111110000000001111111000000001111111100000000111111100000000111111110000000011111111000000001111111000000000111111100000000011111110000000011111110000000001111111000000000111111100000000111111111111111111111110000000001111111000000001111111111111111111111100000000011111110000000011111110000000001111111000000000111111111111111111111100000000011111111111111111111
+# ON3 (23C)
+0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001111111111111111111111111111111111111111111111111111111111111110000000011111111111111111111111000000000111111100000000011111110000000011111111000000001111111111111111111111100000000111111110000000011111110000000001111111000000000111111100000000111111100000000011111110000000001111111000000001111111000000000111111100000000011111110000000011111110000000001111111111111111111111100000000111111100000000011111110000000011111111000000001111111000000000111111111111111111111110000000011111110000000001111111000000000111111111111111111111110000000011111111111111111111111000000001111111100000000111111110000000011111111111111111111
+# OFF3
+0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001111111111111111111111111111111111111111111111111111111111111100000000011111111111111111111111000000001111111100000000111111100000000011111110000000011111111111111111111111000000000111111100000000011111110000000011111110000000001111111111111111111111100000000111111111111111111111110000000001111111000000001111111000000000111111100000000111111110000000011111110000000001111111000000000111111100000000111111100000000011111110000000001111111000000001111111100000000111111111111111111111110000000011111111000000001111111111111111111111100000000111111110000000011111110000000001111111000000001111111111111111111111100000000011111111111111111111
+# ON4 (23C)
+0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001111111111111111111111111111111111111111111111111111111111111110000000011111111111111111111111000000000111111100000000011111110000000011111110000000001111111111111111111111100000000111111110000000011111110000000001111111000000001111111100000000111111100000000011111110000000001111111000000001111111000000000111111100000000011111110000000011111110000000001111111111111111111111100000000111111100000000011111110000000001111111000000001111111000000000111111111111111111111110000000011111110000000001111111000000000111111111111111111111100000000011111111111111111111111000000001111111100000000111111100000000011111111111111111111
+# OFF4
+0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001111111111111111111111111111111111111111111111111111111111111100000000011111111111111111111111000000001111111000000000111111100000000111111110000000011111111111111111111111000000000111111100000000111111100000000011111110000000001111111111111111111111000000000111111111111111111111110000000011111111000000001111111000000000111111100000000111111110000000011111110000000001111111000000000111111100000000111111100000000011111110000000001111111000000001111111000000000111111111111111111111110000000011111110000000001111111111111111111111100000000111111100000000011111110000000001111111000000001111111111111111111111100000000011111111111111111111
+# TEMP UP (24C)
+00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011111111111111111111111111111111111111111111111111111111111111000000000111111111111111111111110000000011111110000000001111111000000000111111100000000011111111111111111111110000000001111111000000001111111100000000111111100000000011111110000000011111111000000001111111000000000111111100000000011111111111111111111110000000001111111000000000111111100000000111111100000000011111111111111111111111000000001111111000000000111111100000000011111111111111111111110000000001111111000000000111111111111111111111100000000011111110000000001111111000000001111111100000000111111111111111111111110000000011111111000000001111111111111111111111100000000011111111111111111111
+# TEMP UP (25C)
+00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001111111111111111111111111111111111111111111111111111111111111100000000011111111111111111111110000000001111111000000000111111100000000111111110000000011111111111111111111111000000001111111100000000111111100000000011111110000000001111111000000001111111000000000111111100000000011111110000000011111111111111111111111000000000111111100000000011111110000000011111110000000001111111111111111111111100000000111111100000000011111111111111111111111000000001111111000000000111111100000000011111111111111111111110000000001111111000000000111111100000000111111100000000011111111111111111111111000000001111111111111111111111100000000011111110000000011111111111111111111
+# TEMP UP (26C)
+000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000111111111111111111111111111111111111111111111111111111111111110000000001111111111111111111111100000000111111110000000001111110000000011111111000000000111111111111111111111100000000011111110000000001111111000000001111111000000000111111100000000011111110000000011111110000000001111111000000000111111111111111111111100000000011111110000000001111111000000001111111100000000111111111111111111111110000000001111111000000001111111111111111111111100000000011111111111111111111110000000001111111000000000111111111111111111111110000000011111110000000001111111000000000111111100000000111111111111111111111110000000011111111111111111111111000000000111111111111111111111110000000011111111111111111111
+# OFF5
+0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001111111111111111111111111111111111111111111111111111111111111100000000011111111111111111111111000000000111111100000000111111110000000011111110000000001111111111111111111111100000000111111100000000011111110000000001111111000000001111111111111111111111100000000011111111111111111111110000000001111111000000000111111100000000111111100000000011111110000000001111111000000001111111000000000111111100000000011111110000000011111110000000001111111000000000111111100000000111111111111111111111110000000001111111000000001111111111111111111111100000000011111110000000011111111000000001111111000000001111111111111111111111110000000011111111111111111111
+# ON6
+000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000111111111111111111111111111111111111111111111111111111111111111000000001111111111111111111111100000000011111110000000001111111000000001111111100000000111111111111111111111110000000011111111000000001111111000000000111111100000000011111110000000011111110000000001111111000000000111111100000000111111100000000011111110000000001111111000000001111111000000000111111111111111111111110000000011111110000000001111111111111111111111100000000111111111111111111111110000000011111111000000001111111111111111111111100000000111111110000000011111111000000001111111111111111111111100000000111111111111111111111110000000001111111111111111111111100000000111111111111111111111110000000011111111111111111111
+# OFF6
+0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000111111111111111111111111111111111111111111111111111111111111110000000011111111111111111111111100000000111111100000000111111110000000011111111000000001111111111111111111111100000000011111110000000011111110000000001111111000000000111111111111111111111100000000011111111111111111111111000000001111111000000000111111100000000011111110000000011111110000000001111111000000000111111100000000111111100000000011111110000000001111111000000001111111000000000111111100000000011111111111111111111111000000001111111000000000111111111111111111111110000000011111110000000001111111000000000111111100000000111111111111111111111110000000011111111111111111111
+ON 26C
+0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001111111111111111111111111111111111111111111111111111111111111110000000011111111111111111111111100000000111111100000000011111110000000001111111000000001111111111111111111111100000000011111110000000011111110000000001111111000000000111111100000000111111100000000011111110000000011111111000000001111111000000000111111100000000011111110000000011111111000000001111111111111111111111100000000111111110000000001111111111111111111111000000000111111111111111111111100000000011111110000000001111111111111111111111000000000111111100000000011111110000000011111111111111111111111000000001111111111111111111111100000000011111111111111111111111000000001111111111111111111111100000000011111111111111111111
+# TEMP DOWN 25C
+00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011111111111111111111111111111111111111111111111111111111111111000000000111111111111111111111110000000001111111000000001111111000000000111111100000000011111111111111111111110000000001111111000000000111111100000000111111100000000011111110000000001111111000000001111111000000000111111100000000111111111111111111111110000000001111111000000000111111100000000111111100000000011111111111111111111111000000000111111100000000111111111111111111111110000000011111111000000001111111000000000111111111111111111111110000000011111110000000001111111000000000111111100000000111111111111111111111110000000001111111111111111111111000000000111111100000000011111111111111111111
+# TEMP DOWN 24C
+00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011111111111111111111111111111111111111111111111111111111111111100000000011111111111111111111111000000001111111000000000111111100000000011111110000000011111111111111111111111000000000111111100000000111111110000000011111110000000001111111000000001111111100000000111111100000000011111110000000011111111111111111111111000000000111111100000000111111110000000011111110000000001111111111111111111111100000000111111100000000011111110000000001111111111111111111111000000000111111100000000111111111111111111111110000000001111111000000000111111100000000111111100000000011111111111111111111111000000001111111100000000111111111111111111111110000000011111111111111111111
+# TEMP DOWN 23C
+000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000111111111111111111111111111111111111111111111111111111111111110000000001111111111111111111111100000000011111110000000011111110000000001111111000000000111111111111111111111100000000011111110000000001111111000000001111111100000000111111100000000011111110000000011111111000000001111111000000001111111111111111111111110000000011111110000000001111111000000001111111100000000111111111111111111111110000000001111111000000001111111000000000111111100000000011111110000000011111111111111111111111000000000111111100000000111111100000000011111110000000001111111111111111111111000000000111111100000000011111110000000011111111111111111111
+# OFF
+0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000111111111111111111111111111111111111111111111111111111111111110000000011111111111111111111111000000000111111100000000111111110000000011111110000000001111111111111111111111100000000111111100000000111111110000000001111111000000001111111111111111111111100000000111111111111111111111110000000001111111000000000111111100000000111111100000000011111110000000001111111000000001111111100000001111111100000000011111110000000011111111000000001111111000000001111111100000000111111111111111111111110000000011111111000000001111111111111111111111100000000011111110000000001111111000000001111111000000000111111111111111111111110000000011111111111111111111
+# ON 23C
+000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000111111111111111111111111111111111111111111111111111111111111110000000001111111111111111111111100000000111111110000000011111110000000011111111000000001111111111111111111111100000000011111110000000001111111000000001111111000000000111111100000000011111110000000011111110000000001111111000000000111111100000000111111100000000011111110000000001111111000000001111111111111111111111100000000011111110000000011111110000000001111111000000000111111100000000011111111111111111111110000000001111111000000001111111100000000111111111111111111111110000000011111111111111111111111000000000111111100000000111111110000000011111111111111111111
+# OFF
+0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001111111111111111111111111111111111111111111111111111111111111100000000111111111111111111111111000000001111111000000000111111100000000111111110000000011111111111111111111111000000000111111100000000111111110000000011111110000000011111111111111111111111100000000111111111111111111111110000000011111111000000001111111000000000111111100000000011111110000000011111110000000001111111000000001111111100000000111111100000000011111110000000001111111000000001111111000000000111111111111111111111110000000011111111000000001111111111111111111111100000000111111100000000011111110000000011111111000000001111111111111111111111100000000011111111111111111111
+# ON (mode0, 23C)
+000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000111111111111111111111111111111111111111111111111111111111111110000000001111111111111111111111100000000111111100000000011111110000000001111111000000001111111111111111111111100000000011111110000000011111110000000001111111000000000111111100000000111111100000000011111110000000011111111000000001111111100000000111111100000000011111110000000011111111000000001111111111111111111111100000000011111110000000011111110000000001111111000000000111111100000000111111111111111111111110000000001111111000000000111111100000000111111111111111111111110000000001111111111111111111111000000000111111100000000011111110000000011111111111111111111
+# MODE (to mode1, 22C - when switching to mode1 temp automaticall sets to 22C)
+0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001111111111111111111111111111111111111111111111111111111111111100000000011111111111111111111111000000001111111100000000111111100000000011111110000000001111111111111111111111000000000111111100000000011111110000000011111110000000011111111000000000111111100000000111111100000000011111110000000001111111111111111111111000000000111111100000000011111111111111111111110000000001111111111111111111111100000000111111100000000011111111111111111111111000000001111111111111111111111100000000011111111111111111111111000000001111111000000001111111111111111111111110000000011111110000000001111111000000001111111100000000111111111111111111111110000000001111111111111111111111000000000111111100000000011111111111111111111
+# OFF
+0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001111111111111111111111111111111111111111111111111111111111111100000000011111111111111111111111000000001111111000000000111111100000000011111110000000011111111111111111111111000000000111111100000000111111100000000011111110000000001111111111111111111111000000000111111111111111111111110000000011111110000000001111111000000000111111100000000111111110000000011111110000000001111111000000001111111100000000111111100000000011111110000000011111111000000001111111000000000111111111111111111111110000000011111110000000001111111111111111111111100000000111111100000000011111110000000001111111000000001111111111111111111111100000000011111111111111111111
+# ON (mode1, 22C)
+0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001111111111111111111111111111111111111111111111111111111111111100000000011111111111111111111111000000000111111100000000111111110000000011111110000000001111111111111111111111100000000111111100000000011111110000000001111111000000001111111000000000111111100000000011111110000000011111110000000001111111000000000111111100000000111111111111111111111110000000001111111111111111111111100000000111111100000000011111111111111111111111000000001111111111111111111111100000000111111111111111111111110000000001111111000000001111111111111111111111100000000011111110000000001111111000000001111111111111111111111100000000011111111111111111111110000000001111111111111111111111100000000111111100000000011111111111111111111
+# MODE (to mode2, no temperature displayed)
+00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011111111111111111111111111111111111111111111111111111111111111100000000011111111111111111111110000000001111111000000000111111100000000111111100000000011111111111111111111111000000001111111000000000111111100000000111111110000000011111110000000001111111000000000111111100000000111111100000000011111111111111111111111000000001111111100000000111111100000000011111111111111111111111000000001111111111111111111111100000000111111110000000011111110000000001111111000000001111111100000000111111111111111111111110000000001111111000000001111111000000000111111100000000011111111111111111111110000000011111111000000000111111111111111111111100000000011111111111111111111
+# OFF
+0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001111111111111111111111111111111111111111111111111111111111111100000000111111111111111111111111000000001111111100000000111111100000000011111110000000001111111111111111111111000000000111111100000000111111110000000011111110000000001111111111111111111111100000000111111111111111111111110000000001111111000000001111111100000001111111100000000111111110000000011111111000000001111111000000001111111100000000111111110000000011111110000000001111111000000001111111100000000111111111111111111111110000000011111111000000001111111111111111111111100000000011111110000000011111110000000001111111000000001111111111111111111111100000000011111111111111111111
+# ON (mode2)
+00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001111111111111111111111111111111111111111111111111111111111111100000000011111111111111111111111000000001111111000000000111111100000000011111110000000011111111111111111111111000000000111111100000000111111110000000011111110000000001111111000000001111111100000000111111100000000011111110000000001111111000000001111111000000000111111100000000011111111111111111111110000000001111111111111111111111100000000111111100000000011111110000000001111111000000001111111000000000111111111111111111111110000000011111111000000001111111000000000111111111111111111111110000000011111111111111111111111000000001111111100000000111111111111111111111110000000011111111111111111111
+# MODE (to mode3, 23C)
+0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001111111111111111111111111111111111111111111111111111111111111100000000011111111111111111111111000000001111111100000000111111100000000011111110000000001111111111111111111111000000000111111100000000111111110000000001111111000000001111111000000000111111100000000111111110000000011111110000000001111111111111111111111100000000111111111111111111111110000000001111111000000001111111000000000111111111111111111111110000000011111111000000001111111000000001111111100000000111111110000000011111111111111111111111000000001111111100000000111111100000000011111111111111111111111000000001111111000000000111111100000000011111110000000011111111111111111111
+# OFF
+0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000111111111111111111111111111111111111111111111111111111111111110000000001111111111111111111111000000000111111100000000011111110000000011111110000000001111111111111111111111100000000111111100000000011111110000000011111111000000001111111111111111111111100000000011111111111111111111111000000001111111000000000111111100000000011111110000000011111110000000011111111000000000111111100000000111111100000000011111110000000001111111000000001111111000000000111111100000000011111111111111111111110000000001111111000000001111111111111111111111100000000011111110000000001111111000000001111111000000000111111111111111111111110000000011111111111111111111
+# ON (mode3, 23C)
+00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011111111111111111111111111111111111111111111111111111111111111000000000111111111111111111111110000000011111110000000001111111000000000111111100000000111111111111111111111110000000001111111000000001111111000000000111111100000000011111110000000011111111000000001111111000000000111111100000000111111110000000011111111111111111111111000000001111111100000000111111100000000011111111111111111111111000000001111111000000000111111100000000111111110000000011111110000000001111111111111111111111100000000111111100000000011111110000000001111111000000001111111000000000111111100000000011111110000000011111111111111111111
+# MODE (to mode0, 23C)
+000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000111111111111111111111111111111111111111111111111111111111111110000000001111111111111111111111100000000111111110000000011111110000000001111111000000001111111111111111111111100000000011111110000000011111111000000001111111000000000111111100000000011111110000000011111110000000001111111000000000111111111111111111111100000000011111110000000011111111000000000111111000000000111111111111111111111110000000011111111000000001111111000000000111111100000000011111110000000011111111111111111111111000000000111111100000000111111100000000011111110000000001111111111111111111111100000000111111100000000111111110000000011111111111111111111
+# OFF
+00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001111111111111111111111111111111111111111111111111111111111111100000000111111111111111111111110000000001111111000000001111111100000000111111100000000111111111111111111111111000000001111111000000001111111100000000111111110000000011111111111111111111111000000001111111111111111111111100000000011111110000000001111111000000001111111100000000111111100000000011111110000000001111111000000001111111100000000111111100000000011111110000000001111111000000001111111000000000111111111111111111111110000000011111110000000001111111111111111111111100000000111111100000000011111110000000001111111000000001111111111111111111111100000000011111111111111111111
+# VENTILLATION SLOW
+00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011111111111111111111111111111111111111111111111111111111111111100000000011111111111111111111110000000001111111000000000111111100000000111111100000000011111111111111111111111000000001111111000000000111111100000000011111110000000011111110000000001111111000000000111111100000000111111110000000011111111111111111111111000000001111111100000000111111100000000011111110000000011111111000000001111111000000001111111111111111111111110000000011111111111111111111111000000000111111100000000111111100000000011111110000000001111111000000001111111111111111111111100000000011111110000000011111111111111111111111000000000111111111111111111111100000000011111111111111111111
+# VENTILLATION MEDIUM
+00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011111111111111111111111111111111111111111111111111111111111111000000000111111111111111111111110000000011111110000000001111111000000001111111100000000111111111111111111111110000000011111111000000001111111000000000111111100000000011111110000000011111110000000001111111000000000111111100000000111111111111111111111110000000001111111000000000111111000000000111111100000000011111110000000011111110000000001111111111111111111111100000000111111111111111111111110000000001111111000000001111111000000000111111111111111111111110000000011111111000000001111111111111111111111100000000111111111111111111111110000000001111111000000000111111111111111111111100000000011111111111111111111
+# VENTILLATION HIGH
+000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000111111111111111111111111111111111111111111111111111111111111110000000001111111111111111111111100000000111111100000000011111110000000011111111000000001111111111111111111111100000000011111110000000011111110000000001111111000000000111111100000000111111110000000011111110000000001111111000000000111111111111111111111100000000011111110000000011111111000000001111111000000000111111100000000011111110000000011111111111111111111111000000000111111111111111111111100000000011111110000000001111111111111111111111000000000111111100000000011111110000000011111111111111111111111000000000111111111111111111111110000000011111111111111111111111000000000111111111111111111111100000000011111111111111111111
+# VENTILLATION LIGHT
+00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001111111111111111111111111111111111111111111111111111111111111100000000011111111111111111111111000000001111111000000000111111100000000111111110000000011111111111111111111111000000000111111100000000111111110000000011111110000000001111111000000001111111100000000111111100000000011111110000000001111111111111111111111100000000111111100000000011111110000000011111111000000001111111000000001111111100000000011111111111111111111110000000001111111111111111111111100000000111111100000000011111111111111111111111000000001111111000000000111111111111111111111110000000011111110000000001111111000000000111111100000000111111100000000011111111111111111111
+# VENTILLATION SLOW
+0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001111111111111111111111111111111111111111111111111111111111111100000000111111111111111111111111000000001111111000000000111111100000000011111110000000011111111111111111111111000000000111111100000000111111100000000011111110000000001111111000000001111111000000000111111100000000011111110000000011111111111111111111111000000000111111100000000111111100000000011111110000000001111111000000001111111100000000111111111111111111111110000000011111111111111111111111000000001111111100000000011111110000000011111110000000001111111000000000111111111111111111111100000000011111110000000001111111111111111111111000000000111111111111111111111110000000011111111111111111111
+# SWING ON
+00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011111111111111111111111111111111111111111111111111111111111111000000001111111111111111111111110000000011111110000000001111111000000001111111100000000111111111111111111111110000000001111111000000001111111100000000111111100000000111111110000000011111111000000011111111000000001111111111111111111111110000000011111110000000001111111000000000111111100000000111111110000000011111110000000011111111000000001111111100000000111111100000000011111110000000011111111000000001111111000000000111111100000000011111110000000011111110000000011111111000000001111111111111111111111100000000011111111111111111111
+# SWING OFF
+0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001111111111111111111111111111111111111111111111111111111111111100000000011111111111111111111111000000001111111000000000111111100000000111111110000000001111111111111111111111000000000111111100000000111111100000000011111110000000001111111000000001111111100000000111111100000000011111111111111111111111000000001111111000000001111111100000000111111110000000011111110000000001111111000000001111111100000000111111100000000011111110000000001111111000000011111111000000000111111100000000011111110000000011111110000000011111111000000000111111100000000111111111111111111111110000000011111111111111111111
+# SWING ON
+000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000011111111111111111111111111111111111111111111111111111111111110000000001111111111111111111111100000000011111110000000011111111000000001111111000000001111111111111111111111110000000011111110000000011111111000000001111111100000000111111100000000011111110000000011111111000000001111111111111111111111100000000011111110000000011111111000000001111111000000000111111100000000011111110000000011111110000000001111111000000001111111100000000111111100000000111111110000000001111111000000001111111000000000111111100000000111111110000000011111110000000001111111111111111111111100000000011111111111111111111
+# TURN OFF (18C currently)
+0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001111111111111111111111111111111111111111111111111111111111111100000000011111111111111111111111000000000111111100000000111111100000000011111110000000001111111111111111111111000000000111111100000000011111110000000011111110000000001111111111111111111111100000000111111111111111111111110000000001111111000000001111111100000000011111100000000011111110000000011111111000000001111111000000000111111100000000111111110000000011111110000000011111111000000000111111100000000111111111111111111111110000000001111111000000001111111111111111111111100000000011111110000000011111110000000001111111000000000111111111111111111111100000000011111111111111111111
diff --git a/IR-Data/test-suite.sh b/IR-Data/test-suite.sh
index 3c7be1d..7176020 100644
--- a/IR-Data/test-suite.sh
+++ b/IR-Data/test-suite.sh
@@ -95,6 +95,7 @@ for j in \
denon-rc-176-repeat-15kHz.txt \
irc-15kHz.txt \
kathrein-15kHz.txt \
+ lg-air-15kHz.txt \
recs80-15kHz.txt \
saa3004-15kHz.txt \
samsung32-15kHz.txt \
diff --git a/README.txt b/README.txt
index fba99f2..9f50115 100644
--- a/README.txt
+++ b/README.txt
@@ -1,8 +1,8 @@
IRMP - Infrared Multi Protocol Decoder
--------------------------------------
-Version IRMP: 2.5.2 03.06.2014
-Version IRSND: 2.5.2 03.06.2014
+Version IRMP: 2.5.3 05.06.2014
+Version IRSND: 2.5.3 05.06.2014
Dokumentation:
diff --git a/irmp.c b/irmp.c
index 371e94e..09a3513 100644
--- a/irmp.c
+++ b/irmp.c
@@ -3,7 +3,7 @@
*
* Copyright (c) 2009-2013 Frank Meyer - frank(at)fli4l.de
*
- * $Id: irmp.c,v 1.148 2014/05/30 12:48:54 fm Exp $
+ * $Id: irmp.c,v 1.149 2014/06/05 21:00:06 fm Exp $
*
* ATMEGA88 @ 8 MHz
*
@@ -537,6 +537,7 @@ irmp_protocol_names[IRMP_N_PROTOCOLS + 1] =
"RCMM24",
"RCMM12",
"SPEAKER",
+ "LGAIR",
"RADIO1"
};
@@ -942,6 +943,31 @@ static const PROGMEM IRMP_PARAMETER nec42_param =
#endif
+#if IRMP_SUPPORT_LGAIR_PROTOCOL == 1
+
+static const PROGMEM IRMP_PARAMETER lgair_param =
+{
+ IRMP_LGAIR_PROTOCOL, // protocol: ir protocol
+ NEC_PULSE_LEN_MIN, // pulse_1_len_min: minimum length of pulse with bit value 1
+ NEC_PULSE_LEN_MAX, // pulse_1_len_max: maximum length of pulse with bit value 1
+ NEC_1_PAUSE_LEN_MIN, // pause_1_len_min: minimum length of pause with bit value 1
+ NEC_1_PAUSE_LEN_MAX, // pause_1_len_max: maximum length of pause with bit value 1
+ NEC_PULSE_LEN_MIN, // pulse_0_len_min: minimum length of pulse with bit value 0
+ NEC_PULSE_LEN_MAX, // pulse_0_len_max: maximum length of pulse with bit value 0
+ NEC_0_PAUSE_LEN_MIN, // pause_0_len_min: minimum length of pause with bit value 0
+ NEC_0_PAUSE_LEN_MAX, // pause_0_len_max: maximum length of pause with bit value 0
+ LGAIR_ADDRESS_OFFSET, // address_offset: address offset
+ LGAIR_ADDRESS_OFFSET + LGAIR_ADDRESS_LEN, // address_end: end of address
+ LGAIR_COMMAND_OFFSET, // command_offset: command offset
+ LGAIR_COMMAND_OFFSET + LGAIR_COMMAND_LEN, // command_end: end of command
+ LGAIR_COMPLETE_DATA_LEN, // complete_len: complete length of frame
+ NEC_STOP_BIT, // stop_bit: flag: frame has stop bit
+ NEC_LSB, // lsb_first: flag: LSB first
+ NEC_FLAGS // flags: some flags
+};
+
+#endif
+
#if IRMP_SUPPORT_SAMSUNG_PROTOCOL == 1
static const PROGMEM IRMP_PARAMETER samsung_param =
@@ -1893,6 +1919,11 @@ static uint16_t irmp_tmp_address2;
static uint16_t irmp_tmp_command2; // ir command
#endif
+#if IRMP_SUPPORT_LGAIR_PROTOCOL == 1
+static uint16_t irmp_lgair_address; // ir address
+static uint16_t irmp_lgair_command; // ir command
+#endif
+
#if IRMP_SUPPORT_SAMSUNG_PROTOCOL == 1
static uint16_t irmp_tmp_id; // ir id (only SAMSUNG)
#endif
@@ -1988,6 +2019,23 @@ irmp_store_bit (uint8_t value)
}
}
+#if IRMP_SUPPORT_LGAIR_PROTOCOL == 1
+ if (irmp_param.protocol == IRMP_NEC_PROTOCOL || irmp_param.protocol == IRMP_NEC42_PROTOCOL)
+ {
+ if (irmp_bit < 8)
+ {
+ irmp_lgair_address <<= 1; // LGAIR uses MSB
+ irmp_lgair_address |= value;
+ }
+ else if (irmp_bit < 24)
+ {
+ irmp_lgair_command <<= 1; // LGAIR uses MSB
+ irmp_lgair_command |= value;
+ }
+ }
+ // NO else!
+#endif
+
#if IRMP_SUPPORT_NEC42_PROTOCOL == 1
if (irmp_param.protocol == IRMP_NEC42_PROTOCOL && irmp_bit >= 13 && irmp_bit < 26)
{
@@ -2154,7 +2202,10 @@ irmp_ISR (void)
irmp_tmp_command2 = 0;
irmp_tmp_address2 = 0;
#endif
-
+#if IRMP_SUPPORT_LGAIR_PROTOCOL == 1
+ irmp_lgair_command = 0;
+ irmp_lgair_address = 0;
+#endif
irmp_bit = 0xff;
irmp_pause_time = 1; // 1st pause: set to 1, not to 0!
#if IRMP_SUPPORT_RC5_PROTOCOL == 1
@@ -2267,7 +2318,6 @@ irmp_ISR (void)
NEC_START_BIT_PAUSE_LEN_MIN, NEC_START_BIT_PAUSE_LEN_MAX);
irmp_param_p = (IRMP_PARAMETER *) &nec_param;
#endif
-
}
else if (irmp_pulse_time >= NEC_START_BIT_PULSE_LEN_MIN && irmp_pulse_time <= NEC_START_BIT_PULSE_LEN_MAX &&
irmp_pause_time >= NEC_REPEAT_START_BIT_PAUSE_LEN_MIN && irmp_pause_time <= NEC_REPEAT_START_BIT_PAUSE_LEN_MAX)
@@ -3043,10 +3093,22 @@ irmp_ISR (void)
irmp_start_bit_detected = 1; // tricky: don't wait for another start bit...
}
#endif // IRMP_SUPPORT_JVC_PROTOCOL == 1
+#if IRMP_SUPPORT_LGAIR_PROTOCOL == 1
+ else if (irmp_param.protocol == IRMP_NEC_PROTOCOL && (irmp_bit == 28 || irmp_bit == 29)) // it was a LGAIR stop bit
+ {
+ ANALYZE_PRINTF ("Switching to LGAIR protocol, irmp_bit = %d\n", irmp_bit);
+ irmp_param.stop_bit = TRUE; // set flag
+ irmp_param.protocol = IRMP_LGAIR_PROTOCOL; // switch protocol
+ irmp_param.complete_len = irmp_bit; // patch length: 16 or 17
+ irmp_tmp_command = irmp_lgair_command; // set command: upper 8 bits are command bits
+ irmp_tmp_address = irmp_lgair_address; // lower 4 bits are address bits
+ irmp_start_bit_detected = 1; // tricky: don't wait for another start bit...
+ }
+#endif // IRMP_SUPPORT_LGAIR_PROTOCOL == 1
#if IRMP_SUPPORT_NEC42_PROTOCOL == 1
#if IRMP_SUPPORT_NEC_PROTOCOL == 1
- else if (irmp_param.protocol == IRMP_NEC42_PROTOCOL && irmp_bit == 32) // it was a NEC stop bit
+ else if (irmp_param.protocol == IRMP_NEC42_PROTOCOL && irmp_bit == 32) // it was a NEC stop bit
{
ANALYZE_PRINTF ("Switching to NEC protocol\n");
irmp_param.stop_bit = TRUE; // set flag
@@ -3060,6 +3122,17 @@ irmp_ISR (void)
irmp_tmp_command = (irmp_tmp_address2 >> 3) | (irmp_tmp_command << 10);
}
#endif // IRMP_SUPPORT_NEC_PROTOCOL == 1
+#if IRMP_SUPPORT_LGAIR_PROTOCOL == 1
+ else if (irmp_param.protocol == IRMP_NEC42_PROTOCOL && irmp_bit == 28) // it was a NEC stop bit
+ {
+ ANALYZE_PRINTF ("Switching to LGAIR protocol\n");
+ irmp_param.stop_bit = TRUE; // set flag
+ irmp_param.protocol = IRMP_LGAIR_PROTOCOL; // switch protocol
+ irmp_param.complete_len = irmp_bit; // patch length: 16 or 17
+ irmp_tmp_address = irmp_lgair_address;
+ irmp_tmp_command = irmp_lgair_command;
+ }
+#endif // IRMP_SUPPORT_LGAIR_PROTOCOL == 1
#if IRMP_SUPPORT_JVC_PROTOCOL == 1
else if (irmp_param.protocol == IRMP_NEC42_PROTOCOL && (irmp_bit == 16 || irmp_bit == 17)) // it was a JVC stop bit
{
diff --git a/irmp.h b/irmp.h
index bf53e3c..2ff7766 100644
--- a/irmp.h
+++ b/irmp.h
@@ -3,7 +3,7 @@
*
* Copyright (c) 2009-2013 Frank Meyer - frank(at)fli4l.de
*
- * $Id: irmp.h,v 1.84 2014/02/19 12:57:36 fm Exp $
+ * $Id: irmp.h,v 1.85 2014/06/05 21:00:06 fm Exp $
*
* ATMEGA88 @ 8 MHz
*
@@ -146,6 +146,12 @@
# define IRMP_SUPPORT_NEC_PROTOCOL 1
#endif
+#if IRMP_SUPPORT_LGAIR_PROTOCOL == 1 && IRMP_SUPPORT_NEC_PROTOCOL == 0
+# warning LGAIR protocol needs also NEC protocol, NEC protocol enabled
+# undef IRMP_SUPPORT_NEC_PROTOCOL
+# define IRMP_SUPPORT_NEC_PROTOCOL 1
+#endif
+
#if IRMP_SUPPORT_RCMM_PROTOCOL == 1 && F_INTERRUPTS < 20000
# warning F_INTERRUPTS too low, RCMM protocol disabled (should be at least 20000)
# undef IRMP_SUPPORT_RCMM_PROTOCOL
diff --git a/irmpconfig.h b/irmpconfig.h
index 0c8f2b3..e01b1c7 100644
--- a/irmpconfig.h
+++ b/irmpconfig.h
@@ -5,7 +5,7 @@
*
* Copyright (c) 2009-2013 Frank Meyer - frank(at)fli4l.de
*
- * $Id: irmpconfig.h,v 1.107 2014/05/30 13:09:46 fm Exp $
+ * $Id: irmpconfig.h,v 1.109 2014/06/05 21:00:57 fm Exp $
*
* ATMEGA88 @ 8 MHz
*
@@ -88,6 +88,7 @@
#define IRMP_SUPPORT_A1TVBOX_PROTOCOL 0 // A1 TV BOX >= 15000 (better 20000) ~300 bytes
#define IRMP_SUPPORT_LEGO_PROTOCOL 0 // LEGO Power RC >= 20000 ~150 bytes
#define IRMP_SUPPORT_RCMM_PROTOCOL 0 // RCMM 12,24, or 32 >= 20000 ~150 bytes
+#define IRMP_SUPPORT_LGAIR_PROTOCOL 0 // LG Air Condition >= 10000 ~300 bytes
#define IRMP_SUPPORT_RADIO1_PROTOCOL 0 // RADIO, e.g. TEVION >= 10000 ~250 bytes
/*---------------------------------------------------------------------------------------------------------------------------------------------------
diff --git a/irmpprotocols.h b/irmpprotocols.h
index d029e3e..a222be2 100644
--- a/irmpprotocols.h
+++ b/irmpprotocols.h
@@ -5,7 +5,7 @@
*
* Copyright (c) 2013 Frank Meyer - frank(at)fli4l.de
*
- * $Id: irmpprotocols.h,v 1.22 2014/05/30 12:48:54 fm Exp $
+ * $Id: irmpprotocols.h,v 1.23 2014/06/05 21:00:06 fm Exp $
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -64,9 +64,10 @@
#define IRMP_RCMM24_PROTOCOL 37 // Fujitsu-Siemens (Activy keyboard)
#define IRMP_RCMM12_PROTOCOL 38 // Fujitsu-Siemens (Activy keyboard)
#define IRMP_SPEAKER_PROTOCOL 39 // Another loudspeaker protocol, similar to Nubert
-#define IRMP_RADIO1_PROTOCOL 40 // Radio protocol (devel status), do not use it yet!
+#define IRMP_LGAIR_PROTOCOL 40
+#define IRMP_RADIO1_PROTOCOL 41 // Radio protocol (devel status), do not use it yet!
-#define IRMP_N_PROTOCOLS 40 // number of supported protocols
+#define IRMP_N_PROTOCOLS 41 // number of supported protocols
/*---------------------------------------------------------------------------------------------------------------------------------------------------
* timing constants:
@@ -122,7 +123,7 @@ typedef uint8_t PAUSE_LEN;
#define SIRCS_FLAGS 0 // flags
/*---------------------------------------------------------------------------------------------------------------------------------------------------
- * NEC & NEC42 & NEC16:
+ * NEC & NEC42 & NEC16 & LGAIR:
*---------------------------------------------------------------------------------------------------------------------------------------------------
*/
#define NEC_START_BIT_PULSE_TIME 9000.0e-6 // 9000 usec pulse
@@ -147,6 +148,12 @@ typedef uint8_t PAUSE_LEN;
#define NEC42_COMMAND_LEN 8 // read 8 command bits
#define NEC42_COMPLETE_DATA_LEN 42 // complete length (2 x 13 + 2 x 8)
+#define LGAIR_ADDRESS_OFFSET 0 // skip 0 bits
+#define LGAIR_ADDRESS_LEN 8 // read 8 address bits
+#define LGAIR_COMMAND_OFFSET 8 // skip 8 bits (8 address)
+#define LGAIR_COMMAND_LEN 16 // read 16 bits (16 command)
+#define LGAIR_COMPLETE_DATA_LEN 28 // complete length (8 address + 16 command + 4 checksum)
+
#define NEC16_ADDRESS_OFFSET 0 // skip 0 bits
#define NEC16_ADDRESS_LEN 8 // read 8 address bits
#define NEC16_COMMAND_OFFSET 8 // skip 8 bits (8 address)