Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9084445
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T20:59:59+00:00 2026-06-16T20:59:59+00:00

I need to construct a SDHC card (FAT32) with a directory where I have

  • 0

I need to construct a SDHC card (FAT32) with a directory where I have chosen the short and long filenames independently. E.g. short filename MYDIR but long name i am a cool name. yeah. check out the awesomeness. Based on Wikipedia, there is no mandatory correlation between the two names, so my goal should be possible:

there is no compulsory algorithm for creating the 8.3 name from an LFN

— http://en.wikipedia.org/wiki/8.3_filename#Overview

I can use any necessary system to do this (windows, mac, linux, hex editor) but the easier the better. Thanks!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-16T21:00:00+00:00Added an answer on June 16, 2026 at 9:00 pm

    The short file name is automatically and compulsorily constructed from the LFN using the algorithm you mentioned. (Also detailed in the FAT32 specifications). This is done by the file-system driver (at least on Windows and Linux).You really can’t change that, unless you modify the driver which is not advisable. If you want to do this only for one directory, then you could achieve this by modifying the disk image in a hex editor being wary of not creating duplicate entries with the same name.

    Here is what I tried on Linux:

    #dd if=/dev/zero of=fatImage bs=1048576 count=256
    #mkfs.vfat -F 32 fatImage
    #mount -o loop fatImage  /mnt
    #cd /mnt
    #mkdir ThisIsALongDirectoryName
    

    The fat driver generates a short name for the directory:THISIS~1.
    You can use both names to access it.

    #cd /mnt/ThisIsALongDirectoryName
    #cd /mnt/THISIS~1
    

    Then after unmounting the partition, I opened the image in a hex editor(Okteta on KDE), searched for the SFN entry THISIS~1,
    and replaced it with MYNEWDIR. Also,each 32 byte LFN sub-entry stores a checksum of the SFN at offset 13.
    So I had to calculate and replace the checksum of THISIS~1(which is 0xA6)
    with the checksum for MYNEWDIR(which is 0x6A) in all the LFN sub-entries.After saving the modifications,I remounted the image and was able to access the directory using the old LFN and the new SFN.

    #cd /mnt/ThisIsALongDirectoryName
    #cd /mnt/MYNEWDIR
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I need to construct a long SQL request to my database, but I'm not
I know this is a long shot but I need to construct a secure
I need to construct a long string with javascript. Thats how i tried to
I have a place in my Django app where I need to construct a
I have the need to construct a LINQ To SQL statement at runtime based
I have a case where I need to construct following structure programmatically (yes I
I have two vectors of integers, like so: c(1,5,14,24) c(3,9,22,30) I need to construct
I have two source xml files and I need to construct a new xml
I have an array I need to construct with a pre-determined number of zero-value
I have a js file where I need to construct some HTML the problem

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.