[Freedos-user] usb in freedos

2012-02-21 Thread sasi maran


Dear all
       
               I have installed free dos in the hard disk  --
Keep Your Developer Skills Current with LearnDevNow!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-d2d___
Freedos-user mailing list
Freedos-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freedos-user


[Freedos-user] Fw: usb in freedos

2012-02-21 Thread sasi maran
Dear all
    
                  i have installed free dos in my computer. how to use flash 
drive for the file transfer
        i have installed  driver for the usb  it scan for usb but displays usb 
not found
     can any one help to solve this problem

 with regards 
  MARAN
                                                                                
                      
  
                                                                  


  
                                                                   

--
Keep Your Developer Skills Current with LearnDevNow!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-d2d___
Freedos-user mailing list
Freedos-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freedos-user


Re: [Freedos-user] Fw: usb in freedos

2012-02-21 Thread Bernd Blaauw
Op 21-2-2012 17:41, sasi maran schreef:
 Dear all
 i have installed free dos in my computer. how to use flash drive for the
 file transfer
 i have installed driver for the usb it scan for usb but displays usb not
 found
 can any one help to solve this problem

Most USB flash drives come pre-formatted with a FAT32 filesystem 
already. Likewise, most computers have the possibility to use BIOS USB 
Legacy emulation to have keyboards, mice and drives connected to USB 
working before loading modern operating systems such as Windows and Linux.

In other words, insert your USB flash disk, start up FreeDOS and you 
should be able to see the USB flash disk as BIOS lists it as a kind of 
harddisk, and thus FreeDOS (actually the kernel bootup file named 
kernel.sys) will have given it a driveletter. This might be C: if your 
normal harddisk doesn't contain any recognised filesystems.

If your harddisk is C: however, your USB drive might have become D: or so.

Reach the USB drive by typing in:
D: (followed by enter)

See contents:
DIR D:

Copy a file from harddisk or floppy to USB:
COPY A:\SOMEFILE.TXT D:\USBFILE.TXT

USB-drivers are only needed in specific circumstances: whenever your 
system doesn't list attached drives automatically (which is often the 
case when using add-on PCI/PCIe usb-controllers).

So try the following:
- without loading any drivers (as DOS relies on computer/BIOS anyway)
- with FreeDOS's USB drivers, based on [ http://bretjohnson.us/ ]

If that fails, a demo version of a commercial set of USB drivers can be 
tried from: [ http://www.georgpotthast.de/usb/ ], maybe that will work 
for you.

Bernd

--
Keep Your Developer Skills Current with LearnDevNow!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-d2d
___
Freedos-user mailing list
Freedos-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freedos-user


Re: [Freedos-user] writing a loadable block driver for 4k-sector drive (Questions)

2012-02-21 Thread Bertho Grandpied
Hi, FreeDOS-devel !

Upon C. Masloch's harsh request\\kind invitation, I'm joining 
Freedos-devel now and shall continue this question here that started in 
Freedos-user. Apologies to anybody this change of venue may inconvenience.

 --

On Mon, 20 Feb 2012 11:15:00 PST BretJ bretjohn@***.com wrote in Freedos-user 
:

 Bertho Grandpied wrote:
 Therefore my first interrogation is, what set of device header attributes
 - and associated functions, including IOCTL codes - must be present /at a
 minimum/ for letting DOS access the disk properly ?

Bret wrote :
 FWIW, this is what is implemented in my USBDRIVE:
 
 01h - Media Check
 02h - Build BIOS Parameter Block
 04h - Read
 08h - Write
 09h - Write with Verification
 0Dh - Device Open
 0Eh - Device Close
 0Fh - Removable Media
 11h - Generic IOCTL DOS 3
 13h - Generic IOCTL DOS 4+
 17h - Get Logical Device
 18h - Set Logical Device
 19h - IOCTL Check DOS 5+
 
 USBDRIVE is installed as a TSR instead of in CONFIG.SYS, so
 doesn't need or
 support Function 00h (Initialize).  I don't know if all
 of these are
 actually needed or not, but they are supported. 
 
(list of IOctls scrubbed for brevity, cf. Bret's original msg)

Well, OK Bret, but this doesn't tell what the minimum set would be (as you 
conceded). Are the IOCTLs and functions 17,18,19h required ? Since support for 
these features has to be marked by corresponding bits #7  6 of the driver 
attribute, it is conceivable that a driver might not provide it. Unless of 
course DOS refuses to use (old?) drivers which do not advertise these 
functions. Someone knows ?

 Bertho Grandpied wrote:
 - Using a loadable driver for the block device implies DOS won't use /its/
 internal buffers, so I don't have to care about DOS own buffers sizing,
 right ?
 
 Wrong. 

Of course you're right, I wasn't thinking out well.

 The reason you're even doing this in the first
 place is because DOS
 _will_ use its internal buffers.  This wouldn't be
 necessary otherwise. 
 IOW, you should still check the max sector size in the DOS
 List of Lists
 before you install yourself to make sure it's 512 bytes, and
 should refuse
 to install yourself if it's already 4096. 

Uh, here I'm confused, not following any more, please elaborate your point. 
Assuming we've loaded  USBASPI.SYS [which provides ector access to the external 
disk using SCSI commands], my hypothetical driver wishes to support one or 
more FAT partitions on that external disk. Whether or not DOS has already 
increased its buffer size up to 4K before my driver loads from CONFIG, the 
driver had better be loaded or else DOS won't know to access the partition(s). 
IOW the role of the driver is not /just/ to inform DOS that it might have to 
adjust its internal buffer size, as you seem to be writing above; rather the 
main role of the loaded driveris to augment DOS by allowing it to well, 
read/write files and clusters and sectors to the disk, a feat DOS by itself 
would be incapable of (neither USB nor SCSI/ASPI existed when DOS was designed, 
so I guess we might pardon it).

 What am I missing of your above point ?


 The only way
 around this I know
 of is to install as an IFS (Installable File System /
 Network) driver,
 similar to how MSCDEX (and its clones) work.

 
 Bertho Grandpied wrote:
 - Besides, should I consider using the non IBM format bit in driver
 attribute ? From whatever docs I saw is unclear what non IBM changes
 exactly in how DOS uses the driver, 
 
 None of the devices I've ever seen use the IBM format -- it
 changes the BPB. 
 Probably a dangerous road to go down.

