Submarines also have batteries to supply electrical power. Electrical equipment is often run off the batteries and power from the diesel engine or nuclear reactor is used to charge the batteries. In cases of emergency, the batteries may be the only source of electrical power to run the submarine.