Using Buttons to Remotely Control WLED

I have spent a fair amount of time looking for a project that someone has already done that I can use as a template for what I want to do. I have not found one yet. I will have 3 ESP32’s running WLED. I would like to use one of them, to support push buttons and the illumination for the push buttons. So, for example, WLED on the first ESP32 would watch for activity on push-button 1, and if pressed (momentary type switch) it would cause the LED for that switch to be turned on. Simultaneously, I would like WLED to send commands over the local network to a 2nd ESP32 running WLED that would turn on a string of analog LED’s, using an external MOSFET or solid state relay. This 2nd ESP32/WLED instance would control 3 separate strips of analog LED’s using WLED’s PWM option for dimming. So that first ESP32 would host a total of 4 push buttons, each with it’s own LED in the button, that would light up when pressed. That part is not too difficult, but would still like to see some schematics showing how the LED’s would be driven with the GPIO pins (e.g., would they need a transistor to drive the LED or can the GPIO pin on the ESP32 drive the LED directly). The part I am having trouble finding a solution for, is the remote control of the analog LED strips attached to separate ESP32’s.

I believe that what I want to do is within WLED’s capabilities, but I lack the software expertise to know for sure. The thoughts that I had so far, was to set up button 1 to control a specific LED output as on/off to drive button 1’s LED illumination and toggle it from OFF to ON, or from ON to OFF - will that work? If so, then I believe I would then try using the Sync option and set up groups, one for each button/LED combo, and then setup the 2nd ESP32 with the same groups. So when button 1 is pressed on the first ESP32, it would light the LED on the GPIO pin I selected on that ESP32, then sync would communicate to the 2nd ESP32, and light up a string of analog LED’s driven by the MOSFET or SSR (Solid State Relay) connected to the associated GPIO pin on the 2nd ESP32 for that same sync group. The 3rd ESP32 running WLED would be in a separate sync group for button 4 on the first ESP32.

Will this work? I have seen some information on various sites, that seems to indicate that a single ESP32 handling all this may not be a good idea. Mainly, since I may run out of GPIO pins for the buttons and the 4 analog strips I need to control, but there may be other reasons why a single controller would not be advised. But also, I have seen that a single controller setup will likely require some special programming and/or API commands. The multiple controller setup, to me, seems to fit my situation the best, as I am setting this all up for kitchen accent lighting. So my hopes are that WLED can support the buttons on the first ESP32, each with its own button LED, sync’d via sync group to 2nd and 3rd ESP32 running analog LED’s. Due to power runs, and the way the strips are spread out, with access between some cabinets being difficult, the multiple controller setup would be easier.

Button 1, ESP32 #1, Button LED #1, Sync to ESP32 #2, Analog LED strip 1 on GPIO 7

Button 2, ESP32 #1, Button LED #2, Sync to ESP32 #2, Analog LED strip 2 on GPIO 8

Button 3, ESP32 #1, Button LED #3, Sync to ESP32 #2, Analog LED strip 3 on GPIO 9

Button 4, ESP32 #1, Button LED #4, Sync to ESP32 #3, Analog LED strip 4 on GPIO 7

Will this work? If it would be better on a single controller, please let me know why, and also how I would accomplish this. My concern is that this may need special code or API commands to accomplish both the LED indicators and lighting up the analog strips. I have also seen where the remote ESP32 uses RGB DDP, and/or virtual LED’s, but I don’t know if analog LED setups are supported with that option. I am comfortable with hardware and electronic components, but my experience with software code and API’s is limited.

Thank you for any guidance you can provide.