We discuss the dynamics of an amplitude modulation atomic force microscope in different environments such as water and air. Experiments, analytical expressions, and numerical simulations show that the resonance curves depend on the excitation method used to drive the cantilever, either mechanical or magnetic. This dependence is magnified for small force constants and quality factors, i.e., below 1 N / m and 10, respectively. We show that the equation for the observable, the cantilever deflection, depends on the excitation method. Under mechanical excitation, the deflection involves the base and tip displacements, while in magnetic excitation, the cantilever deflection and tip displacement coincide.