Feedback control of limit cycles: a switching control strategy based on nonsmooth bifurcation theory