When the ambient light is too bright (i.e. the keyboard can be easily seen without any backlighting), keyboard backlighting is disabled. Turning off "automatically adjust keyboard brightness" in System Preferences may stop this behaviour though I wouldn't advise it as it will likely negatively impact battery life.