Generate electricity using magnet