TCS34725: Difference between revisions

From NURDspace
No edit summary
No edit summary
 
(3 intermediate revisions by the same user not shown)
Line 15: Line 15:


The plan is to connect it to a Wemos D1 mini ESP8266 board.
The plan is to connect it to a Wemos D1 mini ESP8266 board.
Looks exactly like the Adafruit one:
https://www.adafruit.com/product/1334
ESP-HOME yaml:
<pre>
esphome:
  name: lichtsensor
esp8266:
  board: d1_mini
# Enable logging
logger:
# Enable Home Assistant API
api:
  password: ""
ota:
  password: ""
wifi:
  ssid: "NurdSpace"
  password: "geheimgeheimgeheim"
  # Enable fallback hotspot (captive portal) in case wifi connection fails
  ap:
    ssid: "Lichtsensor Fallback Hotspot"
    password: "pFFK0GrHcwZB"
captive_portal:
i2c:
  sda: D1
  scl: D2
sensor:
  - platform: tcs34725
    red_channel:
      name: "TCS34725 Red Channel"
    green_channel:
      name: "TCS34725 Green Channel"
    blue_channel:
      name: "TCS34725 Blue Channel"
    clear_channel:
      name: "TCS34725 Clear Channel"
    illuminance:
      name: "TCS34725 Illuminance"
    color_temperature:
      name: "TCS34725 Color Temperature"
    gain: 16x
    integration_time: 120ms
    glass_attenuation_factor: 1.0
    address: 0x29
    update_interval: 10s
switch:
  - platform: gpio
    pin: D3
    name: "Lampje"
</pre>

Latest revision as of 21:10, 15 January 2022

TCS34725
TCS34725.jpg
Participants
Skills Arduino, Esphome
Status In progress
Niche Other
Purpose Occupational Therapy
Tool No
Location
Cost
Tool category Surveillance

TCS34725 Property "Tool Image" (as page type) with input value "File:{{{Picture}}}" contains invalid characters or is incomplete and therefore can cause unexpected results during a query or annotation process. {{{Picture}}} {{#if:No | [[Tool Owner::{{{ProjectParticipants}}} | }} {{#if:No | [[Tool Cost::{{{Cost}}} | }}

The TCS34725 is a light (and color) sensor. This sensor will be connected to ESP-home / hass to provide an indication of the illumination level at NurdSpace

This thing has an I2C interface and is already supported by ESP-home: https://esphome.io/components/sensor/tcs34725.html

The plan is to connect it to a Wemos D1 mini ESP8266 board.

Looks exactly like the Adafruit one: https://www.adafruit.com/product/1334

ESP-HOME yaml:

esphome:
  name: lichtsensor

esp8266:
  board: d1_mini

# Enable logging
logger:

# Enable Home Assistant API
api:
  password: ""

ota:
  password: ""

wifi:
  ssid: "NurdSpace"
  password: "geheimgeheimgeheim"

  # Enable fallback hotspot (captive portal) in case wifi connection fails
  ap:
    ssid: "Lichtsensor Fallback Hotspot"
    password: "pFFK0GrHcwZB"

captive_portal:

i2c:
  sda: D1
  scl: D2

sensor:
  - platform: tcs34725
    red_channel:
      name: "TCS34725 Red Channel"
    green_channel:
      name: "TCS34725 Green Channel"
    blue_channel:
      name: "TCS34725 Blue Channel"
    clear_channel:
      name: "TCS34725 Clear Channel"
    illuminance:
      name: "TCS34725 Illuminance"
    color_temperature:
      name: "TCS34725 Color Temperature"
    gain: 16x
    integration_time: 120ms
    glass_attenuation_factor: 1.0
    address: 0x29
    update_interval: 10s

switch:
  - platform: gpio
    pin: D3
    name: "Lampje"