Do you mean to say non-IBM ? UIAM again, the IBM (should be called MS) 
formats are the usual FAT disks. IOW non-IBM is when attribute bit 13 = 1. 
See a difference in driver function 2 in Ralf Brown's list : FAT sectors aren't 
transmitted, does it mean a non IBM disk may be non-FAT ?
Again, I'm curious if anybody has experience with this unusual case.

WHATEVER... Interestingly Novac's DI1000DD.SYS driver has attribute = 68C2 (or 
68C0 for disks under 32 Megs). Yes, it's non IBM whatever that means!


Regards


-- 
Czerno

--
Keep Your Developer Skills Current with LearnDevNow!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-d2d
___
Freedos-user mailing list
Freedos-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freedos-user


Re: [Freedos-user] writing a loadable block driver for 4k-sector drive (Questions)

2012-02-21 Thread Bret Johnson
 Unless of course DOS refuses to use (old?) drivers which do not
 advertise these functions. Someone knows ?

I find that a minimalistic approach almost always leads to problems and 
compatibility issues.  Even if you think a function/feature/API may not be 
needed, it's still better to put it in.

 IOW, you should still check the max sector size in the DOS List of
 Lists before you install yourself to make sure it's 512 bytes, and
 should refuse to install yourself if it's already 4096.

 Uh, here I'm confused, not following any more, please elaborate your
 point. Assuming we've loaded  USBASPI.SYS [which provides ector
 access to the external disk using SCSI commands], my hypothetical
 driver wishes to support one or more FAT partitions on that external
 disk.

It depends on exactly what your driver does.  It sounds like you're intending 
to essentially make a replacement for DI1000DD.SYS.  If so, you're going to 
need to coordinate your installation with DD1000DD.SYS, in case the user 
tries to install both at the same time.  Whether you abort your installation or 
not depends on whether DI1000DD.SYS is already installed, whether it supports 
4k sectors or not (I have no idea), whether there are any disks with 4k sectors 
actually plugged in or not, and whether or not the DOS kernel natively supports 
4k sectors.  You don't want to install if DI1000D.SYS is already installed and 
can already handle everything.  I (and you, apparently) are assuming that 
USBASPI.SYS supports 4k sectors, but I would actually verify that before I went 
very far.

If, however, you're going to do what Christian (and maybe Eric?) was thinking 
and essentially install a shim between DI1000DD.SYS and the kernel, things 
are a little different.  Such a shim could work even on non-ASPI disks (such as 
those provided by Georg's or my USB drivers), but should abort installation if 
the kernel natively supports 4k sectors.  In this scenario, there's also the 
potential issue of hot-pluggable disks (which are supported by my USB drivers, 
but I don't think are supported by USBASPI or Georg).

 Do you mean to say non-IBM ? UIAM again, the IBM (should be
 called MS) formats are the usual FAT disks. IOW non-IBM is when
 attribute bit 13 = 1.

No, it's the other way around.  If bit 13 is set, it means IBM Format, but 
that doesn't equate to MS.  Here's a quote from an old book I have, DOS 
Programmer's Reference, 2nd Edition, by Que, which gives the practical 
explanation of what the bit means, specifically regarding function 2, Build 
BPB:

A one sector buffer is passed to this routine.  If the non-IBM format bit in 
the device attribute word is set to zero, the buffer contains the first sector 
of the FAT and should not be changed.  If the bit is set, the buffer can be 
used as a scratch area in which to build the BPB.

It doesn't have anything to do with non-FAT.

Bottom line for safety in the driver: ignore the setting of the bit, assume you 
can't change the buffer, and assume the buffer does not contain the first 
sector of the FAT.


--
Virtualization  Cloud Management Using Capacity Planning
Cloud computing makes use of virtualization - but cloud computing 
also focuses on allowing computing to be delivered as a service.
http://www.accelacomm.com/jaw/sfnl/114/51521223/
___
Freedos-user mailing list
Freedos-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/freedos-user