If compass calibration is required, an alert will be shown in your capture app as well as in the DJI Go app. Some drones also cannot take off when compass calibration is required.
This error may simply be due to the drone sitting above iron objects (e.g. reinforced concrete or pipes in the ground). If your drone allows you to, try taking off. Often, increasing your drone's distance to the ground will get rid of the compass calibration error. If this does not work, try moving your drone away from metal objects, reinforced concrete and electric equipment. If the error persists, switch to the DJI Go app, then follow the DJI Go app instructions to calibrate the compass.