![background image](http://html2.mh-extra.com/html/keithley/2657a/2657a_reference-manual_4007750405.webp)
Section 7: TSP command reference
Model 2657A High Power System SourceMeter® Instrument Reference Manual
7-92
2657A-901-01 Rev. B/December 2012
format.byteorder
This attribute sets the binary byte order for the data that is printed using the
printnumber()
and
printbuffer()
functions.
Type
TSP-Link accessible
Affected by
Where saved
Default value
Attribute (RW)
Yes
Instrument reset
Recall setup
Not saved
1 (format.LITTLEENDIAN)
Usage
order
= format.byteorder
format.byteorder =
order
order
Byte order value as follows:
•
Most significant byte first:
0
,
format.NORMAL
,
format.NETWORK
, or
format.BIGENDIAN
•
Least significant byte first:
1
,
format.SWAPPED
or
format.LITTLEENDIAN
Details
This attribute selects the byte order in which data is written when you are printing data values with the
printnumber()
and
printbuffer()
functions. The byte order attribute is only used with the
format.SREAL
,
format.REAL
,
format.REAL32
, and
format.REAL64
data formats.
format.NORMAL
,
format.BIGENDIAN
, and
format.NETWORK
select the same byte order.
format.SWAPPED
and
format.LITTLEENDIAN
select the same byte order. Selecting which to use is a matter of preference.
Select the
format.SWAPPED
or
format.LITTLEENDIAN
byte order when sending data to a computer with a
Microsoft Windows operating system.
Example
x = 1.23
format.data = format.REAL32
format.byteorder = format.LITTLEENDIAN
printnumber(x)
format.byteorder = format.BIGENDIAN
printnumber(x)
Output depends on the terminal program
you use, but will look something like:
#0¤p??
#0??p¤
Also see
(on page 7-93)
Содержание 2657A
Страница 3: ......