[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: PRODOS file date query



Michael J. Mahon wrote:
> bloomer_au wrote:
>> I've got a bunch of program and text files I've been editing daily in
>> Applesoft on an 800kb floppy image in Sweet16.
>> 
>> When I catalog the disk in either 40 or 80 columns, nearly everything
>> says 'NO DATE' for both modified and created dates. Yet when I catalog
>> the disk with PROSEL, all the correct 2010 modification dates appear.
>> 
>> Anyone know why they don't show up by normal cataloging?
> 
> I suspect you have a ProSel modified for Y2K by Glen Bredon.
> 
> He chose to extend the year range by extending the "year" field
> in the packed date from 0..99 to 0..128, where 100 = the year 2000.
> It is non-standard for this field to be > 99, so anything but his
> utilities will report it as 'NO DATE'.
> 
> The "standard" scheme proposed by Apple was to move the "window"
> from 1900..1999 to 1940..2039, keeping all the "year" fields in
> the 00..99 range.
> 
> Since standard tools only report the 2-digit year, that approach
> is backward compatible as long as you don't sort by date.
> 
> Beverly Cadieux made patches to ProSel and the ProSel Utilities
> that are consistent with the Apple-recommended approach.  You may
> wish to use these versions to restore consistent behavior.
> 
> -michael
> 
> NadaNet 3.1 for Apple II parallel computing!
> Home page:  http://home.comcast.net/~mjmahon/
> 
> "The wastebasket is our most important design
> tool--and it's seriously underused."
>

00B3B6  1  C9 64        @3:       cmp       #100                ; >99?
00B3B8  1  90 06                  bcc       @4                  ; no, skip
00B3BA  1  D8                     cld                           ; binary
math
00B3BB  1  E9 64                  sbc       #100                ; take off
the 100
00B3BD  1  4C B6 B3               jmp       @3                  ; in case
some doof put >200

My port of EHBASIC does this in CAT... a modulo 100 on the year.  "<NO
DATE>" happens only when the whole date is 0 (and undefined behavior if the
month is >12).

-uso.