implemented brightness control