A tool includes a nonmagnetic tool housing; a cylindrical rotor inside the
tool housing and rotatable in response to a flow of pressurized fluid
through the tool housing; magnets mounted in the rotor; and a stator on
the exterior of the tool housing. The stator is dimensioned to cooperate
with the magnets to, upon rotation of the rotor, generate electrical
current for supply to a load.