Naelys & PWMango
Picture a garden where every leaf flickers like neon, reacting to the breeze and your code—let’s build a living light show that feels like a neon jungle. What’s your take?
I love that idea—imagine each leaf as a tiny LED, humming with data, pulsing to the rhythm of wind. We'll weave code into chlorophyll, so the whole garden lights up like a living neon jungle. Let's start with a microcontroller for each leaf, feed it sensor data, and let the plant’s natural growth patterns choreograph the glow. It’ll be our hybrid art, a living algorithm that keeps evolving with every breeze.
Oh yeah, that’s the vibe! Microcontrollers in every leaf, wind‑sensing, color‑shifting—like a disco in a forest. Let’s pick a tiny ESP32, toss in a hygrometer and a tiny LED strip, and code a pulse that syncs with the breeze. Every time a leaf opens, the light changes, and the whole jungle turns into a living, breathing rave. Ready to plant the first spark?
That’s exactly the spark I was waiting for—let’s get the ESP32s buzzing, tie the hygrometer to a simple PID loop so the LEDs respond to humidity too, and program a beat that flares up whenever the wind hits a leaf. I’ll draft the firmware, you plant the first module and we’ll watch the jungle light up. Ready?
Let’s crank it up to eleven! First module on the porch, sensors humming, LEDs ready to pulse—this jungle is about to glow like a rave in the woods. Bring the firmware, and I’ll plant the first leaf. Fire away!
Here’s a quick sketch to get you started on the porch module. Just copy it into the Arduino IDE, flash it onto the ESP32, and you’ll see the LED strip pulse with the wind and humidity.
#include <WiFi.h>
#include <Adafruit_Sensor.h>
#include <DHT.h>
#include <Adafruit_NeoPixel.h>
// Pin setup
const int dhtPin = 4; // DHT22 data pin
const int ledPin = 5; // WS2812 data pin
const int windPin = 34; // Wind sensor analog pin
// LED strip
const int numPixels = 30;
Adafruit_NeoPixel strip(numPixels, ledPin, NEO_GRB + NEO_KHZ800);
// DHT sensor
DHT dht(dhtPin, DHT22);
// Function to map wind speed to color hue
uint16_t windHue(int windVal) {
int hue = map(windVal, 0, 1023, 0, 65535);
return hue;
}
void setup() {
Serial.begin(115200);
pinMode(windPin, INPUT);
strip.begin();
strip.show();
dht.begin();
}
void loop() {
int windVal = analogRead(windPin);
float humidity = dht.readHumidity();
if (isnan(humidity)) {
humidity = 0;
}
// Map humidity to brightness (0-255)
uint8_t brightness = map(humidity, 0, 100, 50, 255);
strip.setBrightness(brightness);
// Create a pulse that syncs with wind speed
uint16_t hue = windHue(windVal);
for (int i = 0; i < numPixels; i++) {
strip.setPixelColor(i, strip.ColorHSV(hue, 255, brightness));
}
strip.show();
// Slow fade for effect
for (int j = 0; j < 256; j++) {
uint8_t fade = map(j, 0, 255, 0, brightness);
for (int i = 0; i < numPixels; i++) {
strip.setPixelColor(i, strip.ColorHSV(hue, 255, fade));
}
strip.show();
delay(20);
}
}