
[Description]
Reads the work origin offset amount stored in the CNC within the
specified range.
In the CNC, a work origin offset amount is provided for each controlled
axis (the first to 32nd controlled axes). The work origin offset amount
can be read either for individual axes separately or for all axes at a
time. If there is no controlled axis expansion option, however, it is
impossible to read a work origin offset amount for additional axes.
Specify one of (1,..,amount of controlled axes) for each axis or -1
for all axes as axis number in "axis".
Specify one of following value as start/end offset number in
"s_number"/"e_number".
number Kind of work origin offset amount
---------------+--------------------------------------------
0 External work origin offset amount
1,..,6 Work origin offset amount of G54 through G59
7,..,306 Work origin offset amount of G54.1P1 through
G54.1P300
The work origin offset amount is stored in "buf.data" with signed
binary format. (The negative value is represented as 2's complement.)
The storing order is as follows.
Reading for one axis
Member Work origin offset
-----------------------+--------------------------------
buf.data[0] Start number
buf.data[1] Start number+1
: :
buf.data[M-1] End number
Reading for all axes
Member Work origin offset
-----------------------+--------------------------------
buf.data[0] The 1st axis of start number
: :
buf.data[N-1] The Nth axis of start number
: :
buf.data[31] The 32nd axis of start number
buf.data[32] The 1st axis of (start number+1)
: :
buf.data[32+(N-1)] The Nth axis of (start number+1)
: :
buf.data[63] The 32nd axis of (start number+1)
: :
buf.data[32*(M-1)] The 1st axis of end number
: :
buf.data[32+M+N-33] The Nth axis of end number
: :
buf.data[32*M-1] The 32nd axis of end number
N is the amount of axis and M is the number of offset to be
read. If the maximum controlled-axis number is lower than 32,
no data is stored to the members that correspond to axis Nos.
"maximum controlled-axis number + 1" to 32.