Hi Osika, my apologies for the slow response. I see you are not using the functions to enable/disable the mechanical recoil, so that is not the problem. Your switch setup is fine too, that is the same way that I use cannon and machine gun on a 3 position switch too.
So that's good, but I am not sure what the problem could be. The fact that it does work sometimes tells me that the TCB is not broken, and it makes me suspect a mechanical issue with the recoil unit itself. The main thing to check is the little limit switch, possibly it is loose, or maybe it is not being closed completely at the end of the cycle. Also check your soldering job to make sure there are no loose wires, the wires on those units are very thin and flimsy.
This may not help anything but for the moment it is all I can think of. I don't have a unit on hand to test right now, but again I don't think it is a firmware issue because your recoil does work occasionally.