ADD TLC59208F documentation (#338)

This commit is contained in:
Levente Tamas 2019-10-14 12:38:20 +03:00 committed by Otto Winter
parent 4884282ba0
commit ac28efde9c
9 changed files with 126 additions and 0 deletions

View File

@ -45,5 +45,6 @@ See Also
- :doc:`/components/output/ledc`
- :doc:`/components/output/esp8266_pwm`
- :doc:`/components/output/pca9685`
- :doc:`/components/output/tlc59208f`
- :apiref:`cwww/cww_light_output.h`
- :ghedit:`Edit`

View File

@ -55,6 +55,7 @@ See Also
- :doc:`/components/output/ledc`
- :doc:`/components/output/esp8266_pwm`
- :doc:`/components/output/pca9685`
- :doc:`/components/output/tlc59208f`
- :doc:`/components/output/my9231`
- :apiref:`monochromatic/monochromatic_light_output.h`
- :ghedit:`Edit`

View File

@ -60,6 +60,7 @@ See Also
- :doc:`/components/output/ledc`
- :doc:`/components/output/esp8266_pwm`
- :doc:`/components/output/pca9685`
- :doc:`/components/output/tlc59208f`
- :doc:`/components/output/my9231`
- :doc:`/components/output/sm16716`
- :apiref:`rgb/rgb_light_output.h`

View File

@ -40,6 +40,7 @@ See Also
- :doc:`/components/output/ledc`
- :doc:`/components/output/esp8266_pwm`
- :doc:`/components/output/pca9685`
- :doc:`/components/output/tlc59208f`
- :doc:`/components/output/my9231`
- :doc:`/components/output/sm16716`
- :apiref:`rgbw/rgb_light_output.h`

View File

@ -51,6 +51,7 @@ See Also
- :doc:`/components/output/ledc`
- :doc:`/components/output/esp8266_pwm`
- :doc:`/components/output/pca9685`
- :doc:`/components/output/tlc59208f`
- :doc:`/components/output/my9231`
- :doc:`/components/output/sm16716`
- :apiref:`rgbww/rgbww_light_output.h`

Binary file not shown.

After

Width:  |  Height:  |  Size: 45 KiB

View File

@ -0,0 +1,120 @@
TLC59208F
=========
.. seo::
:description: Instructions for setting up TLC59208F LED PWM drivers.
:image: tlc59208f.jpg
:keywords: TLC59208F
.. _tlc59208f-component:
Component
---------
The TLC59208F component represents a Texas Instruments TLC59208F 8-bit PWM driver
(`datasheet <http://www.ti.com/lit/gpn/tlc59208f>`__,
`hw example <https://faboplatform.github.io/ArduinoDocs/03.I2C%20Brick/211_brick_i2c_7seg/>`__) in ESPHome. It
uses :ref:`I²C Bus <i2c>` for communication.
To use the channels of this components, you first need to setup the
global ``tlc59208f`` chip and specify its address and id, and then define the
:ref:`individual output channels <tlc59208f-output>`.
.. code-block:: yaml
# Minimalistic configuration entry, single chip, single output
tlc59208f:
address: 0x10
id: tlc59208f_1
# Individual outputs
output:
- platform: tlc59208f
tlc59208f_id: 'tlc59208f_1'
channel: 0
Configuration variables:
************************
- **address** (*Optional*, int): The I²C address of the driver.
Defaults to ``0x20``.
- **id** (*Optional*, :ref:`config-id`): The id to use for
this tlc59208f component. Use this if you have multiple TLC59208Fs connected at the same time
.. _tlc59208f-output:
PWM Output
----------
The TLC59208F output component exposes a TLC59208F PWM channel of a global
:ref:`TLC59208F chip <tlc59208f-component>` as a float
output.
.. figure:: images/tlc59208f-full.jpg
:align: center
:width: 75.0%
Sample application of a TLC59208F 8-Channel PWM Driver.
.. code-block:: yaml
# Complete example configuration entry for 3 drivers and 4 outputs
# Maximum 64 drivers with 8 outputs each
tlc59208f:
- address: 0x20
id: tlc59208f_1
- address: 0x22
id: tlc59208f_2
- address: 0x24
id: tlc59208f_3
# Individual outputs
output:
- platform: tlc59208f
id: 'tlc59208f_1_ch0'
channel: 0
tlc59208f_id: 'tlc59208f_1'
- platform: tlc59208f
id: 'tlc59208f_1_ch4'
channel: 4
tlc59208f_id: 'tlc59208f_1'
- platform: tlc59208f
id: 'tlc59208f_2_ch2'
channel: 2
tlc59208f_id: 'tlc59208f_2'
- platform: tlc59208f
id: 'tlc59208f_3_ch7'
channel: 7
tlc59208f_id: 'tlc59208f_3'
# Sample use as a RGB light
light:
- platform: rgb
name: "Sample RGB light"
red: tlc59208f_1_ch0
green: tlc59208f_1_ch4
blue: tlc59208f_2_ch7
Configuration variables:
************************
- **id** (**Required**, :ref:`config-id`): The id to use for this output component.
- **channel** (**Required**, int): Choose the channel of the TLC59208F for
this output component. Must be in range from 0 to 7.
- **tlc59208f_id** (*Optional*, :ref:`config-id`): Manually specify the ID of the
:ref:`TLC59208F chip <tlc59208f-component>`.
Use this if you have multiple TLC59208Fs you want to use at the same time.
- All other options from :ref:`Output <config-output>`.
See Also
--------
- :doc:`/components/output/index`
- :doc:`/components/output/esp8266_pwm`
- :doc:`/components/output/ledc`
- :doc:`/components/light/monochromatic`
- :doc:`/components/light/rgb`
- :doc:`/components/fan/speed`
- :doc:`/components/power_supply`
- :apiref:`tlc59208f/tlc59208f_output.h`
- :ghedit:`Edit`

BIN
images/tlc59208f.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.3 KiB

View File

@ -180,6 +180,7 @@ Output Components
GPIO Output, components/output/gpio, pin.svg
ESP32 LEDC, components/output/ledc, pwm.png
PCA9685, components/output/pca9685, pca9685.jpg
TLC59208F, components/output/tlc59208f, tlc59208f.jpg
MY9231/MY9291, components/output/my9231, my9231.svg
SM16716, components/output/sm16716, sm16716.svg
Custom Output, components/output/custom, language-cpp.svg