Thread: making a proper image for floppy

  1. #1
    'AlHamdulillah
    Join Date
    Feb 2003
    Posts
    790

    making a proper image for floppy

    Ok, what I need to know is : what is the proper way to make an image for a floppy. The reason being is that I am in the process of developing an operating system, and I need what is put on the floppy to be totally contiguous. I have seen programs like rawwrite, but they only write a single image or a file.

    So in the end, I am looking for a program that in of itself creats an image and can write it, or a program to create an image with the specifications I laid out. I have looked on google searching for such things of "floppy image creation" and "image creation out of files" with no luck.

    thanks guys
    there used to be something here, but not anymore

  2. #2
    PC Fixer-Upper Waldo2k2's Avatar
    Join Date
    May 2002
    Posts
    2,001
    fd has a pretty active OS dev board, go check it out, im sure there's some stuff covered in there already
    PHP and XML
    Let's talk about SAX

  3. #3
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    39,659
    > I have seen programs like rawwrite, but they only write a single image or a file.
    So write what you want to a file (using fwrite/fseek) then write that file to floppy using rawrite
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.

  4. #4
    Yes, my avatar is stolen anonytmouse's Avatar
    Join Date
    Dec 2002
    Posts
    2,544
    On NTx:
    Code:
    	hDrive = CreateFile(TEXT("\\\\.\\A:"), GENERIC_WRITE, FILE_SHARE_READ | FILE_SHARE_WRITE,
    	                    NULL, OPEN_EXISTING, FILE_FLAG_WRITE_THROUGH, NULL);
    will open A: drive for raw writing. Raw read/write samples are available here. You can write/read whole sectors (512 bytes for a floppy) only.

  5. #5
    Registered User VirtualAce's Avatar
    Join Date
    Aug 2001
    Posts
    9,607
    Hey Ev just use abswrite in DOS mode. It only works with FAT, however, so if you want NTFS you are out of luck. Besides I'm not sure NTFS can be used on floppies.

    I use to have a program that would allow you to save the bootstrap, modify it, and/or switch it with another 512 byte bootstrap as you wanted to.

    This helped me test out my new bootstrap code as I developed it. Let me look on my drive for it. All you really need to do is read the first 512 bytes from sector 0 using and absread and then write that to a binary file. If I can't find the code I'll rewrite it for you.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. open and read bmp image files
    By cnewbie85 in forum C Programming
    Replies: 2
    Last Post: 05-19-2009, 01:36 AM
  2. image analysis theory: mapping a network
    By elninio in forum C++ Programming
    Replies: 5
    Last Post: 10-30-2008, 01:23 PM
  3. HotSpot image controls (web)
    By novacain in forum C# Programming
    Replies: 0
    Last Post: 06-25-2008, 04:27 AM
  4. Loading an image in from a resource file
    By starcatcher in forum C++ Programming
    Replies: 4
    Last Post: 04-15-2008, 06:44 AM
  5. Image persistence (cue Twilight Zone theme...)
    By SMurf in forum Windows Programming
    Replies: 3
    Last Post: 04-21-2002, 10:24 PM