Barrier coverage is an important issue aiming at finding a set of sensors from a given wireless sensor network for detecting the illegal crossing of a boundary. A large number of algorithms have been proposed for prolonging the network lifetime. However, most of them assumed that each sensor is battery powered and the Boolean Sensing Model (BSM) is applied. Sensors powered by battery have limited lifetime while the BSM is difficult to reflect the physical features of sensing. This paper proposes a barrier coverage mechanism, called MSQ, which considers the solar-powered sensors and allows the battery to be recharged for maintaining the perpetual lifetime of sensor networks. However, two challenges should be overcome. First, the schedule should take into account the state switching due to limited energy. Second, the cooperation between neighboring sensors should be considered since the Probabilistic Sensing Model (PSM) is applied. The evaluation of surveillance quality supported by the cooperative sensing should be further considered. Performance evaluations depict that the proposed mechanism improves the performance of existing studies in terms of surveillance quality and stability.