Read and write specific parameter „x“ (78h), N 140, Example 2: change measuring unit to inches – Baumer N 140 User Manual
Page 13: Example 2: write new delay time
N 140
www.baumer.com
13
4.3.4. Read / write parameter measuring unit, command „i“ (69h)
The command is to read or write the measuring unit in mm or inches.
Data = 0 (30h) = mm
Data = 1 (31h) = inch
Example 1: Read parameter (parameter = mm)
SOH
Adr
Cmd
EOT
CRC
Transmission
01h
20h
69h
04h
5E
SOH
Adr
Cmd
Data
EOT
CRC
Response
01h
20h
69h
30h
04h
D0h
Example 2: Change measuring unit to inches
SOH
Adr
Cmd
Data
EOT
CRC
Transmission
01h
20h
69h
31h
04h
D2
SOH
Adr
Cmd
Data
EOT
CRC
Response
01h
20h
69h
31h
04h
D2
Example 3: Write mm as measuring unit into all N 140 by broadcast command (identifier/address=99)
SOH
Adr
Cmd
Data
EOT
CRC
Transmission
01h
83h
69h
30h
04h
CDh
Response
Not confirmed
Important: Parameters are entered in mm and converted into inches by the SPA when displaying the position
values.
4.3.5. Read and write specific parameter „x“ (78h)
The specific parameter „x“ comprises several sub-parameters enabling alteration of originally permanent
parameters to adapt them to new circumstances. At present, the following sub-parameter is available:
D (44h) = minimized delay time of serial interface
Sub parameter: Delay time „D“ (44h)
This parameter defines the minimum delay time (timeout) between the last bit received and the first bit of the
response transmitted. Delay time is in steps of 0.1 ms within the range from 00.0...60.0 ms. Default is 1.0 ms.
Example 1: Read current delay time
SOH Adr Cmd Sub EOT CRC
Transmission
01h 20h 78h 44h 04h 7Ch
SOH Adr Cmd Sub
Delay time = 4.5
EOT CRC
Response
01h 20h 78h 44h 30h 30h 34h 35h
04h BBh
Example 2: Write new delay time
SOH Adr Cmd Sub
Delay time = 15.0
EOT CRC
Transmission
01h 20h 78h 44h 30h 31h 35h 30h
04h BDh
SOH Adr Cmd Sub
Delay time = 15.0
EOT CRC
Response
01h 20h 78h 44h 30h 31h 35h 30h
04h BDh
Please note that the true delay time might be extended. It depends on the required processing time as well as
on internal software cycles. The tolerance is approx. 8 ms.