Interference problems in digital inputs between VFD and Arduino

Hello,
I think I have interference / EMI problems between the connection of a VFD and an arduino. I enclose a scheme of the connection circuit.

The problem is that after a while, sometimes days, the digital inputs of the inverter are activated. This happened to me with different brands of drives (LG, Siemens, Weg, etc.)

The connection cables that I use are meshed and have a ground connection.

I want to add an RC filter to the circuit but I do not know if it is convenient and which is the best option to avoid interference.

Thank you very much for the help

Conexion Arduino-VFD.png

Are the optoisolators part of the VFD? If so there's nothing else you can do, it ought to be reliable
if the cabling is decent (twisted pair, or shielded, or both).

If the opto coupler is a separate unit, the wires on its outputs may be subject to noise pick up, and capacitance
across the output at the receiving end may help (perhaps 1nF to 10nF).