A method of controlling a window shade, based on sunlight, said window shade comprising a roller shutter apron, a photovoltaic generator, a battery storing electrical energy supplied by said photovoltaic generator and supplying electrical energy to said roller shutter apron, and a control module, said method comprising the steps of:
- electrically isolating said photovoltaic generator from said battery;
- taking a reading of short circuit current of the isolated photovoltaic generator;
- determining a numerical value being based on at least one reading of short circuit current and corresponding to the reading of the short circuit current;
- comparing said numerical value determined with at least one reference threshold value;
- and
- controlling said roller shutter apron, when said numerical value determined corresponds to a value range limited by the at least one reference threshold value so as to thereon confer a configuration corresponding to said value range.