Simple C Peg engine