PERIOD, The Model 100 Periodic Table Program - History

[Copyright 1982,1983,2000,2002 Frank Durda IV, All Rights Reserved.
Mirroring of any material on this site in any form is expressly prohibited.
The official web site for this material is:  http://nemesis.lonestar.org
Contact this address for use clearances: clearance at nemesis.lonestar.org
Comments and queries to this address: web_software_2011 at nemesis.lonestar.org]

What is PERIOD?

PERIOD is BASIC program that can search and display information from the Table of Periodic Properties of the Elements, also known simply as the Periodic Table. Elements can be searched by name, element symbol, atomic number, or atomic weight. The electronegativity, electron orbit distribution, and crystal type are displayed.

PERIOD also holds the distinction of being the very first real application written specifically for the TRS-80 Model 100, the original laptop (or notebook) computer.


History of PERIOD

In the summer and fall of 1982, Frank Durda IV was assigned the task of testing a new type of computer that Tandy was having manufactured by a company called Kyocera. Normally, when new computer products were under development at Tandy, they were not to be discussed with anyone outside of the hardware, software and documentation departments, but within these departments, just about anyone could find out about any other project. Not so with this new computer. Frank received one of the few working samples (unit number 3), one of ten in existence and one of five sent to the United States. He was under orders to not show this computer to anyone or discuss it with anybody, nor could anybody else in the Quality Assurance department see the specification, early documentation, or problem reports on the product.

Tandy management even wanted the unit hidden when anyone else was around, but Franks 5'x7' cubicle (that contained a full-sized free-standing desk and a chair that you had to climb into because it was wedged between desk and wall) was located in a 20'x20' former conference room with five other cubicles that all opened onto one another, so this restriction proved somewhat impractical.

This computer would eventually be known as the TRS-80 Model 100, was first mentioned to the general public on March 25th of 1983, both with a full page ad on the back page of section one of the Wall Street Journal, and in stories run in other newspapers on the same day. (The Fort Worth Star Telegram ran their first story on the Model 100 on March 25th.) The formal introduction date was Tuesday March 29th, 1983, a date that has been reported incorrectly by as much as three years earlier in some places, largely because Tandy Corporation (now RadioShack Corporation) managed to get the year wrong on their own web site.

The Model 100 was one of six products that Tandy released each Friday over six weeks in early 1983. The products announced during this advertising campaign were the Model 4, Model 12, MC-10, ARCNET, XENIX, and the Model 100.

Franks job on the Model 100 product was to test functional aspects of the Model 100 system. The working sample provided looked essentially identical to the production units, although it lacked the name plate, used a plastic lens over the screen that scratched far too easily, and had a 4.5"x7" circuit board outside of the unit that was wired into the Model 100 using a ribbon cable and one yellow wire. This external board held four EPROMs containing the test releases of firmware. At the time, it was too expensive to use 32Kx8 EPROMs that could plug right into the Model 100, so four 8Kx8 EPROMs were erased and re-programmed to get each new release of firmware to be tested.


Photograph of one of the Model 100 working samples with the external EPROM board.

As it turned out, the Model 100 required lots of testing and repeated firmware releases. Not only was this a new hardware platform that required new drivers and included some new applications, but Microsoft also broke their BASIC interpreter when they replaced the binary math routines with a BCD math pack. Although BCD math provided greater accuracy, it also slowed the interpreter way down, and introduced bugs all over the place.

One of the normal procedures for testing the BASIC interpreter was to run standard programs against it to ensure that you got the desired answers. However, at the time those tests needed to be done, the TELCOM function of the Model 100 was not working and so the only way these programs could be loaded into the Model 100 was by typing them in. It was quickly discovered that differences between Model 100 BASIC and other Tandy versions of BASIC meant that many of the existing test programs failed over subtle language differences and could not be used without modification, largely defeating the test. This meant that in addition to the normal testing of each command and function of BASIC to make sure they did what the specification documentation that Microsoft Japan was writing, new or modified programs had to be written to test "real life" programs.

One of the areas that Tandy had no previous test material for was the area of Model 100 BASIC graphics functions. Tandy had optional graphics support for the Model II and Model III, but the test programs didn't work on the smaller Model 100 screen and had trouble with the BCD math handling on the Model 100. New routines had to be devised in order to test the drawing functions.

The need to test BASIC was the beginning of PERIOD. PERIOD was written to not only test the graphics capability of the Model 100, but also to demonstrate a practical application running on the system.

