makebootfat creates the USB drive successfully, but when I try to boot, it just hangs with a flashing cursor.

I've tried countless makebootfat parameters, such as -m mbrfat.bin, -F, -Z, -D, -P, -EI've tried different boot sector images, from a FAT32 HDD with Win98, from a FAT12 Floppy Disk, from a FAT32 USB Key that can boot (created by HP's tool), but nothing works I've tried different command.com files, and even tried HP's system files.

Note that most boot sectors are 512bytes. But HP's built-in FAT32 boot sector is 1500Bytes!

When I try writing that 1500Byte sector using makebootfat, it only write 512bytes.When I try writing that 1500Byte sector using HDHacker, the drive shows corrupted files and folders.

So my question is, how does HP write the 1500Byte boot sector? Is it writing an MBR with a partition table?

On a freshly formatted FAT32 volume "default value" of bytes on 2nd sector are (Absolute offsets from begiinning of first sector, hex):at 0x0200:

52 52 61 41

at 0x03E4:

72 72 61 41

at 0x03E8:

FF FF FF FF

at 0x03EC usually:

02 00 00 00

at 0x03FE:

55 AA

Thus:1st sector contains both "CODE" (fixed) and "DATA" (variable)2nd sector contains both "CODE" (fixed) and "DATA" (variable) but of which the "standard values" are known3rd sector (as saind not necessarily the actual sector at offset 0x0400) contains only "CODE" (fixed)

Please note that this option (FAT32 on a 512 Mb USB key) did NOT make a bootable volume. I suspect that there is something not right in the FAT32 identifier (hex 0b) and structure. By running (in Qemu) sys.com, it changed (between other things) the identifier to LBA mappped (hex 0c) and the volume booted.

I guess that SYS.COM fixed, besides the Partition ID, the missing 2nd and 3rd sector.

Since the 2nd and 3rd sector are "fixed" (at least for a freshly formatted system they should work allright if copied to the stick with dsfo/dsfi (or HDhacker).

So basically I need to write more than 512bytes, which is why HP's utility writes 1.5KB of sectors.

Yep.

The question is, can makebootfat v1.4 (latest) do this? or would it need to be updated?

It seems to me that your experience, summed up to the one I did at the time (and it was ALREADY version 1.4) already produced an answer: it seems like NOT. makebootfat seems like a dead project, unfortunately. We would need a programmer to take the Source Code and fix/integrate/update it.

to try ADDING the missing/wrong 2nd and "3rd" (beware of the placement of this last one as 12th sector for Windows 2K/XP/2003 and probably for Vista/2008/Windows7) as hinted above AFTER having used makebootfat to generate the 1st sector (and the other filesystem structure).

If it works, you can then script it and use dsfo/dsfi to automate the process.