Just for the hell of it, try programming in MDI m3 s500. Does the same thing happen? Then, see if there is any difference using M40, M41 or M42, these are the m codes (usually) for gear change or motor high / low range.
Does the machine have a gearbox? if so, maybe a keep relay needs to be set. the keep relays should be documented by the OEM. Usually the OEM (Mori) has to write the PMC to operate the gear change, using these keep relays to set the option installed on the machine. There is sometimes a selector shaft operated by an air or hydraulic cylinder and monitored for f/w or back position by switches, each giving an input for its status to the PMC input table.
If you have a hard copy of the PMC, have a scoot through looking for M3, M4 and M5 you may find the keep relay that way. (K002.5 for example)
Final thought, have you got the spindle speed parameters set correctly i.e. Minimum speed and Maximum speed ?