An initial version of PERIOD with an abbreviated periodic table was written in August of 1982. A version with a complete periodic table existed by October 11th, 1982, version 1(4). In late November or early December, the Model 100 and its firmware was released to manufacturing. The application developers at Tandy and Microsoft did not receive production hardware samples until December 1982 or January 1983, clearly making PERIOD the first add-on application written specifically for the Model 100.

Meanwhile, there was a new idea rolling around inside Tandy, that of bundling an application with each computer. The first computer getting this treatment was the Model 4. Due to some insanity in the mind of the product buyer, the bundled program (a mailing list program) was written not by a programmer, but by one of the documentation writers who hadn't written software before (and it showed).

Despite this dubious start, the idea of bundling some software with a computer caught-on inside Tandy, even before any bundled hardware and software systems were sold. It was believed that it would be easier to sell a computer that did something, anything, without the customer having to immediately buy more software. This was a point that customers frequently complained about, but the idea was opposed in some parts of Tandy, with arguments against the idea like "Well, VCRs don't include a free movie".

Despite the objections, the Model 4 mailing list program became the genesis of having other bundled applications, including Deskmate for the Model 4, an application eventually ported to the Model 1000 family which grew from there.

On the Model 100, it was argued that it already came with some applications, but there was an urge to have at least one Tandy program present on the system. Tandy knew that they only had excusive rights to the Kyocera unit for a short time and soon you would be able to buy essentially the same computer from other vendors, and they would likely have some or all of the same Microsoft-provided applications that the Model 100 had, maybe even some of the ones that Tandy elected to drop in favor of other features.

The possibility that PERIOD could serve as a store demo or even be bundled as a sample application pushed Frank Durda IV to complete coding, code-packing and debugging of the PERIOD program. It was shown to Tandy management and the computer buyer for the Model 100 at Tandy in mid-October 1982.

Although the R&D management thought the program was slick, the computer buyer didn't like things he didn't understand, and he didn't understand chemistry or anything that involved numbers, so he really wasn't impressed. A further problem of how to get the program loaded onto Model 100 systems during manufacturing, and have it not fade before systems reached customers was another issue. Shipping the program on a cassette that the customer could load was also rejected. Eventually, Tandy, who really wasn't sure that anybody would buy the Model 100 in the first place, elected to not bundle any other software with the Model 100 system.


What eventually happened to PERIOD?

Despite the rejection by the buyer - sometimes considered to be a good thing since this Tandy Merchandising buyer had the knack for killing-off good ideas and substituting rotten ones - Frank continued work on PERIOD, reducing its size and adding more information to the element database. The last version developed was dated February 13, 1983. Since there was no further interest within Tandy for anything like PERIOD, several versions of PERIOD and other Model 100 programs developed during 1982 were written to cassette tape and shoved in a desk drawer.

In 1986, Tandy R&D had a "garage sale" where employees could buy surplus equipment. During the entire period when Tandy was in the computer business, Tandy never did offer computers and related items to any of their employees at or near cost, but instead gave them 10% discount off list, the same discount that any other Tandy employee could get, which meant that Tandy still made at least 38% profit margin (usually a lot more) at the store when selling to their own employees. (This was on top of profit already made by Tandy factory, Tandy warehouse and Tandy transportation divisions.) Most R&D employees would swarm to these junk sales as a way to get used but affordable systems that were perhaps two or three years older than what they had on their desks, and those office systems were usually at least one year older than what was being sold in the stores. Only a few R&D employees got current-model equipment, and it was invariably pre-production samples, with their own quirks.

During the 1986 sale, Frank was able to get the working sample Model 100 he had originally worked with back in 1982, along with its external board still hanging out the back of the case. Most people looked at this combination of computer and wires and decided to look for something more-assembled, not really knowing what it was. A trip to the Tandy outlet store (then specializing in surplus parts by the pallet) and located the second version of the Model 100 masked ROM, yielding a complete Model 100 system (minus the case labels). However, the tapes for PERIOD and some other programs written for the Model 100 could not be found at this time.

In 1996, Frank was unpacking moving boxes at his home, and discovered some TRS-80 data tapes mixed-in with digital data tapes he used at a job prior to working at Tandy. The TRS-80 tapes were from the Model I, Model III, Color Computer and the Model 100. Some still had data on them. However, the Radio Shack "data grade" tapes had deteriorated and only portions of them could be read. A few non-Radio Shack audio tapes with TRS-80 data on them were more readable. Trying to restore the tapes was set aside until 1998, when some noise reduction equipment was added, allowing more of the data to be recovered. Over two dozen reads were performed from multiple tapes, all claiming to be Version 1(6) of PERIOD.BA, the last version written in the 1980s. Of those repeated reads of the surviving tapes, only six reads got all the way through without aborting and of those six, only two compared.


