💾 Archived View for tilde.club › ~anthonyg › files › tech › onlycoke.txt captured on 2023-04-26 at 13:56:41.
⬅️ Previous capture (2022-07-16)
-=-=-=-=-=-=-
The "Only" Coke Machine on the Internet Hi, I'm the CMU CS Department Coke Machine. A lot of folks have written a quite a bit about me in the last couple of years, and most of them can tell you more about the history of me and my family than I can. Before I worked here, my Mom, and I think her Pop (heh heh :-) used to sell sodas to the folks in the Computer Science Department. In fact, my family has been here longer than most of the students, and even a lot of the faculty. We moved to the third floor of the computer science building (Wean Hall) in the 70's. I still sell Coke in bottles, but they're big 20 oz plastic things these days. They go for 50 cents each, which I guess isn't too bad considering inflation. And at least they don't break inside me any more like the glass ones used to. What a mess... Tom Lane had the following to say about us: > Since time immemorial (well, maybe 1970) the Carnegie-Mellon CS > department has maintained a departmental Coke machine which sells > bottles of Coke for a dime or so less than other vending machines > around campus. As no Real Programmer can function without caffeine, > the machine is very popular. (I recall hearing that it had the highest > sales volume of any Coke machine in the Pittsburgh area.) The machine > is loaded on a rather erratic schedule by grad student volunteers. > > In the mid-seventies expansion of the department caused people's > offices to be located ever further away from the main terminal room > where the Coke machine stood. It got rather annoying to traipse down > to the third floor only to find the machine empty - or worse, to shell > out hard-earned cash to receive a recently loaded, still-warm Coke. > One day a couple of people got together to devise a solution. > > They installed micro-switches in the Coke machine to sense how many > bottles were present in each of its six columns of bottles. The > switches were hooked up to CMUA, the PDP-10 that was then the main > departmental computer. A server program was written to keep tabs on > the Coke machine's state, including how long each bottle had been in > the machine. When you ran the companion status inquiry program, you'd > get a display that might look like this: > > EMPTY EMPTY 1h 3m > COLD COLD 1h 4m > > This let you know that cold Coke could be had by pressing the > lower-left or lower-center button, while the bottom bottles in the two > right-hand columns had been loaded an hour or so beforehand, so were > still warm. (I think the display changed to just "COLD" after the > bottle had been there 3 hours.) > > The final piece of the puzzle was needed to let people check Coke > status when they were logged in on some other machine than CMUA. CMUA's > Finger server was modified to run the Coke status program whenever > someone fingered the nonexistent user "coke". (For the uninitiated, > Finger normally reports whether a specified user is logged in, and if > so where.) Since Finger requests are part of standard ARPANET (now > Internet) protocols, people could check the Coke machine from any CMU > computer by saying "finger coke@cmua". In fact, you could discover the > Coke machine's status from any machine anywhere on the Internet! Not > that it would do you much good if you were a few thousand miles away... (Which is not to say that I haven't had a lot of electronic visits and kind email from folks all over the country and all over the world.) Tom continues: > The Coke machine programs were used for over a decade and were even > rewritten for Unix Vaxen when CMUA was retired in the early eighties. > The end came just a couple years ago when the local Coke bottler > discontinued the returnable, coke-bottle-shaped bottles. The old > machine couldn't handle the non-returnable, totally-uninspired-shape > bottles, so it was replaced by a new vending machine. This was not long > after the New Coke fiasco (undoubtedly the century's greatest example > of fixing what wasn't broken). The combination of these events left CMU > Coke lovers sufficiently disgruntled that no one has bothered to wire > up the new machine. > > I'm a little fuzzy about the dates, but I believe all the other > details are accurate. The man page for the second-generation (Unix) > Coke programs credits the hardware work to John Zsarnay, the software > to David Nichols and Ivor Durham. I don't recall who did the original > PDP-10 programs. Steve Berman then chimed in: > In 1992, a second year graduate student and a full time staff member > of the CMU CS department decided to re-connect the coke machine to the > internet. The new Coke Machine Interface passively senses the > presence of bottles in the machine by the state of the "empty" light > for each column. The status of the nearby M&M machine is also > monitored. The new Coke Machine Interface is based on home-brew > optical isolators designed by John Zsarnay before he left CMU in 1991. > The new Coke Machine Interface resides on a PC-XT class machine whose > host name is COKE.ELAB.CS.CMU.EDU at IP address 128.2.209.43. > > The Coke Machine Interface hardware was constructed by Steve Berman who > also integrated the network interface software. Greg Nelson architected > the machine status software and installed the interface. For the "CMU SCS 25th Anniversary Symposium," Craig Everhart, Eddie Caplan, and Robert Frederking described things this way: > The only problem with the Coke machine was that after trekking down to > buy something it was found to be either empty or newly-filled (and > there are few more revolting substances that warm Coke; ideally it is > served just slightly above freezing). John Zsarnay created an > interface between the six little "empty" lights and a serial port. > These lights would flash when a bottle was dispensed and would stay > lit when a column was empty. Mike Kazar programmed a server machine > to track the time of the last transition for each column. Mike and > Dave Nichols put together a simple network protocol by which any > machine on the local Ethernet (and eventually on the Internet) could > probe the current status of the Coke machine. Dave wrote the program > that printed out the length of time since each column had been totally > empty. Ivor Durham wrote the "Finger" server so that if you fingered > the user "coke" you would get the status of the columns. One of the > most-used Perq/Canvas applications displayed the coldness as an array > of bar graphs in the same layout as the selector buttons on the > machine itself. Glenn Meter made the following comments: > The first coke machine information that could be gotten over the net > was on the old CS coke machine. It used the old-style coke bottles, > the tall ones which curved in and out. The machine was near the old > CS terminal room, just off the elevators of the third floor. They > used to have an Alto or two (early grahical workstations) showing the > coke status through the glass walls of the terminal room. So, when a > guest was shown the facilities, one of the first things they saw was > the status of the coke machine. > > When the local coke supplier no longer could supply the old-style > bottles, a new machine with the current squat and cylindrical bottles > was installed. It took a while for people to reconfigure the new > machine so that it's status could be fingered over the net. > > Around 1990, the new machine was finally connected to the net, along > with the M&M machine next to it (actually, the M&M machine was > connected first). At first, you had to run a program called 'jf' (for > Junk Food) to get the information. (However, my interface has changed again and at the moment much of the old software to access me is out of date. Some day, some kind soul will put that back on line, and will give my little friend the M&M machine a proper sensor so that his status is meaningful.) Glenn continues: > Later on, someone added the interface so you could finger the machine from > anywhere on the internet. In fact there are now a number of machines available on the net, so it's not at all fair to call me the *only* Coke machine on the Internet. From Bennet Yee: >This is a list of various coke or other vending machines that are accessible >via the Internet. >* Carnegie Mellon University coke and M&M machine (Fixed!) >* Cocacola and Pepsi at Columbia University >* University of Wisconsin (appears to be just a maintennance account, not a > real coke-machine-on-the-net) >* UC Berkeley >* Rochester Institute of Technology, Computer Science House > * Soda machine status > * stock details > * graphical display and coke temperatures >* University of Western Australia >* Coffee machine (Cambridge) So, that's a bit of my history, captured by the words of those who have love me and and used me. The Carnegie Mellon University Computer Science Department Coke Machine