[Coco] Megaread problems

Dave Philipsen dave at davebiz.com
Mon Mar 27 17:33:10 EDT 2017


I'm not 100% sure on this but I *think* it may even be advantageous for 
you to do a megaread </dd/test-file where the test-file is at least one 
megabyte in length because then instead of just doing sequential reads 
of sectors it forces the file manager to read through a file which could 
involve a little more computational effort as well as time for the 
device to search different sectors. It might yield more of a 'real 
world' result.

I'm pretty sure you'd see a difference between the raw and the file on a 
floppy or hard drive.

Dave


On 3/27/2017 3:39 PM, Tim Fadden wrote:.

Dave

> Well, at one time I am sure I knew this because I have used megaread 
> in the past.  Unfortunatly @ is rarely used and I don't have a 
> photographic memory! :-)
>
> On 3/27/2017 12:49 PM, Bill Pierce via Coco wrote:
>> Dave, Tim, Robert etc, You can't "megaread" "/dd". As Dave stated 
>> it's a directory and not a file, so error 214 was correct.
>> The help message is not "wrong", just incomplete. The "@" is a 
>> standard in OS9 directive for opening and reading the "raw" device 
>> (it's in the manual) and anyone having read the manual, should know 
>> this :-P.
>> Many programs can use "@" as a directive and very few of those state 
>> so in their helpfiles.
>> In that respect, "Copy" would not work as copy assumes a definate 
>> file size (obtained from the file descriptor) and "@" has no file 
>> size, therefore would run forever (bad error trapping?) or error out. 
>> For copy to work with "@" it would have to read LSN0 to get the drive 
>> size (not part of the copy code).
>>   Megaread on the otherhand, works with "@" because you state a file 
>> size (or default size) and it will come to a stop at the said file size.
>>
>>
>>
>>
>> Bill Pierce
>> "Charlie stole the handle, and the train it won't stop going, no way 
>> to slow down!" - Ian Anderson - Jethro Tull
>>
>>
>> My Music from the Tandy/Radio Shack Color Computer 2 & 3
>> https://sites.google.com/site/dabarnstudio/
>> Co-Contributor, Co-Editor for CocoPedia
>> http://www.cocopedia.com/wiki/index.php/Main_Page
>> Global Moderator for TRS-80/Tandy Color Computer Forums
>> http://www.tandycoco.com/forum/
>>
>> E-Mail: ooogalapasooo at aol.com
>>
>>
>>
>>
>> -----Original Message-----
>> From: Dave Philipsen <dave at davebiz.com>
>> To: CoCoList for Color Computer Enthusiasts <coco at maltedmedia.com>
>> Sent: Mon, Mar 27, 2017 2:25 pm
>> Subject: Re: [Coco] Megaread problems
>>
>> So, I *think* that the real problem is that /dd is a directory. And 
>> in order to read a directory it has to be opened in a different way 
>> than a regular file. I haven't written any file manipulation code for 
>> OS9 in years so I'd have to look this up in the tech manual but I'm 
>> guessing that when you open a file for reading you may have to 
>> specify that it's a directory if it actually is one.  As an example, 
>> the disk editor 'ded' will correctly open a root directory and read 
>> it in (ded /dd). Additionally, megaread will correctly read from a 
>> regular file but if the regular file is shorter than what megaread 
>> wants to read then it will just finish early without errors.  So 
>> 'megaread /dd/bigfile' works but only provides useful information if 
>> 'bigfile' is at least one megabyte in size.DaveOn 3/27/2017 1:02 PM, 
>> Robert Gault wrote:> Tim Fadden wrote:>> <snip>>> So it is something 
>> system wide?  and not megaread itself?>>>>>> Any how just wanted to 
>> let you know your not loosing it. :-)>>>> In a way :). The help 
>> message is incorrect for this utility and should > indicate that a 
>> raw read is necessary, ex. megaread </DD@>> Robert>>-- Coco mailing 
>> listCoco at maltedmedia.comhttps://pairlist5.pair.net/mailman/listinfo/coco
>>
>
>



More information about the Coco mailing list