EasyManua.ls Logo

Sutter Instrument MPC-325 Series - Page 48

Sutter Instrument MPC-325 Series
71 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
46
MPC-325 SERIES OPERATION MANUAL REV. 3.20F (20200303)
14. Move Interruption: A command should be sent to the controller only after the task of any
previous command is complete (i.e., the task-completion terminator (CR) is returned). One
exception is the “Interrupt Move” (^C) command, which can be issued while a command-
initiated move is still in progress.
15. Extracting the MPC-200 Firmware Version Number: The firmware version number
returned by the ‘K’ command is encoded in BCD (Binary Coded Decimal) in two bytes,
with minor version byte first, followed by major version byte, each of which contains two
digits , the first of which is in the upper nibble and the next in the lower nibble. For
example, if the complete version is 3.15, then the bytes at offsets 1 and 2 will show (in
hexadecimal) as 0x15 0x03 (ret[1] and ret[2] as shown in the following code snippets). The
following code shows how to extract and convert the 4 BCD digits into usable forms for
later comparison without altering the original command return data (written in C/C++
and is easily portable to Python, Java, C#, MATLAB script, etc.).
Minor version number as an int (e.g., 15):
// “ret” is the array of bytes containing
// the ‘K’ command’s return data
unsigned char verbyte; // temp work byte
verbyte = ret[1]; // get minor ver. digits
// get 1’s digit & then get & add 10’s digit
int minver = (verbyte & 0x0F) +
((verbyte >>4 & 0x0F) * 10);
Major version number as an int (e.g., 3):
verbyte = ret[2]; // get major ver. digits
int majver = (verbyte & 0x0F) +
((verbyte >>4 & 0x0F) * 10);
Complete (thousands) version as an int (e.g., 315):
int majminver = majver * 100 + minver;
Complete version as a floating-point number (e.g., 3.15):
float version = majminver * .01;
16. ‘S’ Command’s Streaming Return Data for Current Position: The Straight-Line Move (‘S’)
command has two modes of operation:
a. a CR is returned when the target position has been reached (F’ (Off) command
before the ‘S’ command sequence), or
b. streaming positional data is returned while movement is occurring, and then a CR
once movement is complete (‘O’ (On) command before the ‘S’ command sequence).
Positional data is streamed at every 1 micron of movement, and the rate (data per second)
depends on the ‘S’ command speed level used. Each positional data block streamed
consists of 12 bytes:
1 The 1
st
three bytes each contains FF hexadecimal (255 decimal) as a data block
signature,
2 the next 3 contains positional data for the X axis,
3 the penultimate is for Y, and
4 last for Z.
All positional data are in microsteps. Each 3-byte position needs to be converted into 4-
byte blocks by prepending a byte containing 0, so that the resulting data (now 4 bytes)
can be treated programmatically as an unsigned 32-bit “long” (C/C++) or “U32”
(LabVIEW) data type. All positional data streamed is in Little-Endian bit/byte order

Table of Contents

Related product manuals