Mitsubishi Electric MELIPC MI5000 Series Programming Manual page 55

Vxworks
Hide thumbs Also See for MELIPC MI5000 Series:
Table of Contents

Advertisement

CCPU_ReadDevice
Reads data from the internal user devices and internal system devices of a MELIPC.
Format
short CCPU_ReadDevice(short sDevType, unsigned long ulDevNo, unsigned long ulSize, unsigned short* pusDataBuf,
unsigned long ulBufSize)
Argument
Argument
Name
sDevType
Device type
ulDevNo
Start device number
ulSize
Data size
pusDataBuf
Data storage destination
ulBufSize
Data storage destination size
Description
• This function reads data in a device after one specified to the device type (sDevType) and the start device number
(ulDevNo) for the size specified to the data size (ulSize), and stores it in the data storage destination (pusDataBuf).
• When "0" was specified for the data size (ulSize), a specification size error occurs.
Precautions
Note that the size of data storage destination (ulBufSize) should be equal to or bigger than the data size (ulSize).
Return value
Return value
0(0000H)
-210(FF2EH)
-253(FF03H)
-254(FF02H)
-255(FF01H)
-264(FEF8H)
-28158(9202H)
For details on error codes, refer to the following section.
Page 116 Function error codes
Relevant function
Page 79 CCPU_WriteDevice
Description
Specify the device type.
Page 8 Device type
Specify the start device number.
(Only multiples of 16 can be specified for bit devices.)
Specify the read data size in word units.
Specify the storage destination of read data.
Specify the data storage destination size in word units.
Description
Normal
Read area size error
Device number specification error
Device type specification error
Size specification error
Pointer error
WDT error
3 DETAILS OF FUNCTIONS
3.1 C Controller Module Dedicated Functions
3
IN/OUT
IN
IN
IN
OUT
IN
53

Advertisement

Table of Contents
loading

Table of Contents