add sprinkler setting function & security functions