Basic sensors works thanks to the interruption of a light beam, that is a photocell. These devices provide limited quality performances and may run into some technical inaccuracies although they are less expensive than the other type.
Professional systems with cameras, on the other hand, provide high quality performances thanks to the stereoscopic technology (the presence of two parallel lenses) and the softwares ability for video analysis.