The nonlinear Ball-beam system combine with a CCD camera is studied in this paper. The images which include Ball-beam system and a ruler are collected by CCD sensor. The image is segmented using the adaptive image binarization threshold algorithm, and then the ruler, the ball position and the pointer position are extracted from the image. The ruler is scaled and the pointer position is also calculated. Finally, the value of pointer position is input into Ball-beam system as an expected ball balance position. A Fuzzy self-tuning PID controller and a BP neural network PID controller are designed for ball balance stable control. After experimental, the Ball-beam balance control in any position can be fulfilled using both of algorithms.