Aiming at the problem of frequent manual picking up ping-pong balls during training, an automatic system for picking up ball is designed. The system combines single-chip computer technology, sensor technology and embedded technology to achieve the recognition, tracking, and picking up of ping-pong balls. The OpenMV visual module is used to identify and track table tennis balls, and the roller structure is used to pick up balls. The μC/OS-III embedded real-time operating system is transplanted to STM32 to achieve multitask management and task scheduling of the system, which improves the performance and stability of the system at a certain extent. The practice of the automatic ping-pong ball collection system shows that the rate of success picking up ball is high and its stability is good, which can reduce the burden of manual ball picking at a certain extent.