ok I was close on the Gcode but not quite. Where I had
M6 S<s>
M3
Has now been changed to
M3 S<s>
G4 P7
It turns the spindle on with the M3 and to the correct RPM if I just give it M3 S15000, but it doesn’t wait for it to ramp up at all. My VFD is set to 5 seconds ramp up so the 7 gives it a little extra lol