If you are having troubles with the camera on your Hubsan X4 H502E Quadcopter you can replace it with a new one. The 720P HD Camera that comes on the new Hubsan X4 H502E GPS is of fair quality but not the greatest.
Follow these instructions in the video below to install a replacement HD camera in your quadcopter. While he is installing the cam on a very similar H502s version.
The Hubsan X4 H502E and H502S Quadcopters are two of the best buys you can currently get in a low priced drone. They are well worth modding and upgrading. But, with all drones they do incur some damage from time to time.
If you have crashed your H502E and damaged it you can take it apart and replace it with this factory replacement Hubsan X4 H502E camera here.