Fixed transistor switching issues