A method for operating a lighting system for a motor vehicle, the lighting system comprising lighting apparatus having a processing module configured to receive, process and send signals from a data bus of the motor vehicle, a light-emitting diode (LED) unit configured to emit light of adjustable brightness and prescribed color locus, wherein the LED unit has a microcontroller and a plurality of LEDs, wherein the microcontroller and the LEDs are surrounded by a package of the LED unit, and wherein the LED unit comprises a temperature sensor configured to measure a present temperature value on the LED unit and to communicate bidirectionally with the processing module, the method comprising:
- actuating the temperature sensor by the processing module to ascertain a present temperature value on the LED unit,
- receiving measurement signals of the temperature sensor,
- ascertaining a present temperature value on the LED unit based on the received measurement signals of the temperature sensor, and
- controlling the function of the motor vehicle based on the ascertained temperature value on the LED unit.