100 Years of Macintosh
Zero seconds on the Mac OS system clock is January 1, 1904. The Mac OS epoch hits 100 years ... now. That's assuming you live in the Pacific time zone, anyway: the Mac OS epoch is unique in that it is time zone-specific. Of course, none of this applies unless you are running Mac OS, and all you Mac users are using Mac OS X, right? (Geek note: the Mac OS epoch is unsigned, which is why it can count over 100 years from 0 seconds, and 32-bit Unix can't, though it can count backward to 1901.)
I've been using my older Mac all evening (I know, boring life). Right now it claims it's "2:01:22 AM 1/1/2004". Seems to be OK to me.
I will remove the PRAM battery from my LC II temporarily and boot it up, resetting its internal clock, in commemoration of this event.
It seems that with Apple's other projects, they stand a good shot digging themselves out the nitch they carved out long ago.. Since Apple models itself a hardware company, do they offer patches on a similar basis as Microsoft or to they rely more on the BSD patching system?
it refers to the fact that when something caused the old MacOS to lose the current date and time, it would default to 1/1/1904. it's the date in the old PROM that is used as a base starting value. much like epoch in UNIX(TM)
Ewwww... I don't think I want to see what a 100 year old Apple looks like.
Life is not for the lazy.
The Classic Mac OS epoch limit was fixed quite some time ago. I believe it was around System 8.6 if I remember correctly. Classic Mac OS has since that version had the ability to work with any date in the range from 20,000 BC to 30,000 AD.
This post doesnt have a real point, and isnt based on an article. It is just stating that today marks 100 years from the point that macs count from. Nothing bad happens from it, it can still cound for another 30ish years (i beleive).
The article confuses epoch and ticks. The epoch is a fixed point in time. Ticks is a number of seconds (or other time unit) since the epoch.
Nya, nya!
Fresnel lens has a small scratch, and vacuum tube port is broken, but otherwise mint. Best offer.
Before you go, just test to make sure the 'Speech' extension and control panels are in order. Wouldn't want to get stuck out there in the cold with your machine not listening to you.
"Sometimes, I think Trent just needs a cup of hot chocolate and a blankie." -Tori Amos on Nine Inch Nails
Mac OS epoch is unique in that it is time zone-specific.
It is unique, in the sense that it is crappy.
On Unix, the epoch is an extremely well-defined moment in time, so then is any point in time measured in epoch-seconds is also extremely well-defined.
On the Mac, the epoch-seconds depends on the time zone, meaning that in order for a measurement of time in macos-epoch-seconds to be meaningful, you also need to know the time zone. To me, that kind of ruins the whole point...
Dec. 31, 1903, 6:00 PM
Which may be the default for the Central time zone.
Do I really need those files anymore? Well sure! Some of them are old entries for the Bulwer Lytton Contest, and you never know when I'll have enough to collect for section of a short story collection. Plus, you know that as soon as I throw away a file, I'll need it the next day. That's just how things work.
This is one of the many, many reasons why I've gone from a 60 Meg to a 60 Gig hard drive. ;-)
Lawrence Person (lawrencepersonh@gmailh.com (remove all "h"s to mail)
http://www.lawrenceperson.com/
Note that there's nothing particularly special about hitting 100 years after epoch, being that 100 years is not a technically interesting length of time and the epoch being 1/1/1904 isn't non-technically interesting.
A technically interesting length of time (such as 2^32 seconds) from epoch would be noteworthy, but that's a few decades off.
A non-technically interesting length of time (such as 20 years) from the date the Macintosh was first introduced would also be noteworthy, and that's later this month I believe.
I'm a bit tired; did anyone grok that?
$x='S24;r)>63/* h@<5+oZ)32"5cz';$me='phroggy'x$];
$x=~y+ -xz+\0-Tx+;print$_^chop$me for split'',$x;
Actually all Macs are defined that way, the hardware clock is defined that way.
Little know fact (or widely known) almost all Macs will reset to January 1, 1969 if the batter is removed.
No, 2^31 passed. 2^32 would be in 2040.
Ha! Us Windows users don't have this problem. Microsoft won't let us use a Windows OS that old! *SmUG*
"Derp de derp."
Why did these people pick these various epochs? Why 1904? Why 1970? Why is unix going to have (?) problems in 2038?
John Kerry is a Joke!
Actually it depends on the Mac - there are about 4 or 5 dates they can reset to:
1904, 1956, 1976 , 1984, 2001, depending on the machine.
This was a "Stump the Experts" Question at the 2003 world wide develoepr conference.
Palm OS also uses 1904 as 0. I don't know about Macs, but I do know that the DateType structure uses a 7-bit field for the year, so 2027 will be the end of the world for Palm handhelds.
Gates' Law: Every 18 months, the speed of software halves.
"I am a homosexual. I bought an Apple computer because of its well earned reputation for being "the" gay computer."
Okay, the whole 'Mac users are gay' troll is very stale now. Here's something a little fresher:
"I heard that OSX is based on eunichs!"
(man I hope the mod dudes are in good humor today.)
I seem to remember being amazed at just how many damn dates there were... and being even more amazed that people knew them...
nothing compared to that guy who came up with the internationalisation bug/easter egg that took three minutes just to describe....
I thought WWDC was full of nerds, but then Stump the Experts was like concentrated nerd juice...
i don't read slashdot anymore.
Some Macintosh models have clocks that reset to August 27, 1956 (and to a time other than midnight, I believe). This is the birthdate (and time) of Ray Montagne, the Apple engineer and programmer who designed the chip that controlled the PRAM on those models.
As for January 1, 1904, this date was selected because the original Mac's clock (which counts in seconds) can encompass a period of about 136 years. Selecting 1904 as the start date means that the 136-year period covered by the clock (1904-2040) includes the birthdate of nearly every Mac user, and extends well past the expected lifetime of the Mac OS. It also means that the simplest rule for leap-years can be used (every fourth year has an extra day), which simplifies day and date calculations. They didn't choose the year 1900 because it was not a leap year.
~Philly
I agree all those epochs are too random, including the birthday of Jesus Christ. IMHO the only meaningful and universal epoch is a time of the Big Bang. All time should be count from that.
Less is more !
The Macintosh traditionally measured time for most purposes in seconds since Midnight, January 1st, 1904. The call to get this value is GetDateTime() which takes a pointer to a unsigned long and returns the number of seconds by assigning the value to the argument.
Unlike what the article says, GetDateTime() is still available under the Carbon framework in MacOS X. However, there are now other ways of dealing with date/time in the MacOS. Ironically the preferred method, CFDate is also available under MacOS 9. So, I don't really get the point of the write up saying that this works only in MacOS 9.
Frankly this is of little interest to anyone who is not a Macintosh programmer - and only mild interest to those of us who are Macintosh programmers.
It is interesting to note that the Apple Newton also measures time from this reference point. However, it measures minutes since 1904 instead of seconds in dealing with its default date handling routines. On the Newton they had no real reason for picking that reference date other than that the Mac already used it.
On the original Mac, they did have a good reason for picking it. Apparently 1904 is the first leap year in the 20th century and it simplified the algorithm for factoring in leap years by starting at that point. Since they were trying shoe horn a graphical OS onto a 128Kb machine with no HD (but they did have some ROMs), you can't really fault them for taking a few shortcuts.
Avoid Missing Ball for High Score
Actually, in just three weeks there will be a real anniversary of the introduction of the Macintosh - January 24th, 1984.
Hopefully, just too many drinks for a New Year and not a troll. 2^16-1, which corresponds to unsigned 2 byte int, wouldn't even last for one day. INT_MAX assuming four byte integer is 2^31-1. When the variable reaches it's max value, it will change to a -2^31. Depending on how functions like ctime are implemented, this may work just fine until the start of 22nd century, set the date to 1902 or cause programs to display garbage data or even crash. It will definitely not set the date to 1970, which would correspond to 0, not INT_MIN.
Related comic
:)
and all you Mac users are using Mac OS X, right?
No, actually. You forgot that OS X is optimised for G4 architecture and newer. Even a fast G3 box is often brought to its knees by Jaguar due to its lack of specific hardware features. OS 9 is not dead: that is apple marketing hype. sure, its becoming more of a niche platform, and eventually the market will drive it to being a "retro platform" or whatever but thats another couple years at least. but its preferred if you don't have a particular need for a UNIX environment and/or you really need to eek out every last bit of performance from your hardware... and even if you did need a unix environment, what not just use linux? oh yeah, no itunes, my bad...
don't get me wrong. OS X is a tight platform, and i can't wait till the day i buy a brand new g5 or whatever and run OSX full-time. but come on: i'm one mac user thats not gonna bow down to the cult... my G3/800 MHz w/ 512 MB ram screams in OS 9.2.2 but feels like a 286 when i'm in jaguar (10.2.6), and sorry but i just don't have the time or mental energy to have to be waiting on my computer when i'm trying to get stuff done quickly.
alright, i'm done ranting. =) oh, and btw, i've had more than one Mac come up w/ 1856 (not 19--) when the battery dies...
Latest scientific estimate of age of universe from WMAP data: 13.7 billion years +/- 200 million years
, 616 ~= 1.845*10^18 -- quite enough for the current age of the universe and 3 more of the same length tacked on.
Assume 13.9 as worst case.
Assume 365 days, 5 hours, 48 minutes, and 46.5 seconds for a 'year' -- the time it takes for the Earth to go around the Sun once -- ignore the 'slowdown' (which hasn't happened in 5 years anyway) alluded to in an earlier article. (no real need to be so exact though -- 31,560,000 seconds would work fine)
((365*24+5)*60+48)*60+46.5 = 31556926.5 seconds in the 'year'
13.9x10^9 * 3.156*10^7 = 4.38684*10^17 seconds
2^32=4,294,967,296
2^64=18,446,744,073,709,551
If you really need to skimp on the bit length, we could suffice with 59 bits, which would give us:
2^59=576,460,752,303,423,488 ~= 5.76*10^17 -- at least 100 quadrillion years to spare before the Y-576trillion-K bug rears its ugly head.
The clock epoch (Jan 1st, 1904) and the time it resets to are two different things. All time is counted from the 1904 date. It's up to the designer of that particular motherboard/system/whatever what date the system will reset to if the time value has been lost. Usually it's sometime before the Mac could have ever existed so applications can tell whether or not the date IS actually wrong. If the OS returns 1970, some apps warn you that the date it set incorrectly.
The time and
date corresponding to 0 in an operating system's clock and
timestamp values. Under most Unix versions the epoch is
00:00:00 GMT, January 1, 1970; under VMS, it's 00:00:00 of
November 17, 1858 (base date of the US Naval Observatory's
ephemerides); on a Macintosh, it's the midnight beginning
January 1 1904. System time is measured in seconds or ticks
past the epoch. Weird problems may ensue when the clock wraps
around which is not necessarily a rare
event; on systems counting 10 ticks per second, a signed
32-bit count of ticks is good only for 6.8 years. The
1-tick-per-second clock of Unix is good only until January 18,
2038, assuming at least some software continues to consider it
signed and that word lengths don't increase by then.
Wall Time is the `Real world' time
(what the clock on the wall shows), as opposed to the system clock's
idea of time. The real running time of a program, as opposed to
the number of ticks required to execute it (on a timesharing
system these always differ, as no one program gets all the ticks,
and on multiprocessor systems with good thread support one may get
more processor time than real time).
Wrap Around of a counter that starts over at zero or
at `minus infinity' (see infinity) after its maximum value has
been reached, and continues incrementing, either because it is
programmed to do so or because of an overflow (as when a car's
odometer starts over at 0).
Never try to beat a professional at his own game!
A non-technically interesting length of time (such as 20 years) from the date the Macintosh was first introduced would also be noteworthy, and that's later this month I believe.
That is indeed later this month, dated from the SuperBowl 1984 when the Apple SuperBowl commercial aired. And there are some rumors that Apple will air it again, during the 2004 SuperBowl, to get some of that old time feeling back.
--
$tar -xvf