EasyManuals Logo
Home>Mitsubishi>Controller>MELSEC-Q/L

Mitsubishi MELSEC-Q/L User Manual

Mitsubishi MELSEC-Q/L
850 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 #473 background imageLoading...
Page #473 background image
471
VAL, VALP, DVAL, DVALP
1
2
3
4
4
6
7
8
7.11 Character string processing instructions
7.11.10 VAL, VALP, DVAL, DVALP
(8) In cases where the character string designated by contains "20
H
" (space) or "30
H
" (0) between the sign and the first
numerical value other than "0", these "20
H
" and "30
H
" are ignored in the conversion into a BIN value.
Operation Error
(1) In any of the following cases, an operation error occurs, the error flag (SM0) turns ON, and an error code is stored into
SD0.
Program Example
(1) The following program reads the character string data stored from D20 to D22 as an integer, converts it to a BIN value,
and stores it at D0 when X0 is ON.
[Ladder Mode] [List Mode]
Error
code
Error details
Q00J/
Q00/
Q01
QnH QnPH QnPRH QnU LCPU
4100
The number of characters in the character string specified by is
outside the following ranges:
When VAL instruction is in use........2 to 8
When DVAL instruction is in use.....2 to 13
The number of characters in the decimal fraction portion of the
character string specified by is outside the following ranges:
When VAL instruction is in use........0 to 5
When DVAL instruction is in use.....0 to 10
The total number of characters in the character string specified by
and the number of characters in the decimal fraction part stand in a
relationship that is outside the following ranges:
Total number of characters -3
Number of characters in the decimal
fraction part
An ASCII code other than "20
H
" or "2D
H
" has been set for the sign.
An ASCII code other than "30
H
" to "39
H
" or "2E
H
" (decimal point) has
been set as a digit for one of the individual numbers.
There has been more than one decimal points set in the value.
The converted BIN value exceeds the following ranges:
When the VAL instruction is in use........-32768 to 32767
When the DVAL instruction is in use.....-2147483648 to 2147483647
4101
No "00
H
" is set within the range from the device number specified by
to the last device number of the corresponding device.
S
654 3 . 21
Ignored
12
2
Total number of digits
Number of digits
in decimal fraction
BIN data
0 000
5
4 321
Ignored
11
8
.
Sign
65
4
3
21
5 4 321
Total number of digits
Number of digits
in decimal fraction
BIN data
S1
S
S
S
Step Instruction Device

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Mitsubishi MELSEC-Q/L and is the answer not in the manual?

Mitsubishi MELSEC-Q/L Specifications

General IconGeneral
BrandMitsubishi
ModelMELSEC-Q/L
CategoryController
LanguageEnglish

Related product manuals