As indicated in the following documentation on FPRINTF:
fprintf (Instrument Control Toolbox)
The calling syntax:
fprintf(obj,'format','cmd')
writes the string 'cmd' to the instrument connected to obj using the format specified by 'format'.
FPRINTF may also be called as in:
fprintf(obj,'cmd')
In this syntax, FPRINTF writes the string 'cmd' directly to the instrument connected to obj.
However, when I execute the following command
fprintf(g2,'FT1<\r\n');
FPRINTF does not transmit my control sequence '\r\n'. Instead it converts then directly to double values. The '\r' sequence is only evaluated to 13 if it is in the format string, but not if it is in a string passed to the format string.
Best Answer