Little update.
I still not able to see logs or traces, but using a statemnt like this in the code
args.set_value("ZZCONSUMO", 60);
i'm able to check that my function is correctly triggered, since this value is correctly set.
But now, since i want also read prameters, when i use the statment
ddb_inst inst = args.get_instance();
during the simulation i get this error when the function is triggered
"You have tried to set the following values for non-existent instance 1: 20"
Where "20" is the numeber i manually insert in my input parameters during the simulation.