Electromagnetic continuous-wave generation using switch lines