There is a sensor which tells the controller whether you hae the 540 shaft or the 1000 shaft installed. If the sensor is bad and the controller thinks the 540 shaft is installed, the computer will limit engine rpm to prevent overspeeding the pto. Sounds like your sensor is bad. The worst thing is that the sensor is inside the rear pto housing. The housing needs to be removed to repair it. Item #4 in diagram is it.