GPIO.setSLED(status, onDuration, offDuration)

This method sets the status led configuration values. It is equivalent to the AT#SLED command.

The first input parameter status is a Python integer that represents the configuration of status led and can assume the following values:

0 - ALWAYS OFF

1 - ALWAYS ON

2 - AUTO

3 - BLINKING

The second input parameter onDuration is a Python integer which is the period of ON configuration of status led measured in 1/10s.

The third input parameter offDuration is a Python integer which is the period of OFF configuration of status led measured in 1/10s.

The return value is a Python integer which is -1 if an error occurred otherwise it is 1.

Example:

 

res = GPIO.setSLED(3, 10, 90)

 

sets status led configuration to blinking with 1s in ON period and 9s in OFF period, assigning the return value to res.