This paper describes a proof-of-concept implementation that uses a high dynamic range CMOS video camera to integrate daylight harvesting and occupancy sensing functionalities. It has been demonstrated that the proposed concept not only circumvents several drawbacks of conventional lighting control sensors, but also offers functionalities that are not currently achievable by these sensors. The prototype involves three algorithms, daylight estimation, occupancy detection and lighting control. The calibrated system directly estimates luminance from digital images of the occupied room for use in the daylight estimation algorithm. A novel occupancy detection algorithm involving color processing in YCC space has been developed. Our lighting control algorithm is based on the least squares technique. Results of a daylong pilot test show that the system i) can meet different target light-level requirements for different task areas within the field-of-view of the sensor, ii) is unaffected by direct sunlight or a direct view of a light source, iii) detects very small movements within the room, and iv) allows real-time energy monitoring and performance analysis. A discussion of the drawbacks of the current prototype is included along with the technological challenges that will be addressed in the next phase of our research.