A method of mechanical-to-electrical energy conversion utilizes a mechanical spring in combination with a rapid-action variable inductance magnetic flux switch to convert a spring-loaded mechanical energy into a change in magnetic flux captured by an electrical coil element within the magnetic flux switch. The change in coil inductance and magnetic flux induces a current to flow through the electrical coil in the form of a a pulse of electrical energy that may be stored. The electrical coil is coupled to the mechanical spring so that each time the spring is released, the coil moves with respect to a magnetic core and a change in flux is created. The application of an external mechanical force (such as human locomotion) functions to compress and subsequently “unlock” the mechanical switch, allowing for the electrical energy associated with the application of aperiodic forces to be harvested.