Skip to content

Commit

Permalink
Merge WLED/master into upstream-dev-multipin
Browse files Browse the repository at this point in the history
  • Loading branch information
THATDONFC committed Apr 2, 2021
2 parents 2669254 + d603a8a commit 6bdf285
Show file tree
Hide file tree
Showing 24 changed files with 2,135 additions and 2,172 deletions.
44 changes: 0 additions & 44 deletions .travis.yml.old

This file was deleted.

17 changes: 15 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,19 @@
## WLED changelog

### Development versions after 0.11.1 release
### Development versions between 0.11.1 and 0.12.0 releases

#### Build 2103300

- Version bump to 0.12.0-b5 "Hikari"
- Update to core [email protected]
- Fixed IR pin not configurable

#### Build 2103290

- Version bump to 0.12.0-b4 "Hikari"
- Experimental use of [email protected]
- Fixed RGBW mode disabled after LED settings saved
- Fixed infrared support not compiled in if IRPIN is not defined

#### Build 2103230

Expand Down Expand Up @@ -233,7 +246,7 @@
#### Build 2011153

- Fixed an ESP32 end-of-file issue
- Fixed useRGBW not read from cfg.json
- Fixed strip.isRgbw not read from cfg.json

#### Build 2011152

Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "wled",
"version": "0.12.0-b2",
"version": "0.12.0-b5",
"description": "Tools for WLED project",
"main": "tools/cdata.js",
"directories": {
Expand Down
22 changes: 11 additions & 11 deletions platformio.ini
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,7 @@ build_flags = ${common.build_flags_esp8266} -D LEDPIN=1 -D WLED_DISABLE_INFRARED

[env:esp32dev]
board = esp32dev
platform = espressif32@2.0
platform = espressif32@3.2
build_unflags = ${common.build_unflags}
build_flags = ${common.build_flags_esp32}
lib_ignore =
Expand All @@ -273,7 +273,7 @@ lib_ignore =

[env:elementv2]
board = esp32dev
platform = espressif32@2.0
platform = espressif32@3.2
build_flags = ${common.build_flags_esp32} -D LEDPIN=33 -D BTNPIN=22 -D AUDIOPIN=32
upload_speed = 460800
lib_ignore =
Expand All @@ -282,7 +282,7 @@ lib_ignore =

[env:esp32_eth]
board = esp32-poe
platform = espressif32@2.0
platform = espressif32@3.2
upload_speed = 921600
build_unflags = ${common.build_unflags}
build_flags = ${common.build_flags_esp32} -D RLYPIN=-1 -D WLED_USE_ETHERNET -D BTNPIN=-1
Expand Down Expand Up @@ -360,7 +360,7 @@ build_flags = ${common.build_flags_esp8266} -D LEDPIN=12 -D IRPIN=-1 -D RLYPIN=2

[env:soundReactive_esp32dev]
board = esp32dev
platform = espressif32@2.0
platform = espressif32@3.2
upload_speed = 921600
;upload_port = /dev/cu.SLAB_USBtoUART
;monitor_port = /dev/cu.SLAB_USBtoUART
Expand All @@ -372,7 +372,7 @@ lib_ignore =

[env:soundReactive_esp32_eth]
board = esp32-poe
platform = espressif32@2.0
platform = espressif32@3.2
upload_speed = 921600
build_unflags = ${common.build_unflags}
build_flags = ${common.build_flags_esp32} -D RLYPIN=-1 -D WLED_USE_ETHERNET -D BTNPIN=-1
Expand All @@ -382,7 +382,7 @@ lib_ignore =

[env:soundReactive_lolin_d32]
board = lolin_d32
platform = espressif32@2.0
platform = espressif32@3.2
upload_speed = 921600
build_unflags = ${common.build_unflags}
build_flags = ${common.build_flags_esp32} -D WLED_DISABLE_MQTT
Expand Down Expand Up @@ -437,7 +437,7 @@ build_flags = ${common.build_flags_esp8266} -D USE_WS2801

[env:custom32_LEDPIN_16]
board = esp32dev
platform = espressif32@2.0
platform = espressif32@3.2
build_unflags = ${common.build_unflags}
build_flags = ${common.build_flags_esp32} -D LEDPIN=16 -D RLYPIN=19
lib_ignore =
Expand All @@ -446,7 +446,7 @@ lib_ignore =

[env:custom32_APA102]
board = esp32dev
platform = espressif32@2.0
platform = espressif32@3.2
build_unflags = ${common.build_unflags}
build_flags = ${common.build_flags_esp32} -D USE_APA102
lib_ignore =
Expand All @@ -455,7 +455,7 @@ lib_ignore =

[env:custom32_TOUCHPIN_T0]
board = esp32dev
platform = espressif32@2.0
platform = espressif32@3.2
build_unflags = ${common.build_unflags}
build_flags = ${common.build_flags_esp32} -D TOUCHPIN=T0
lib_ignore =
Expand All @@ -464,7 +464,7 @@ lib_ignore =

[env:wemos_shield_esp32]
board = esp32dev
platform = espressif32@2.0
platform = espressif32@3.2
upload_port = /dev/cu.SLAB_USBtoUART
monitor_port = /dev/cu.SLAB_USBtoUART
upload_speed = 460800
Expand All @@ -481,7 +481,7 @@ build_flags = ${common.build_flags_esp32} -D LEDPIN=27 -D BTNPIN=39
lib_ignore =
ESPAsyncTCP
ESPAsyncUDP
platform = espressif32@2.0
platform = espressif32@3.2

[env:sp501e]
board = esp_wroom_02
Expand Down
4 changes: 2 additions & 2 deletions usermods/Temperature/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ default_envs = d1_mini
...
[common]
...
lib_deps_external =
lib_deps =
...
#For use SSD1306 OLED display uncomment following
U8g2@~2.27.3
Expand All @@ -55,4 +55,4 @@ lib_deps_external =
* Changed to use async, non-blocking implementation
* Do not report low temperatures that indicate an error to mqtt
* Disable plugin if temperature sensor not detected
* Report the number of seconds until the first read in the info screen instead of sensor error
* Report the number of seconds until the first read in the info screen instead of sensor error
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ default_envs = d1_mini

[env:esp32dev]
board = esp32dev
platform = espressif32@2.0
platform = espressif32@3.2
build_unflags = ${common.build_unflags}
build_flags =
${common.build_flags_esp32}
Expand Down
4 changes: 2 additions & 2 deletions wled00/FX.h
Original file line number Diff line number Diff line change
Expand Up @@ -660,7 +660,7 @@ class WS2812FX {
}

void
finalizeInit(bool supportWhite, uint16_t countPixels, bool skipFirst),
finalizeInit(uint16_t countPixels, bool skipFirst),
service(void),
blur(uint8_t),
fill(uint32_t),
Expand Down Expand Up @@ -692,6 +692,7 @@ class WS2812FX {
setPixels(CRGB* leds);

bool
isRgbw = false,
gammaCorrectBri = false,
gammaCorrectCol = true,
applyToAllSelected = true,
Expand Down Expand Up @@ -939,7 +940,6 @@ class WS2812FX {
void handle_palette(void);

bool
_useRgbw = false,
_skipFirstMode,
_triggered;

Expand Down
8 changes: 3 additions & 5 deletions wled00/FX_fcn.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -44,11 +44,9 @@
*/

//do not call this method from system context (network callback)
void WS2812FX::finalizeInit(bool supportWhite, uint16_t countPixels, bool skipFirst)
void WS2812FX::finalizeInit(uint16_t countPixels, bool skipFirst)
{
if (supportWhite == _useRgbw && countPixels == _length && _skipFirstMode == skipFirst) return;
RESET_RUNTIME;
_useRgbw = supportWhite;
_length = countPixels;
_skipFirstMode = skipFirst;

Expand Down Expand Up @@ -163,7 +161,7 @@ uint16_t WS2812FX::realPixelIndex(uint16_t i) {
void WS2812FX::setPixelColor(uint16_t i, byte r, byte g, byte b, byte w)
{
//auto calculate white channel value if enabled
if (_useRgbw) {
if (isRgbw) {
if (rgbwMode == RGBW_MODE_AUTO_BRIGHTER || (w == 0 && (rgbwMode == RGBW_MODE_DUAL || rgbwMode == RGBW_MODE_LEGACY)))
{
//white value is set to lowest RGB channel
Expand Down Expand Up @@ -278,7 +276,7 @@ void WS2812FX::show(void) {
}


if (_useRgbw) //RGBW led total output with white LEDs enabled is still 50mA, so each channel uses less
if (isRgbw) //RGBW led total output with white LEDs enabled is still 50mA, so each channel uses less
{
powerSum *= 3;
powerSum = powerSum >> 2; //same as /= 4
Expand Down
2 changes: 1 addition & 1 deletion wled00/alexa.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ void onAlexaChange(EspalexaDevice* dev)
if (espalexaDevice->getColorMode() == EspalexaColorMode::ct) //shade of white
{
uint16_t ct = espalexaDevice->getCt();
if (useRGBW)
if (strip.isRgbw)
{
switch (ct) { //these values empirically look good on RGBW
case 199: col[0]=255; col[1]=255; col[2]=255; col[3]=255; break;
Expand Down
16 changes: 7 additions & 9 deletions wled00/cfg.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ void deserializeConfig() {

JsonArray ins = hw_led["ins"];
uint8_t s = 0; //bus iterator
useRGBW = false;
strip.isRgbw = false;
busses.removeAll();
uint32_t mem = 0;
for (JsonObject elm : ins) {
Expand Down Expand Up @@ -131,13 +131,13 @@ void deserializeConfig() {
uint8_t ledType = elm["type"] | TYPE_WS2812_RGB;
bool reversed = elm["rev"];
//RGBW mode is enabled if at least one of the strips is RGBW
useRGBW = (useRGBW || BusManager::isRgbw(ledType));
strip.isRgbw = (strip.isRgbw || BusManager::isRgbw(ledType));
s++;
BusConfig bc = BusConfig(ledType, pins, start, length, colorOrder, reversed);
mem += busses.memUsage(bc);
if (mem <= MAX_LED_MEMORY) busses.add(bc);
}
strip.finalizeInit(useRGBW, ledCount, skipFirstLed);
strip.finalizeInit(ledCount, skipFirstLed);
if (hw_led["rev"]) busses.getBus(0)->reversed = true; //set 0.11 global reversed setting for first bus

// 2D Matrix Settings - BROKEN WITH MULTIPIN CHANGES
Expand All @@ -163,7 +163,7 @@ void deserializeConfig() {
//int hw_btn_ins_0_type = hw_btn_ins_0["type"]; // 0

#ifndef WLED_DISABLE_INFRARED
int hw_ir_pin = hw["ir"]["pin"]; // 4
int hw_ir_pin = hw["ir"]["pin"] | -1; // 4
if (pinManager.allocatePin(hw_ir_pin,false)) {
irPin = hw_ir_pin;
} else {
Expand Down Expand Up @@ -559,11 +559,9 @@ void serializeConfig() {
hw_btn_ins_0_macros.add(macroDoublePress);

#ifndef WLED_DISABLE_INFRARED
if (irPin>=0) {
JsonObject hw_ir = hw.createNestedObject("ir");
hw_ir["pin"] = irPin;
hw_ir[F("type"] = irEnabled; // the byte 'irEnabled' does contain the IR-Remote Type ( 0=disabled )
}
JsonObject hw_ir = hw.createNestedObject("ir");
hw_ir["pin"] = irPin;
hw_ir[F("type")] = irEnabled; // the byte 'irEnabled' does contain the IR-Remote Type ( 0=disabled )
#endif

JsonObject hw_relay = hw.createNestedObject(F("relay"));
Expand Down
6 changes: 3 additions & 3 deletions wled00/colors.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ void colorHStoRGB(uint16_t hue, byte sat, byte* rgb) //hue, sat to rgb
case 4: rgb[0]=t,rgb[1]=p,rgb[2]=255;break;
case 5: rgb[0]=255,rgb[1]=p,rgb[2]=q;
}
if (useRGBW && strip.rgbwMode == RGBW_MODE_LEGACY) colorRGBtoRGBW(col);
if (strip.isRgbw && strip.rgbwMode == RGBW_MODE_LEGACY) colorRGBtoRGBW(col);
}

void colorKtoRGB(uint16_t kelvin, byte* rgb) //white spectrum to rgb, calc
Expand Down Expand Up @@ -111,7 +111,7 @@ void colorCTtoRGB(uint16_t mired, byte* rgb) //white spectrum to rgb, bins
} else {
rgb[0]=237;rgb[1]=255;rgb[2]=239;//150
}
if (useRGBW && strip.rgbwMode == RGBW_MODE_LEGACY) colorRGBtoRGBW(col);
if (strip.isRgbw && strip.rgbwMode == RGBW_MODE_LEGACY) colorRGBtoRGBW(col);
}

#ifndef WLED_DISABLE_HUESYNC
Expand Down Expand Up @@ -169,7 +169,7 @@ void colorXYtoRGB(float x, float y, byte* rgb) //coordinates to rgb (https://www
rgb[0] = 255.0*r;
rgb[1] = 255.0*g;
rgb[2] = 255.0*b;
if (useRGBW && strip.rgbwMode == RGBW_MODE_LEGACY) colorRGBtoRGBW(col);
if (strip.isRgbw && strip.rgbwMode == RGBW_MODE_LEGACY) colorRGBtoRGBW(col);
}

void colorRGBtoXY(byte* rgb, float* xy) //rgb to coordinates (https://www.developers.meethue.com/documentation/color-conversions-rgb-xy)
Expand Down
2 changes: 1 addition & 1 deletion wled00/data/index.css
Original file line number Diff line number Diff line change
Expand Up @@ -931,6 +931,7 @@ input[type=number]::-webkit-outer-spin-button {
}

.lstI {
position: sticky;
overflow: hidden;
}

Expand All @@ -948,7 +949,6 @@ input[type=number]::-webkit-outer-spin-button {
}

.lstI.sticky, .lstI.selected {
position: sticky;
z-index: 1;
}

Expand Down
2 changes: 1 addition & 1 deletion wled00/html_other.h
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ function B(){window.history.back()}function U(){document.getElementById("uf").st
.bt{background:#333;color:#fff;font-family:Verdana,sans-serif;border:.3ch solid #333;display:inline-block;font-size:20px;margin:8px;margin-top:12px}input[type=file]{font-size:16px}body{font-family:Verdana,sans-serif;text-align:center;background:#222;color:#fff;line-height:200%}#msg{display:none}
</style></head><body><h2>WLED Software Update</h2><form method="POST"
action="/update" id="uf" enctype="multipart/form-data" onsubmit="U()">
Installed version: 0.12.0-b2<br>Download the latest binary: <a
Installed version: 0.12.0-b5<br>Download the latest binary: <a
href="https://github.com/atuline/WLED/releases" target="_blank"><img
src="https://img.shields.io/github/release/atuline/WLED.svg?style=flat-square">
</a><br><input type="file" class="bt" name="update" accept=".bin" required><br>
Expand Down
Loading

0 comments on commit 6bdf285

Please sign in to comment.