Vision system is the critical component for soccer robot. During the football competition, most information perceived by robot is from vision system. Because of the variable illumination conditions, traditional image segmentation method based on color information is not satisfactory. An object recognition algorithm, which combined color image segmentation with edge detection is presented in this paper based on the color information and shape information of the object. This algorithm implement image segmentation using color information in the HSV color space obtain the pixel of the object, and use this pixel implement edge detection to recognize the object. Experiments show that this algorithm can recognize the object exactly in the different illumination conditions, satisfy the requirement of the competition.