I am new to programming strings and RS232. I have recently put a SNAP-SCM-ST2 module into my system to run some stepper motors. I am able to put the example in from OPTO Form 1944, nStatus = TransmitReceiveString(">SetPulseFrequency(50000)", comScmStPort1, sReturn); and was able to create a program to run the motors at set speed. Now I am trying to figure out the easiest way to be able to put in a setpoint from Pac display basic to change the frequency in the TransmitReceiveString (). Thanks, Lloyd
That’s Good. Yes I have put different variable types in place of the 50000 (interger and floats and strings). But I don’t seem to be able to get the module to work or read with the numbers.
Are you having trouble building the string that you need to send (converting an integer to a string), or is the string you are sending not working with the SCM-ST2 module?