fixing the cpp compile problems
pid stuff in