Skip to main content
BParh.1
Senior III
October 21, 2021
Question

Can we get USB name like how OS does from FAT File System Middleware?

So I have a USB stick with name like shown in this snapshot Windows OS: "SanDisk Cruzer Blade USB Device". Get we get similar name from FAT file system middleware? Which API used?

0693W00000FDGqiQAH.png

This topic has been closed for replies.

2 replies

Uwe Bonnes
Chief
October 21, 2021

The name comes from an USB descriptor. Grep the source for that string, change it to your liking, recompile and reflash amd you get the new string if all was done the right way.

Tesla DeLorean
Guru
October 21, 2021

You'll need to dig into the USB Host Stack, and where it's getting the Descriptor(s) pull the name, serial number or whatever data is sent.

16-bit unicode /wide-chars as I recall, so will need extraction to a global variable

Tips, Buy me a coffee, or three.. PayPal Venmo (See Profile) Up vote any posts that you find helpful, it shows what's working..