medium-chain fatty acid-CoA ligase activity [GO_0031956] - Virtual Fly Brain