EasyManuals Logo

Panasonic FP Series User Manual

Panasonic FP Series
1345 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #216 background imageLoading...
Page #216 background image
Conversion instructions
215
Part II IEC Instructions
LD
ST
When programming with structured text, enter the following:
result_string:=DWORD_TO_STRING(input_value);
Example 2
This example illustrates how you create STRING[10] out of the data type DWORD in which the
leading part of the string '16#' is replaced by the string '0x'.
The example is programmed in LD and IL. The same POU header is used for both programming
languages.
POU header
In this example the input variables input_value of the data type DWORD and an output variable
result_string of the data type STRING[10] are declared.
Body
In carrying out the operation in question, the standard function REPLACE is attached to the
function DWORD_TO_STRING. REPLACE replaces one section of a character string with another.
In the example, the output string of DWORD_TO_STRING function is added at input IN1 of the
REPLACE function. At input IN2, the STRING constant '0x' is added as the replacement STRING.
At the L input of REPLACE, the INT constant 3 determines the length of the STRING to be
replaced. The P input determines the position at which the replacement begins. In this case it is the
INT number 1. From the variable input_value = 16#12345678, the result_string = '0x12345678'
results after undergoing the data type conversion and REPLACE function.
LD

Table of Contents

Other manuals for Panasonic FP Series

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Panasonic FP Series and is the answer not in the manual?

Panasonic FP Series Specifications

General IconGeneral
MountingDIN rail
TypePLC
Communication InterfaceRS-232, RS-485, Ethernet (depending on model)
Input Voltage100-240V AC or 24V DC (depending on model)
Output TypeRelay, Transistor
I/O PointsVaries by model
Operating Temperature0°C to 55°C
DimensionsVaries by model
WeightVaries by model

Related product manuals