update the delay function.
format led driver code.