In this paper, a cellular automaton model for studying the on-ramp traffic control problem of highway is proposed. The number of vehicles contained in a highway segment adjacent to the ramp merging region is used to control the on-ramp signal light. Simulation results show that the on-ramp control can improve the highway traffic, particularly when the ramp traffic is heavy. It is found that the location of detected highway segment, the length of ramp merging region and the control parameter governing the light change affect the highway and ramp traffic simultaneously. These three parameters should be coordinately designed for the improvement of both highway and ramp traffic. In general, the detected highway segment should be located at the upstream of the ramp merging region and cover it in the proper direction.