1710
‐
PT060PNE
Rev.
0
Page
52
of
57
6.2.1
Calculation of the checksum
The
two
ASCII
characters
which
identify
the
checksum
must
be
calculated
in
the
following
way:
1.
Calcolate
the
XO
R
binary
of
all
the
characters
from
the
1°
to
the
12°
included
in
the
case
of
strings
of
16
characters
(ID485
=
0)
or
to
the
14°
included
in
the
case
of
strings
of
18
characters
(ID485
>
0).
2.
Separate
the
XOR
values
obtained
into
a
high
area
(first
4
bit)
and
a
low
area
(last
4
bit)
3.
Code
the
high
area
according
to
the
ASCII
hex
table,
which
will
become
the
character
written
in
position
[CHK
1]
(13°
character
in
the
case
of
a
string
of
16
characters,
15°
in
the
case
of
a
string
of
18
characters).
For
example
the
binary
value
5
(0101)
will
become
character
<5>
(Hex
35),
or
the
binary
value
B
(1011)
will
become
character
capital
<B>
(Hex
42).
4.
Code
the
lower
area
according
to
the
ASCII
hex
table,
which
will
become
the
character
written
in
position
[CHK
2]
(14°
character
in
the
case
of
a
string
of
16
characters,
16°
in
the
case
of
a
string
of
18
characters).
(see
previous
example)
6.3
String format in bi-directional mode
The
length
of
the
string
differs
according
to
the
ID485
parameter
value.
6.3.1
Weight request command
<STX>[<ID485H><ID485L>]<CMD><CHK1><CHK2><CR>
CMD
=
<P>
(Hex
50)
weight
command
request
ID485
>
0
(lunghezza
7
caratteri)
1°
character
[STX]
(Hex
02)
Start
of
text
2°
character
[ID485
H]
from
<0>
(Hex
30)
to
<9>
(Hex
39)
to
indicate
the
tens
of
the
set
ID485
value
3°
character
[ID485
L]
from
<0>
(Hex
30)
to
<9>
(Hex
39)
to
indicate
the
units
of
the
set
ID485
value
4°
character
[CMD]
P
(Hex
50)
5°
character
[CHK
1]
from
<0>
(Hex
30)
to
<9>
(Hex
39)
or
from
<A>
(Hex
41)
to
<F>
(Hex
46)
to
indicate
the
higher
part
of
the
checksum
6°
character
[CHK
2]
from
<0>
(Hex
30)
to
<9>
(Hex
39)
or
from
<A>
(Hex
41)
to
<F>
(Hex
46)
to
indicate
the
lower
part
of
the
checksum
7°
character
<CR>
(Hex
0D)
carriage
return
<STX><CMD><CHK1><CHK2><CR>
CMD
=
<P>
(Hex
50)
weight
command
request
ID485
>
0
(
5 characters length
)
1°
character
[STX]
(Hex
02)
Start
of
text
2°
character
[CMD]
P
(Hex
50)
3°
character
[CHK
1]
from
<0>
(Hex
30)
to
<9>
(Hex
39)
or
from
<A>
(Hex
41)
to
<F>
(Hex
46)
to
indicate
the
higher
part
of
the
checksum
4°
character
[CHK
2]
from
<0>
(Hex
30)
to
<9>
(Hex
39)
or
from
<A>
(Hex
41)
to
<F>
(Hex
46)
to
indicate
the
lower
part
of
the
checksum
5°
character
<CR>
(Hex
0D)
carriage
return
The
format
of
the
answer
frame
is
the
same
than
in
continuous
modality.