TotalLUNs

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

TotalLUNs

490 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by danhauck on Wed Feb 13 06:25:43 MST 2013
Hi, has anybody tested the TotalLUNs functionality for the usb-stack? When I`m defining it to 3 there is only the scsi inquiry, request sense, ... for lun 0. Lun 1 and 2 is ignored.

Does anybody knows whats going wrong?

Regards

Daniel
Labels (1)
0 Kudos
1 Reply

479 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by danhauck on Wed Mar 06 02:14:24 MST 2013
Hi all,

I solved the problem. Windows prohibits Multiple LUNs if theres no serialnumber in the usb descriptor

So I changed the .SerialNumStrIndex in the Descriptors.c to 0x04 and added

uint8_t SerialNoString[] =
{
  USB_STRING_LEN(12),
  DTYPE_String,
  WBVAL('U'),
  WBVAL('C'),
  WBVAL('R'),
  WBVAL(' '),
  WBVAL('0'),
  WBVAL('0'),
  WBVAL('0'),
  WBVAL('0'),
  WBVAL('0'),
  WBVAL('0'),
  WBVAL('0'),
  WBVAL('1'),
};
USB_Descriptor_String_t *SerialNoStringPtr = (USB_Descriptor_String_t*)SerialNoString;


and added in function CALLBACK_USB_GetDescriptor in case DTYPE_String the case 0x04

Address = SerialNoStringPtr;
Size    = pgm_read_byte(&SerialNoStringPtr->Header.Size);
break;

Regards

Daniel


0 Kudos