How to define multi Actuators for mega 2560 boards?

Hi
I try to understand how to define Actuators for mega 2560.
I need to define 32 pins to Actuators.
I have very very low skills with code.
I thought i only need to add more lines

#ifndef ACTUATOR_ONOFF_GPIO

ifdef ESP8266

define ACTUATOR_ONOFF_GPIO 15 //12 for sonoff basic relay

elif ESP32

define ACTUATOR_ONOFF_GPIO 15

else

define ACTUATOR_ONOFF_GPIO 24

define ACTUATOR_ONOFF_GPIO 25

define ACTUATOR_ONOFF_GPIO 26

define ACTUATOR_ONOFF_GPIO 27

define ACTUATOR_ONOFF_GPIO 28

define ACTUATOR_ONOFF_GPIO 29

just add it like this. or where should i do it?

Hi,

If actuatorONOFF is defined you need to leverage one of those commands:

Preferably the json ones.

HI
I have try to send this command but nothing happen.
should I delete all of this line?
will i still be discover by home assistant?

Hello,

Could you share the files that you have modified ?

okay here are a link to my own cloud server. there you have the complett project code
https://nextcloud.arnshelm.one/index.php/s/efFyFt9R7aGcda2

Hi don’t know if you have seen the link i post

I have seen it yes. I need sometime to dig into it

HI
Maybe it would be easier if you take a clean code and send me how it should look like for 16 relay to work and how the mqtt topic should be.
I had just hope for the auto detect to work on more relay then just only one