Converts carnitine to trimethylamine and malic semialdehyde. Acts on both enantiomers. (R)-carnitine + H(+) + NADH + O2 = (3R)-3-hydroxy-4-oxobutanoate + H2O + NAD(+) + trimethylamine (R)-carnitine + H(+) + NADPH + O2 = (3R)-3-hydroxy-4-oxobutanoate + H2O + NADP(+) + trimethylamine Binds 1 2Fe-2S cluster. Inhibited by EDTA. Amine and polyamine metabolism; carnitine metabolism. Composed of an oxygenase subunit and a reductase subunit. Belongs to the PDR/VanB family. CntB subfamily.