The main purpose of wearable energy harvesting devices is to replace the chemical battery and supply enough power for portable devices. Therefore, this paper derives the function expression of harvested energy via frequency ratio (excitation frequency/natural frequency) and external resistance, aiming to optimize running conditions directly in practical matters. It proposes that when energy harvesting devices work at direct force excitation the optimal condition is the frequency ratio equal to one. But the optimal excitation frequency is related to damping at base excitation, When the value of the damping ratio is less than 0.258, there is a local peak output power. Conversely, the larger excitation frequency is the larger output power is. The optimal external resistance is related with back EFM constant of the electromagnetic transducer at both cases. In the end, some experiment was conducted to study the relationship between output and some parameters.