EasyManua.ls Logo

Mitsubishi MELFA CR1D - Page 295

Mitsubishi MELFA CR1D
458 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
Loading...
4MELFA-BASIC IV
Detailed explanation of Robot Status Variable 4-282
M_In/M_Inb/M_Inw
[Function]
Returns the value of the input signal.
M_In : Returns a bit.
M_Inb : Returns a byte (8 bits).
M_Inw : Returns a word (16 bits).
[Format]
[Terminology]
<Numeric Variable> Specifies the numerical variable to assign.
<Equation> Enter the input signal number. 0 to 32767 (Theoretical value)
0 to 255 : Standard remote inputs (Normally 32 points. 0 to 31)
900 to 907 : Hand input.
2000 to 5071 : Input signal of PROFIBUS.
6000 to 8047 : Remote input for CC-Link.
[Reference Program]
1 M1=M_In(0) ' M1 will contain the value of the input signal 0 (1 or 0).
2 M2=M_Inb(0) ' M2 will contain the 8-bit information starting from input signal 0.
3 M3=M_Inb(3) AND &H7 ' M3 will contain the 3-bit information starting from input signal 3.
4 M4=M_Inw(5) ' M4 will contain the 16-bit information starting from input signal 5.
[Explanation]
(1) Returns the status of the input signal.
(2) M_Inb and M_Inw will return 8- or 16-bit information starting from the specified number.
(3) Although the signal number can be as large as 32767, only the signal numbers with corresponding hard-
ware will return a valid value. Value for a signal number without corresponding hardware is set as unde-
fined.
(4) This variable only reads the data.
Example) <Numeric Variable>=M_In(<Equation>)
Example) <Numeric Variable>=M_Inb(<Equation>)
Example) <Numeric Variable>=M_Inw(<Equation>)

Table of Contents

Related product manuals