First thing I'd try is to reboot the iPad. This can correct a lot of stuff. Hold down the menu button (has a circle) and at the same time hold down the on off button on the side of the iPad. Release them and a red slide switch will appear on the screen. Slide that switch and the iPad will reboot.
Then press the on off side button again and it will turn on and show a white apple as it starts up again.
Then try the camera again!
P.s. also make sure the camera lens is not blocked. Like putting the iPad in a case the wrong way so there is no hole for the camera.