Protection from habituation by lateral inhibition