keil_examples/USBMem/mscuser.c
/*
 *  MSC SCSI Read Capacity Callback
 *    Parameters:      None (global variables)
 *    Return Value:    None
 */
MSC SCSI Read Capacity Callback
Parameters:      None (global variables)
Return Value:    None
MSC SCSI Read Capacity Callback Parameters : None ( global variables ) Return Value : None
void MSC_ReadCapacity (void) {
  if (!DataInFormat()) return;
  BulkBuf[ 0] = ((MSC_BlockCount - 1) >> 24) & 0xFF;
  BulkBuf[ 1] = ((MSC_BlockCount - 1) >> 16) & 0xFF;
  BulkBuf[ 2] = ((MSC_BlockCount - 1) >>  8) & 0xFF;
  BulkBuf[ 3] = ((MSC_BlockCount - 1) >>  0) & 0xFF;
  BulkBuf[ 4] = (MSC_BlockSize >> 24) & 0xFF;
  BulkBuf[ 5] = (MSC_BlockSize >> 16) & 0xFF;
  BulkBuf[ 6] = (MSC_BlockSize >>  8) & 0xFF;
  BulkBuf[ 7] = (MSC_BlockSize >>  0) & 0xFF;
  BulkLen = 8;
  DataInTransfer();
}
void MSC_ReadCapacity ( void ) { if ( ! DataInFormat ( ) ) return ; BulkBuf [ 0 ] = ( ( MSC_BlockCount - 1 ) >> 24 ) & 0xFF ; BulkBuf [ 1 ] = ( ( MSC_BlockCount - 1 ) >> 16 ) & 0xFF ; BulkBuf [ 2 ] = ( ( MSC_BlockCount - 1 ) >> 8 ) & 0xFF ; BulkBuf [ 3 ] = ( ( MSC_BlockCount - 1 ) >> 0 ) & 0xFF ; BulkBuf [ 4 ] = ( MSC_BlockSize >> 24 ) & 0xFF ; BulkBuf [ 5 ] = ( MSC_BlockSize >> 16 ) & 0xFF ; BulkBuf [ 6 ] = ( MSC_BlockSize >> 8 ) & 0xFF ; BulkBuf [ 7 ] = ( MSC_BlockSize >> 0 ) & 0xFF ; BulkLen = 8 ; DataInTransfer ( ) ; }
MSC SCSI Read Capacity Callback
    Parameters:      None (global variables)
    Return Value:    None
MSC SCSI Read Capacity Callback Parameters : None ( global variables ) Return Value : None
/* Last Logical Block */ /* Block Length */