Ó²ÅÌÊý¾Ý»Ö¸´µ¼º½
RAIDÊý¾Ý»Ö¸´µ¼º½
 | ÍøÕ¾Ê×Ò³ | Êý¾Ý»Ö¸´×ÊÁÏ | Êý¾Ý»Ö¸´Èí¼þ | ×ÉѯÁôÑÔ | Êý¾Ý»Ö¸´²©¿Í | Êý¾Ý»Ö¸´ÂÛ̳ | 
Êý¾Ý»Ö¸´Èí¼þÏÂÔØ
Êý¾Ý»Ö¸´·þÎñ Êý¾Ý»Ö¸´ Êý¾Ý»Ö¸´±¨¼Û Êý¾Ý»Ö¸´Åàѵ Êý¾Ý»Ö¸´ÊµÑéÊÒ Êý¾Ý»Ö¸´Ñо¿³É¹û Êý¾Ý»Ö¸´·þÎñÁªÏµ·½Ê½
ÄúÏÖÔÚµÄλÖ㺠±±ÑÇÊý¾Ý»Ö¸´¼¼ÊõÕ¾ >> Êý¾Ý»Ö¸´×ÊÁÏ >> Ïà¹Ø±à³Ì×ÊÁÏ >> ÎÄÕÂÕýÎÄ
¹ØÓÚINT13H EXT²Ù×÷µÄ C Ô´³ÌÐò    ÈÈ     ¡ï¡ï¡ï ¡¾×ÖÌ壺С ´ó¡¿
¹ØÓÚINT13H EXT²Ù×÷µÄ C Ô´³ÌÐò
×÷Õߣºddcopy    ÎÄÕÂÀ´Ô´£º±¾Õ¾³ÉÔ±Ô­´´    µã»÷Êý£º    ¸üÐÂʱ¼ä£º2004-04-20

¹ØÓÚINT13H EXTµÄÊý¾Ý½á¹¹¼°²Ù×÷¼û£º
http://zli.webspace4free.biz/page5.html

/**
 * Ó²Å̲Ù×÷£º"¶Á"²Ù×÷(0x42)£¬"д"²Ù×÷(0x43),\n 
 * "cmd" must be Diskread(0x42) or Diskwrite(0x43).
 * @return >=0: ³É¹¦,¶ÁдµÄÊý¾Ý¿éÊý;
 * @return -1: ʧ°Ü.
 */
short _diskop (unsigned char drv, unsigned char cmd,
     unsigned char * buffer, unsigned long startlow, unsigned short copyblks)
{
 /* ´ÅÅÌ´æÈ¡Êý¾Ý°ü½á¹¹ */
 struct disk_address_packet {
  unsigned char size_of_packet;
  unsigned char reserved;
  unsigned short number_of_blocks_to_transfer;
  unsigned short transfer_buffer_offset;
  unsigned short transfer_buffer_segment;
  unsigned long starting_absolute_block_low;
  unsigned long starting_absolute_block_high;
 };
 struct disk_address_packet dap;
 unsigned char av;

 unsigned char * pt = (unsigned char *) &dap;

 dap.size_of_packet = sizeof (dap);
 dap.reserved = 0;
 dap.number_of_blocks_to_transfer = copyblks;
 dap.transfer_buffer_offset = FP_OFF(buffer);
 dap.transfer_buffer_segment = FP_SEG(buffer);
 dap.starting_absolute_block_low = startlow;
 dap.starting_absolute_block_high = 0; /* ºöÂÔ¸ßλ */

 asm {
  push ds
  push si
  mov ah, cmd
  mov dl, drv
  lds  si, DWORD PTR pt
  int  13h
  pop si
  pop ds
  mov av, ah
  jc  error
 }
 return (dap.number_of_blocks_to_transfer);

error:
 ErrorNum = av;
 return (-1);
}

ÎÄÕ¼È룺²Ëµ¶    ÔðÈα༭£ºa 
  • ÉÏһƪÎÄÕ£º

  • ÏÂһƪÎÄÕ£º
  • ¡¾·¢±íÆÀÂÛ¡¿¡¾¼ÓÈëÊղء¿¡¾¸æËߺÃÓÑ¡¿¡¾´òÓ¡´ËÎÄ¡¿¡¾¹Ø±Õ´°¿Ú¡¿
    ÍøÓÑÆÀÂÛ£º£¨Ö»ÏÔʾ×îÐÂ10Ìõ¡£ÆÀÂÛÄÚÈÝÖ»´ú±íÍøÓѹ۵㣬Óë±¾Õ¾Á¢³¡Î޹أ¡£©
    ¹ØÓÚÎÒÃÇ | RAIDÊý¾Ý»Ö¸´ | ÓÑÇéÁ´½Ó | RSSÉú³É | XMLÉú³É | ÎÄÕÂHTMLµØͼ | ÏÂÔØHTMLµØͼ

    È«¹úͳһ¿Í·þµç»°:4006-505-808
    ×ܲ¿µç»°£º010-82488636 ÓÊÏä:ycf@frombyte.com
    ¹«Ë¾µØÖ·£º±±¾©Êк£µíÇøÓÀ·á»ùµØ·á»ÛÖз7ºÅвÄÁÏ´´Òµ´óÏÃB×ù205ÊÒ
    ¾©ICP±¸05011939
    .cë _y