Switch constructor updated
Length for wired added, some dead code deleted