The only way I can do it is press F5, or what ever your key is to get them to leave the gun. Look under your F1 key menu for the keyboard layout for which ever button is supposed to toggle the crew and use it.
Or get the mod that changes the commands altogether, it's what made my game playable from that aspect.
Link to the mod =
http://www.subsim.com/radioroom/showthread.php?t=163444
Use the Guncrew key like a fire hold fire, and you should be set.
OH...and yes targeting the ship with Binoc's and pressing the spacebar is an automatic man the guns and open fire. But atleased with this mod you can tell them to stop. It is best to use the command first then target the ship though. Sometimes the crew stays at the gun eventhough you have secured it, then you have to do th dive reset. Believe me I've done it more than once untill I got use to the new way of doing things. But now it is natural.
1. Man the deck gun.
2. Choose target
3. They will fire by themselves usually, so dont do it untill your sure they can hit it.
4. Secure the deck gun, when ship is obviously going down.