Skip to content

Instantly share code, notes, and snippets.

View triphoppingman's full-sized avatar

bruce mcdonald triphoppingman

  • Tusked Crescent
  • United States
View GitHub Profile
@triphoppingman
triphoppingman / ColorTempRGBWLight.h
Created November 22, 2019 05:17
ESPHOME custom light that provides color temperature support to RGBW lights. This differs from the original (see link in the code) by mapping the RGBW from the
#include "esphome.h"
// Constants
const float maxMired = 500;
const float minMired = 153;
const float scale1 = 1.25f;
const float red_offset = 0.4f;
const float green_offset = 0.8f;
/**