Although posted by me, John Kasunick actually wrote the following response--
I'm not sure what you want to do. Direction should be no problem, most VFDs have a forward/reverse input that changes the direction of rotation.
Using the step signal on the other hand would be complicated. Steps control position, not speed. A VFD cannot rotate the shaft a small amount (a step) at a time, and cannot be used to control position. (Actually they can, but only the most sophisticated ones can do it, and usually only as part of a complete system that is too complicated to get into here.) I am guessing that you want to control the spindle with the VFD, not one of the machine axis. In that case, I doubt that step and direction would be used.
I don't know G-code, so I don't know what codes are used for spindle control. I assume there are codes for spindle stop and start, and possibly for spindle reverse. Those could be handled by connecting the corresponding outputs of the CNC controller to the start/stop and fwd/rev inputs of the VFD. Speed is another story. If the controller has an analog output (like 0-10V) that can be set by a G-code, then that output could be connected to the VFD speed
reference input. I don't know enough about CNC & G-codes in general and the specific controller you have to be much help with your project. All I can suggest is read the manuals for your controller and VFD, and try to figure it out.
John Kasunich