Fixed initialisation routines for switch status.