setSpeedFactor in animartrix
This commit is contained in:
@@ -932,7 +932,7 @@ lib_deps_V4_M =
|
||||
paulstoffregen/OneWire@ ^2.3.7 ; used for USERMOD_DALLASTEMPERATURE -> need newer release with bugfixes for -S3; still requires TEMPERATURE_PIN < 46
|
||||
olikraus/U8g2@ ^2.34.5 ; used for USERMOD_FOUR_LINE_DISPLAY -> need newer version with bugfixes for arduino-esp32 v2.0.4 (Wire inititialization)
|
||||
ElectronicCats/MPU6050 @ 0.6.0 ; used for USERMOD_MPU6050_IMU
|
||||
https://github.com/netmindz/animartrix.git#d7c1896166f13fec2917c305222a77e3b504d060
|
||||
https://github.com/netmindz/animartrix.git#65bcfc5410464fc9721dd13d11a0e29eaf7a94e5
|
||||
|
||||
build_flags_XL =
|
||||
-D USERMOD_BH1750
|
||||
|
||||
@@ -67,6 +67,8 @@ class ANIMartRIXMod:public ANIMartRIX {
|
||||
if (SEGENV.call == 0) {
|
||||
init(SEGMENT.virtualWidth(), SEGMENT.virtualHeight(), false);
|
||||
}
|
||||
float speedFactor = map(source, 0, 255, 1, 100) / 10;
|
||||
setSpeedFactor(speedFactor);
|
||||
}
|
||||
void setPixelColor(int x, int y, rgb pixel) {
|
||||
SEGMENT.setPixelColorXY(x, y, CRGB(pixel.red, pixel.green, pixel.blue));
|
||||
|
||||
Reference in New Issue
Block a user