]> vault307.fbx.one Git - micorpython_ir.git/blobdiff - RECEIVER.md
micropython_ir projects
[micorpython_ir.git] / RECEIVER.md
index d6998f1cb25c1acd077f369576148ef12d2237d3..13ce77a24339cb1557c1e9aa5c011fe953fe7bd4 100644 (file)
@@ -15,9 +15,20 @@ driver design ensures operation regardless of sense.
 In my testing a 38KHz demodulator worked with 36KHz and 40KHz remotes, but this
 is obviously neither guaranteed nor optimal.
 
+The TSOP4838 can run from 3.3V or 5V supplies. The former should be used on
+non-5V compliant hosts such as ESP32 and Raspberry Pi Pico and is fine on 5V
+compliant hosts too.
+
 The pin used to connect the decoder chip to the target is arbitrary. The test
-program assumes pin X3 on the Pyboard, pin 23 on ESP32 and pin 13 on ESP8266.
-On the WeMos D1 Mini the equivalent pin is D7.
+program `acquire.py` uses the following pins by default:
+
+| Host    | Pin | Notes |
+|:-------:|:---:|:-----:|
+| Pyboard | X3  |  |
+| ESP32   | 23  |  |
+| ESP8266 | 13  |  |
+| D1 Mini | D7  | WeMos name for pin 13. |
+| Pico    | 16  |  |
 
 A remote using the NEC protocol is [this one](https://www.adafruit.com/products/389).
 
@@ -130,9 +141,9 @@ Class variables:
  1. These are constants defining the NEC repeat code and the error codes sent
  to the error function. They are discussed in [section 4](./RECEIVER.md#4-errors).
 
-#### NEC classes
+#### NEC classes (includes Samsung)
 
-`NEC_8`, `NEC_16`
+`NEC_8`, `NEC_16`, `SAMSUNG`
 
 Typical invocation:
 ```python
@@ -146,6 +157,13 @@ The `NEC_8` class enables error checking for remotes that return an 8 bit
 address: the complement is checked and the address returned as an 8-bit value.
 A 16-bit address will result in an error.
 
+The `SAMSUNG` class returns 16 bit address and data values. The remote sample
+tested did not issue repeat codes - if a button is held down it simply repeated
+the original value. In common with other NEC classes the callback receives a
+value of 0 in the `ctrl` arg.
+
+Thanks are due to J.E.Tannenbaum for information about the Samsung protocol.
+
 #### Sony classes
 
 `SONY_12`, `SONY_15`, `SONY_20`