A Cornwall-based writer went from working in a "mind-numbing" electronics factory to writing an award-winning comedy show.