Did you connect the power line up to the other power line? Someone said they had issues with this quest too, but I reset my whole level/game and I got it to work fine. The relay next to the generator needs to be connected to the relay next to the switch. The switch needs to be connected to the gates (which should already be done)