Moxa V2616A-C5 [57/111] Hot swap hard disk

Moxa V2616A-C8-CT-W7E [57/111] Hot swap hard disk
V2616A Linux Programming Guide
4-8
close(fd);
return ret;
}
Hot-swap Hard Disk
A development library is provided to help you develop your applications. All of the code can be found at
/example/hotswap in the CD
Define Documentation
#define mxhtsp_close(fd) close(fd)
Description
Close the hotswap devices.
Parameters fd: the open port
Returns None
Function Documentation
int mxhtsp_check_partition_usage (const char * partition_name)
Description Get what percentage of a partition is in use.
Parameters partition_name: the name of the partition being checked. In linux, it should be
/media/diskxpx
Returns None
int mxhtsp_is_button_pressed (int fd, int btn_num)
Description Check if a button is pressed.
Parameters fd: the open port
btn_num: the button number
Returns 1: pressed
0: not pressed
-1: fail
int mxhtsp_is_disk_busy (int fd, int disk_num)
Description Check if a disk is busy.
Parameters fd: the open port
disk_num: the disk number
Returns 1: busy
0: idle
-1: fail
int mxhtsp_is_disk_plugged (int fd, int disk_num)
Description Check if a disk is plugged in.
Parameters fd: the open port
disk_num: the disk number
Returns 1: plugged
0: unplugged
-1: fail
Open the hotswap devices.
Description Check if a disk is plugged in.
Returns fd if successful
-1: fail

Содержание

Похожие устройства

Скачать