Catalyzes the transfer of CoA to carnitine, generating the initial carnitinyl-CoA needed for the CaiB reaction cycle. Also has activity toward crotonobetaine and gamma-butyrobetaine. 4-(trimethylamino)butanoate + ATP + CoA = AMP + diphosphate + gamma-butyrobetainyl-CoA ATP + CoA + crotonobetaine = AMP + crotonobetainyl-CoA + diphosphate (R)-carnitine + ATP + CoA = (R)-carnitinyl-CoA + AMP + diphosphate Amine and polyamine metabolism; carnitine metabolism. Belongs to the ATP-dependent AMP-binding enzyme family.