Mitsubishi Electric MELSEC iQ-R C Series Programming Manual page 147

Controller module
Table of Contents

Advertisement

CCPU_UnmountMemoryCard
This function unmounts the SD memory card and USB Mass Storage Class-compliant device inserted to a C Controller
module.
Format
short CCPU_UnmountMemoryCard (short sDrive)
Argument
Argument
Name
sDrive
Target drive
Description
• This function unmounts the drive specified to the target drive (sDrive).
• The CARD RDY LED keeps flashing during the unmount processing of the SD memory card, and it turns OFF after the
unmount processing is completed.
• The USB RDY LED keeps flashing during the unmount processing of the USB Mass Storage Class-compliant device, and it
turns OFF after the unmount processing is completed.
• This function can be executed when the status of the drive specified to the target drive (sDrive) is "Inserted (mounted)".
(The status can be checked with the CCPU_GetCpuStatus function.)
• When the drive specified to the target drive (sDrive) has already been unmounted, this function ends normally without
processing.
Precautions
Design a program so that accessing files in the target drive is stopped and all files are closed before calling this function. If this
function is called while the files are open, data corruption or a file system error may occur.
Return value
Return value
Description
0 (0000H)
Normal
Other than 0
Error
For details on the error, refer to the following:
Page 225 ERROR CODE LIST
Relevant functions
• Page 119 CCPU_MountMemoryCard
• Page 101 CCPU_GetCpuStatus
Description
Specify a target drive.
(When 'Reserved' is specified, this function ends normally without processing.)
• 1: SD memory card
• 2: USB Mass Storage Class-compliant device
• Others: Reserved
3 DETAILS OF FUNCTION
3.1 C Controller Module Dedicated Functions
3
IN/OUT
IN
145

Advertisement

Table of Contents
loading

Table of Contents