Fixing compilation error and remove EMC from pid