In order to correctly build your string, you must look in the instrument documentation if n and x are expressed as characters (i.e. "1", "2" and so on) or in their equivalent numeric code (in the example above, 49, 50 and so on - decimal basis). This is important 'cause character "1" (ASCII code 49) is different from ASCII code 1, so the string you send to the instruments may be wrong due to that basic misunderstanding.
The same for start- end end-of transmission: in the ASCII character set STX stands for Start of Trasmission (ASCII code 2), while ETX is End of Transmission (ASCII code 3).
To insert non-displayable characters into a string, you must embed special escape codes in it: look in the on line help searching for 'escape codes'.
Another hint i
s to find if it is needed a termination character for the message: most instruments use return (ASCI code 13, escape code \r), but others use their own thermination character, which is usually descripted in the instrument's documentation.
And finally: how long is the instrument expected to wait before answering? Depending on the complexity of the job performed and the characteristics of the instruments, it may take some time to react to a request (I saw from milliseconds to hundreds of msecs). You must put a delay in your program to let the instrument play its job...
Hope this helps
Roberto