improve off and on methods
Merge pull request #321 from ArcBees/jd_off

improve off and on methods