Restoring the Program

Despite having two reads that did compare, that version had errors when run on the Model 100, and it was known that Version 1(6) did work back in 1983. The six successful reads were moved to a FreeBSD platform so that context diffs could be made across all six copies. Elements of all six reads of the two recovered tapes were used to locate and correct errors introduced in the tape backup and restore process. A paper listing from the same period was also found and used in the compositing process. This composite code was downloaded into a Model 100 for testing. Eventually, a version was produced on the Model 100 where all 108 elements would display without a failure. At this point, the accuracy of the data displayed was not being considered, only that the program didn't abort.

At this point, PERIOD was moved to a MS-DOS platform, where a copy of the BASIC that was bundled with PC-DOS and MS-DOS in the early eighties (a fairly close relative) was used to renumber the program. The new composite and renumbered version was named Version 1(7). Copies were created and then changes were made to allow PERIOD to run on the PC-DOS version of BASIC, using ported copies of UNIX utilities and editors.

One key area of changes involved the absence of the Tandy-unique PRINT@ command in the PC-DOS BASIC, which had to be replaced with the Microsoft LOCATE command. It was also discovered that the text character cells on the Model 100 and PC used a different number of pixels, meaning that the PC version used more pixels for the same amount of text, so the placement of the graphics and fixed-position text had to be shifted to the right in the PC-DOS version. This also required the cubic crystal structures to be shrunk slightly so that they would fit in the remaining area on the PC CGA 320x200 screen format, which was the closest size to the Model 100 screen dimensions.

Having generated a working version of PERIOD for the PC-DOS platform, it was updated to reflect the additional four elements discovered since the original work on PERIOD in 1982, and to make updates and corrections to the existing element data. (The annotated source code documentation discusses the problems encountered in obtaining definitive information for some elements.)

Once all updates were complete and the PC-DOS version was working well, it was saved in ASCII format. This version was then compared against the earlier version to determine exactly what changes had been needed to make the program work on PC-DOS BASIC. From those differences, a copy of the PC-DOS version was edited so it used the PRINT@ command instead of LOCATE, and all the position settings that had been correct for the Model 100 screen were restored. This version was downloaded into a Model 100 and tested. Errors found on the Model 100 were fixed on the Model 100, until the Model 100 version was working correctly and could correctly display all 112 elements. This new Model 100 version of PERIOD was saved in ASCII and uploaded back to PC-DOS and diff'ed against the PC-DOS version of PERIOD to verify that all fixes made to one version were in the other, and that no errors had crept in during the upload/download process (transferred at 300 baud to avoid overruns on the Model 100).

Finally, the copies on the Model 100 were erased and a fresh copy was downloaded from the PC one more time. The code was immediately re-uploaded and compared against the master to ensure that no errors had occurred during the transfer. The copy on the Model 100 was now deemed "good" and was converted to tokenized BASIC. All 112 elements were tested again to make sure they would all display correctly. The other search commands were also tested in parallel with an identical set of tests on the PC-DOS system running the same PC-DOS port of Version 1(7).

The Model 100 was then connected to a PC sound card via the cassette port and the speaker and microphone jacks on the sound card. Then using the Creative Labs Wave Studio to record, the Model 100 saved the program to "tape", but in this case, the tape was a .WAV file on the PC. After editing, the .WAV file was played-back to the Model 100 and it was verified that a Model 100 could reload the program stored in this fashion.

The PC-DOS and Model 100 ASCII versions of PERIOD 1(7) along with the .WAV files were all transferred to a FreeBSD system. A version of the Model 100 code that was documented was created, and all of these files were made available via the World Wide Web.

The official home for all material related to PERIOD is http://nemesis.lonestar.org


[Copyright 1982,1983,2000,2002 Frank Durda IV, All Rights Reserved.
Mirroring of any material on this site in any form is expressly prohibited.
The official web site for this material is:  http://nemesis.lonestar.org
Contact this address for use clearances: clearance at nemesis.lonestar.org
Comments and queries to this address: web_software_2011 at nemesis.lonestar.org]

Return to the PERIOD Index page

Visit the nemesis.lonestar.org home page and index

Valid HTML 4.01!