add condition for lamp