Got to the modules tab on the RH panel.
You can turn systems on and of there (filled in and empty check boxes). When you have an AFM installed, you can also select a 3rd mode. It looks like a diagonal line in the box. In this state, the AFM will repair damage to the module.
Note : Weapons, Shields, Thrusters, the AFM itself and discovery scanners cannot be repaired.