Skip to main content

Open Apple Vol 2 No 11 DEC 1986

  • PublicationApple Periodicals
  • Date1986-12-01
  • Pages8
  • SourceOpen_Apple-Vol_2_No_11-DEC_1986.pdf
← Magazines Open Apple Vol 2 No 11 DEC 1986
/ 8
Source: Internet Archive — Aggregated Apple-era periodicals, 1981–2012.
Page 1
Loading…
Text content (OCR)
Open-Apple Releasing the power to everyone. A concise look at Apple Il RAM Caution: The following article, like many Open-Apple articles, starts off in an engaging non-technical style designed to lure novice Apple II users into reading it. If you get into it a ways and suddenly realize you don’t have half an idea what it’s talking about, go back to the February 1986 Open-Apple, page 2.2, and read or reread “The Magic of Peek and Poke’ for this month's assignment. The first Apple I! came with 4K of readable-writeable RAM memory (the kind that gets erased when the lights go out). The latest model, the Ilgs, can easily support more than 2,000 times that much (8.1924). This month I'l tell you the story of how the II's memory grew. By telling it | hope we can answer a few of the questions Uncle DOS has been getting about the wide variety of RAM cards available today for the II-Plus, Ile, IIc, and IIgs. The story of Apple I! RAM parallels the story of RAM chips themselves. Every few years the companies that make RAM chips have been able to quadruple the number of memory bits on a single chip. At the same time, as they have qained manufacturing experience and as the size of the market for chips has gown, they have been able to lower prices. Today, the cheapest chips available, ona per-kilobit basis, are 256K chips. They cost from 1 to 2 cents per kilobit. (Or 8 to 16 cents per kilobyte—the 256K RAM chips typically used in Apple Ils hold 262,144 memory bits; it takes eight such chips to make 256K bytes of memory.) Older 64K chips currently cost 2 to 3 cents per kilobit; 16K chips cost3to6 cents. Newer 1,024K (1 megabit) chips currently start at about 7 cents per Kilobit. Ifthe standard chip-price cycle holds, however, these newer chips will be cheaper (ona per-kilobit basis) than todays 256K chips within a couple of years, Next will come 4 megabit chips; by the early 1990s you should be able buyyour Iigs 8 megabytes of RAM (16 4-megabit chips) for less than $200. Meanwhile, back in 1976 when Steve Wozniak was designing the original Apple II, $200 could get you eight 4K RAM chips. Larger 16K chips were only on the horizon. Wozniak designed the Apple II so that it could accommodate three eight-chip groups of 4K chips—a total of 12K of RAM memory. However, with an eye toward the upcoming 16K chips, Wozniak put “memory configuration blocks” on the Apple II motherboard that allowed the 4K chips to be replaced with 16K chips, one eight-chip group at a time. Before long, Apple lis had been configured into nine different memory sizes ranging from 4K to a massive 48K. Noother widelyavailable personal computer of the day could accommodate such a massive amount of memory. This is the primary reason VisiCalcwas originally written for the Apple II. This same kind of RAM foresight was missing from the Ile and IIc—they were built to use only the cheapest memory chips of their day, Foresight is back in style at Apple now, however — look at the IIgs. Almost no other personal computer of the day can accommodate such a massive amount of memory—I can't wait to see what comes of that. The language card. Massive though it seemed in 1979, 48K soon wasn’t enough. Apple wanted to make Pascal available for the II, but just couldn't fit it into 48K. So the Apple Language Card—which extended system RAM by another 16K, to a full 64K bytes of memory—soon appeared on authorized Apple dealers’ shelves. We've talked about language-card memory frequently in the past (going into the most detail, including how to turn the card on and off, in July 1986, page 2.46-47). The significant thing about the language card was its use of “bank switching: The 6502 microprocessor can directly address only 64K of December 1986 Vol. 2, No. 11 ISSN 0885-4017 newstand price: $2.00 Photocopy charge per page: $0.15 memory. Even in an Apple II with only 4K of RAM, a 12K portion of this 64K space is dedicated to built-in ROM memory and another 4K portion is dedicated to hardware control and to devices in slots. After you add 48K of RAM, all of the 6502's Post Office boxes have been rented. When you tum a language card on, it magically appears in the ROM’s address space, from hex addresses $D000 to $FFFF. The ROM disappears. This is what bank switching is all about—electronically replacing one “bank” of memory (the Apple II's built-in ROM, in this case) with another (here, RAM on the language card). The language card even took bank switching one step further by putting banks within a bank. The ROM address space is only big enough for 12K of RAM. To squeeze in another 4K (fora total of 16K) the language card uses the addresses from $D000 to $DFFF twice. One set of off/on switches tums the cardon with the frst of the two 4K banks appearing at $D000-$DFTF (and the other bank inaccessible), another set of switches tums the card on with the second 4K bank appearing at $D000-$DFFF. After Apple lit the way with the language card, a number of third-party 16K cards appeared. (They were quite successful because Apple originally sold its card only in combination with Pascal and the combo made for an expensive package.) Then the third party manufacturers one-uped Apple by bringing out 32K, 64K, and 128K cards. Most of these cards worked by adding multiple “language cards” to the Apple. Cards that worked like this selected the active “language card” by writinga card number (32K, 0 or 1; 64K, 0 through 3; 128K, 0 though 7) into $C084, With at least some of the cards you could also determine which “card” was active by reading $C084. Unlike Apple's 16K card, which was designed to work only in slot 0, many of the third-party cards would also work in any slot. (Add slot*16 to $C084 and to the locations given in July to manipulate cards in slots other than zero.) An interesting variation on the theme appeared on a 256K card called the App-lcache. Instead of being organized as multiple “language cards,’ App-- cache put a “window” where everyone else put the second $D000-SDFFF bank. Any of the card’s 64 4K-banks could be accessed through this window. Three of these banks also appeared at $D000-$FFFF as was normal for a DONT WOR, WELLHAE ENGI RR ES CHRSTWAS=1 TOD THEM WE WERE HSARD LNMERSITY, 2.82 Open-Apple language card. The bank that was to appear in the window was selected by writing its number (0 through 63) to $CO8F. By reading $CO8F you could determine which bank was active. Of all the memory configuration schemes devised in the heyday of the Apple II-Plus, this one was the most elegant. Before it could take the kingdom by storm, however, itwas overshadowed by the auxiliary memory scheme of the Apple Ile, which is probably the least elegant configuration ever devised. Apple Ile auxiliary memory. For years I've been thinking that there must bea good reason for the crazy way auxiliary memory is configured on the Ile and lic. I've been waiting for months for some software wizard to pierce the auxmem barrier and show us something of great value that can be done only because of the flip-flop, subdivided, and crossfolded format of Apple II auxiliary memory, But absolutely nothing has happened. Here, I think, is why. The first 64K of memory on an Apple Ile or IIcis configured to look like an. earlier Apple with a language card in slot 0. The second 64K of memory is configured to look just like the first—it extends from byte $0000 to $BFFF, has two banks at $D000-$DFFF, then continues in a single bank to $FFFF. This second 64K is split into two very distinct pieces—47.5K of “auxiliary” memory, and an “alternate” language card and zero page/Stack. The 47.5K auxiliary memory extends from byte $200 to $BFFF. The 16.5K alternate memory extends from $0000 to $01FF and from $D000 to $FFFF. Tools for using the second 64K of memory were built into the Ile, IIc, and later Apples. These fall into three classes—software, bank-switching softswitches, and display-switching softswitches. The software tools include a routine called AUXMOVE that will move blocks of data between the main and auxiliary banks of the 47.5K section of memory. AUXMOVE can't access any part of the 16.5K section. To use AUXMOVE, you store the source starting address at $3C-$3D, the source ending address at $3E-$3F, and the destination address at $42-$45. You mustalso set or clear the microprocessors carry bit to indicate whether you want to move from auxiliary memory to main (carry=0) or from main to auxiliary (carry=1). Aslight problem with AUXMOVE is that the routine lives in slot 3's firmware space at $C311 This is no problem on the IIc, but ifsomeone puts a card with ROM into slot 5 on a Ile, AUXMOVE will disappear on you. (By the way, the 1985 version of the Apple Ife Technical Reference Manual says on page 88 that AUXMOVE lives at $C312, but don’t you believe it) In addition to providing the ability to move data between banks, Apple builtin the ability to transfer control between banks. The routine you use to do this is called XFER and lives at $C314. To use XFER, you put the address youwant tojump toat $3ED-E in the bank you are in, set the microprocessor’s cany bit to indicate which 47.5K bank you want switched in (0=main, 1=aux), and set the microprocessors overflow bit to indicate which 16.5K bank you want switched in (0=main, 1=aux). Unfortunately, XFER doesn't really do all the things it needs to do if you switch 16.5K banks, but let's talk about that later. You can always use the bank-switching softswitches, if you want, and skip the built-in software. There are four switches associated with the 47.5K section of memory. These allow you to independently select either main or aux memory for either reading or writing, Ifyou want, you can read from one bank and simultaneously write to the other by setting these switches. They are: ROMATNRAM ROCARORAM RPAH RCARORAM 50002 $0003 0004 30005 read main RAM read aux RAK write main RAM write aux RAM To Flip these suitches, you must WRITE to them, not READ There are only two switches associated with the 16.5K section of memory. Flipping them tums on the associated bank for both reading and writing. ‘They are: sersTozP SETALTZP 0008 30009 set standard zero page/stack/ language card set alternate zero page/stack/language card To Flip these switches, you must WRITE to then, not READ Its important to realize that the old language card softswitches have priority over these switches. If you tum on the alternate 16.5K while built-in Apple ROM appears in the language card area, all that will appear to happen will be that the zero page/stack changes. If you then tum on the language card, however, the altemate language card, not the main one, will appear in the ROM’s address range. Vol. 2, No. 11 There are also three status registers that can tell you the currentmemory configuration. The high bit of these registers tells you howmemory is flipped (0=main, 1=aux): RORAMRO RORRRT ROALTZP 50013 scois sceis You aust READ these status registers You can also get at selected portions of auxiliary memory with the display-page softswitches, As we've discussed in the past (April 1985, Pages 27-28), the 80-column screen you see on your Ile or IIc resides partially in main memory and partially in auxiliary memory (assuming the first column is “zero”, the odd columns are in main memory and even columns are in auxiliary memory). In order to make it easier to access the portion of the display page that is in auxiliary memory, Apple added a softswitch that changes the function of the old PAGE! and PAGE2 softswitches, which have been around since day one. Normally the PAGE1 and PAGE2 softswitches flip the display between high- resolution graphics pages 1 and 2 or between text pages 1 and 2. (If you've never heard of “text page 2,’ don’t worry, hardly anything has ever used it because its not supported by Applesoft or the Monitor. On the Apple lleand later IIs, however, writing to a softswitch known as STORE80 causes the function of the PAGE] and PAGE2 softswitches to change. After you poke STORE80, PAGE1 activates the portion of the display page that’s in main memory for reading and writing, PAGE2 activates the portion in auxiliary memory. What's more, ifthe computer's low-resolution/high-resolution softswitches. are set for high-resolution, then PAGE] and PAGE2, in combination with STORE80, also have an effect on the portion of memory that holds high- resolution graphics page 1—$2000-$3FFF. Thus you can actually read and write in a fairly large portion of auxiliary memory without banking in the whole thing. This effect is in addition to the PAGE effect on $400-$7FF area; thats, when the HIRES and STORE80 switches are on, PAGE] and PAGE2 flip between main and auxiliary memory at both $400-7FF and $2000-3FFF. Here's asummary of all this: BAGEL (SCOS4 R/M) effects display sToREA® (sc000 4) only, no effect BASE ($0055 R/kl) on wenary LLORES ($0086 @/8) PAGEL (SCB54 R/M) main $400-7FF STOREBE ($C0L We PAGE2 (30055 P/M) aux 5400-7FF BPGEL ($0054 R/W) effects display STOREA® (30000 WL only, no ef fect BAse2 (SCASS R/M} on mesory HIRES ($0057 B/W) AGEL ($0054 R/M) main $2000-26FF+ San (soon ne BAGE2 ($0055 R/M) aux $2000-2FF+ + Indicates that this combination also effects $400-7FF R/M indicates uhether the suitch should be accessed with READ or WRITE Interestingly, none of these switches actually do anything to the current display that appears on your monitor. There's a switch at $CO50 that tells the Apple to switch to a graphics display; $C051 flips the computer back to text. There's a switch at $COOD that tells the Apple to switch to an 80-column display; $CO0C flips the computer back to 40 columns. Consequently, a program can access the auxiliary memory area from $2000 to $3FFF without even affecting the screen display. There are also status registers that can be used to determine the current status of any of these other softswitches. The high bit of these registers tells whether the feature is tumed on or not (1=on, O=off): ROSTORES® $0018 1=PAGEL/PRGE2 switches flip in main and aux menory ROTEXT $C@1A = L=computer is displaying text, not graphics ROPAGE2 SC@IC 1 =PAGE2 selected, not PAGEL ROHIRES $0010 A=display is high-resolution, not low-resolution ROBOCOL $CO1F —=display is B@ columns, not 4@ columns Awxanem difficulties. Even with this selection of software tools, bank softswitches, and display softswitches, auxiliary memory is difficult to use. The 16.5K alternate zero page/stack/language card memory in particular is extremely difficult to work with, The nut of the difficulty is that whenever you switch in the altemate language card you also get the alternate zero-page Downloaded from www.Apple2Online.com December 1986 and stack. Things would be so much easier if these could be switched in separately. Since they are connected you cannot, for example, use the two most common methods for passing data or parameters to a subroutine (putting the data in the stack or pointing to it with a zero-page pointer) if the subroutine you want to use is stored in or even tums on the alternate language card, Because of this very difficulty the software tool AUXMOVE, which moves data between banks (and which uses zero page for parameter passing), can’t get at either language card. XFER, which transfers control between banks, does work with the language cards (to an extent) but, as mentioned earlier, it doesn't do all itneeds to do. Remember that when you flip in the alternate 16.5K bank you get a new stack and zero page. Inside the microprocessor, however, there is a register called the stack pointer that is always aimed at the current stack position. Thus, when you flip in a new stack you also need to change the stack pointer —XFER neglects to do this. Apple’s manuals put this monkey on the back of programmers. Two bytes in the auxiliary stack are to be used as storage for inactive stack pointers; $100 for the main stack pointer when the auxiliary stack is active, and $101 for the auxiliary stack pointer when the main stack is active. Consequently, it's usually more straightforward to flip the 16.5K portion of memory with softswitches than with XFER, and to make sure the code that does the flip goes something like this: 1000:80 03 C8 ALTZP STA SETALTZP 1003:8 TK 1004:8€ 08 01 Stk $100 1007:AE @1 OL Lox $101 1008:98 i) etc 1100:8A MAINZ TSX STK $101 LOx $108 1107:98 DS 1108:80 06 ce STA SETSTOZP etc Of course, such code must be in the 47.5K portion of memory. If it's somewhere in the language card area, flipping the switch makes the program itself disappear. It would also be wise to tum interrupts off while making the switch, and don't forget to initialize $101 in the auniliary stack with a suitable value. Likewise, a significant problem with using the 47.5K ofauxiliary memory is that the program that flips the softswitches has to either be in both banks or ithas to bein neither, When you flip the softswitch that controls which bank of memory appears in the 47.5K window while using a program that itself lies within that window, your computer crashes because the program disappears —unless, of course, the second bank holds a clone ofthe program in the first bank. One way around this Is to use the firmware discussed earlier. The other is to move your program that flips the softswitches out of the 47.5K window— either up into the language card or down into zero page or the stack. The zero-page/stack area is pretty precious territory to be using for a bank switching program, however, and under ProDOS the language card is where the ProDOS kemel is. However, the ProDOS development team left the rest of us a small space at $D000-DOFF in the secondary bank of both language cards to use for our own auxmem bank-switching routines. The 64K RAMdisk. The three methods for accessing the second 64K that we've looked at so far are all built into the computer itself. ProDOS provides a fourth method of getting at this memory—it automatically sets up a RAMdisk there. Programs that do the same thing for DOS 3.3 are also available. By far the easiest way to use the extra 64K is with the RAMdisk. The April 1986 Open-Apple discussed the possibilities, in terms of Applesoft programs, extensively. There are several advantages to using the extra 64K as a RAMdisk (in addition to the obvious one of not having to write your own assembly language bank-switching programs). The main one is that—in addition to flipping the softswitches and moving things from bank to bank for you automatically—ProDOS manages the extra 64K. It keeps track of what's where. It keeps track of how much space is left. Itwon'taccidentally overwrite something important. ‘The main disadvantage of using the extra memory as a RAMdisk is that to actually execute a program, you have to load it into the main bank of Oper-Apple 2.83 memory. If you write your own assembly language bank-switching stuff, on the other hand, you can execute programs where they are stored, without moving them from the auxiliary bank. My opinion is that having to move routines to main memory for execution isavery small price to pay for memory management. You may disagree with me, of course— if you do, remember to disconnect the RAMdisk before you use auxiliary memory for other purposes. There is a specific protocol for this outlined in the Addison-Wesley edition of Apple's ProDOS Technical Reference Manual (and in Apple's “ProDOS Technical Note #8”), which I wish more software developers would follow. Software that doesn't follow this protocol (Apple Writer, for example), disconnects any storage device that peas to be in slot 5, not just ones that are using the auxiliary 64K memory Multiple auxiliary memory cards. The next chapter in the history of Apple Il RAM is most interesting. An Apple engineer by the name of Peter Baum designed a memory card for the Apple II auxiliary slot that created multiple 64K banks of auxiliary memory. This card works exactly like the usual auxiliary memory scheme with one slight difference—by writing a “pank number’ to a new softswitch at $C075, you can flip in an entirely new 64K of auxiliary memory. Apple wasn't interested in the card, however, and the design ended up ata little-known Texas company called Applied Engineering, AE wrote a program that allowed AppleWorks to use the memory on the card, named the card RamWorks, and the rest is pretty much history. Other companies, notal Checkmate Technologies and Legend Industries, have since introduce similar cards and similar software, but Applied Engineering became known world-wide by dominating the market for auxslot RAM cards. The best part of these cards has always been their support of AppleWorks. Froma programmer’ standpoint, they have all the bad features of standard auxiliary memory multiplied by the number of banks on the card. In addition to the usual problems, programmers have to devise some way to keep track of which auxiliary bank is active. There is no status register on the card itself that can tell you this; you have to store the bank number in memory. Applied Engineering recommends using bytes $FFFO in the 16.5K piece and $47B in the 47.5K piece for this, Reset doesn’tautomatically switch the card back to bank zero— programmers must take care to intercept Reset and do it themselves. In addition, Reset and interrupts always use some addresses they expect to find in the last few bytes of memory after $FFFO; these addresses must be written into every available bank on the card. Programs that want to support interrupts also need a special interrupt handler in each bank. Bank numbers, by the way, aren't necessarily sequential. Some cards have memory in banks 0 and 3 but not in banks 1 or 2. Itdepends on what kind of RAM chips (64K or 256K) were used in the card. Oh, and writing a bank number to $C073 also trips the paddle strobe, for those of you who know what that is. To ensure that the paddles are read properly, a 3 millisecond delay is required between switching banks and reading the paddles. Since | don’t recommend trying to use regular auxiliary memory for anything other than a RAMdisk, you can be sure | don’t recommend using additional auxmem banks for anything else, either. Nonetheless, we've gotten several questions about how to figure out from inside a program whether an auxslot RAM card has been installed in a computer and how to figure out how much memory it has. Here's a simple Applesoft program that uses the display-page softswitches to accomplish this: 100 REM * Test for multiple auxiliary menory banks * 11@ TEXT : HOME : VTAB 10 120 PRINT “Just a einute here...” : PRINT 130 DIM 8(127) = REN array to remember uhich banks have menory 140 POKE 49239,8 : REM turn on HIRES ($0057) 150 POKE 49153,@ : REM turn on STOREB® ($0201) 160 POKE 49237,8 : REM turn on PAGEZ ($C8S5) 200 FOR BANK=127 TD @ STEP-1 210 POKE 49257,BANK = REM $C073, 220 B(BANK)=PEEK(8192) : REN save value now at $2000 230 POKE 8192,BANK : REM put bank number at $2000 240 NEXT 300 FOR BANK=@ 10 127 ‘31@ POKE 49267,BANK : REM $873 320 IF PEEK(B192) > BANK THEN 360 : REM IF <> then no RAM bank here 330 POKE 8192,@ : IF PEEK(B192) <> @ THEN 360 : REM double-check 340 POKE 0192,255 : IF PCEK(G192) < > 255 THEN 350 : REN triple-check ‘35@ POKE 8192,6(BANK) : G(BANK)=1 : B=G+1 : GOTO 37@ ci, bi Some corrections and amplifications Grab a pencil and your binder of Open-Apple back issues and let's fix a few things subscribers have Pointed out to us this month. November 1986. The page between 2.74 and 2.76 is 2.75, of course, not 2.78. The page between 2.77 and 2.79 is really 2.78, not 2.75. Our index will use the correct, rather than the printed, page numbers, so change them now. We've gotten several requests for an AppleWorks 2.0 update to Alan Bird's “don’t pass go” program for ‘AppleWorks. The program appears on page 2.75 (you've changed the page numberalready, right?). It patches AppleWorks so that it doesn't stop twice and wait for keypresses on the way to the desktop. So we called Alan and found out that with version 2.0, the correct value for Al is 14468 and for A2 is 14148. Inthe software-we-forgot-about department, Alan reports (in response to a question on page 2.80) that a there is a machine language sort program called g ‘that works with Extra K on newer versions of Beagle Bros Pro-Byter disk. David Szetela at Nibble reports (in response to the question about sorting long DOS 5.3 catalogs on Page 2.78) that the program DISK MASTER on Nibble’s Disk Customizer disk has been doing that for four years already ($29.95 from Nibble, 45 Winthrop St, Concord, MA 01742 617-371-1660). Nibble has an extensive collection of programs —take a look at the Usting in the back of any issue. And George Tylutki reports (in response to the question about sorting long ProDOS catalogs on Page 2.80) that his program on the Nite Owl Devel- oper Disk #2 ($39.95 from Nite Owl Productions, 5734 Lamar Ave, Mission, KS 66202 913-362-9898) can alphabetize up to 623 files in a single ProDOS subdirectory (if there are more, it just leaves them alone). Finally, last month's article about the bug in the ProDOS floppy disk driver clearly stated that it referred to ProDOS LLL No sooner had it gone out than we got a call asking “which version of ProDOS 111?” It was news to us, but it seems there are several versions, which can be identified by the “modification date” when the file is cataloged. Apple's official ProDOS 1.11 release has a modification date of “09/18/84.” This is the version the article refers to. If you have a version with an earlier modification date, get rid of it. if you have one witha later modification date, someone, probably you, has already done some kind of modification to the file. May 1986. For example, you might have made the quit code modification that causes BYE to reboot, Vol. 2, No. 11 which was published in the May 1986 Open-Apple at the beginning of page 2.51 Obviously you didn't, however, or you would have called months ago to tell us it doesn’t work, as two subscribers did this month. First, there are no fewer than three mistakes in the third line of the instructions. That line should read: S720:CE Fa 03 6C FC FF In addition, the BSAVE command has the wrong number after the L parameter. To correct this, just scratch the L parameter out of the instructions. The Paragraph that follows the instructions should say that the machine code translates as DEC $3F4 followed by JMP (SFFFC). October 1986. In the chart of Apple I Family Identification Bytes (page 2.66), the Apple Ile/ original entry under SFBBF should be $C1, not $00. Control-D(eteated) [am experiencing a problem with loading custom characters into my Imagewriter using my Apple IIc and hoped you could help. There are two methods I have used to load custom characters. The first involves the use of the PRINT statement with the CHRS(n) function to send data bytes. For example, the following produces a lower case italics "n’”: 100 PRINT "nk"; CHRS(@); CHRS(100); CHRS(28); CHRS(4) 3 CHRS(100); CHRS(24)s CHRS(Q)s CHRS(@) 5 While this works fine itis a time consuming method and subject to many typing errors. Another method uses a FOR-NEXT loop and READ- 360 B(BANK)=0 370 Next 380 POKE 49267, : REM return $0873 to bank @ 400 PRINT “This machine ha banks of auxiliary meaory, “; 41@ PRINT “for a total of “s 420 PRINT 430 PRINT “This menory appears as banks:"; 44@ FOR BANK=0 TO 127: IF B(BANK)=1 THEN PRINT SPC(3); BANK; 450. NEXT 460 PRINT : PRINT : END The Apple ‘standard. In September 1985 Apple itselfintroduced astandard-slot-based extended memory card for the Apple II-Plus and Ile. In September of this year Apple introduced a new revision of the Apple Iic that canalso accommodate a special version of this type of card. The card for the Apple II-Plus/Ile also works in the new Ilgs. In addition, memory added to a IIgs by means of itsspecial memory expansion slot can be configured so that software running in a IIgs sees the memory as an Apple memory card in a standard slot. Unlike the Apple memory card, auxslot RAM cards don’twork on the II-Plus or the IIgs, which don’t have an auxiliary slot. Special cards that work like auxslot cards are available for the IIc, but, nowadays, so is the Apple card. Because the auxslot RAM cards can't be used with a IIgs as anything other than a cheap source of memory chips, | recommend that you think long and hard before buying one. If you upgrade your Ile to a Ilgs during the next 18 months (won't everyone?) the auxslot RAM card will be useless. There are several significant differences between the Apple memory standard and the auxslot RAM cards. The Apple memory card was designed from the beginning to be used asa RAMdisk. The card has machine language programs built into it that automatically activate the RAMdisk feature for both DOS 3.3 and ProDOS. All the auxslot RAM cards we've seen come with software that will tum them into RAMdisks, but this software is packaged on disk and has to be run separately to activate the RAMdisk feature. It isn’t possible to execute programs stored on an Apple memory card. The memory simply isn’t connected to the microprocessor. To execute a program stored on the card, the program must be loaded into main memory. Aswe have seen, however, for all practical purposes this is no different from what must be done with an auxslot RAM card. Cards that use the Apple memory expansion standard are available from several suppliers other than Apple itself. Applied Engineering version, called RamFactor, includes AE’s AppleWorks expansion software, as well as the ability to partition the card into several “disks” and to boot from it. A battery-back up option is available that essentially tums the card into a small but speedy “hard drive.’ Cirtech’s Flipper (known as Flipster in the U.S.), comes with most everything the RamFactor has except the battery backup and apres more operating systems (including all versions of Apple Pascal). As mentioned earlier, the IIgs has a new type of memory expansion slot that can hold up to 8 megabytes of RAM and 1 megabyte of ROM. When the IIgs is operating in “Ile mode,’ the only reasonable way to use the extended RAM is as a RAMdisk. The RAM appears to be part of a standard Apple memory card. When in “Ilgs” mode, on the other hand, the memory on this card is “linear” (not "bank switched” as with Ile auxiliary and language card memory) and is directly addressable by the microprocessor. This means the memory bytes appear in sequential memory addresses starting with byte $000000 and going up to the number of bytes of memory you have. (Eight megabytes of RAM would take you to byte $7FFFFF) The ligs includes a memory management tool that allocates the available RAM among programs —the built-in RAM disk is one of the programs that's likely to ask for memory. Rules for living er in /RAM. Since the easiest way to use extended memory on a Ile or IIc is as a RAMdisk, and since programs that use Hle/IIc auxiliary memory also work on the Il-Plus and IIgs RAMdisks, it seems reasonable that programmers should write software that takes advantage of RAMdisks rather than directly addressing additional memory. Because the operating system will handle RAMdisk memory contention, it should be possible for different programs to coexist peacefully. One big problem with the auxslot RAM cards has been programs that go out to see how much RAM is available on the card and then take all of it, ignoring any RAMdisk that might pre-exist on the card. Instead, software authors should make their programs configurable as to how much RAM the userwants them toaccess. The software should then obtain that much by creating a file on the RAMdisk. If that much space isn’t available, the user should be asked to delete some files from the RAMdisk. Additional RAM on the disk should be left free for other programs. In addition, programs should remember to delete their RAMdisk file as part of their quit routine. December 1986 DATA statements. For example, the same “n” can be produced by: 100 2 = 18 110 FOR X = 110.2 : READ BYTE 12@ PRINT CHRS(BYTE); + NEXT 130 DATA 110,72,0,102,28,4,100,24,0,0 Both methods work using DOS 3.5. But using ProDOS and the second example, the Imagewriter reads the data byte 4” as contro-D and interprets it asthe signal to end the loading sequence. My solution has been to use the READ-DATA method for all characters that do not contain a “4” and use the PRINT statement for those characters that do. Why does this happen? Why only with ProDOS and why only with the READ-DATA method? Any guidance would be helpful and much appreciated. Roger H. Brown Chesterfield, Mo. Your supposition that the Imagewriteris interpreting the control-D as an end-of-transmission signal is incorrect. It's Basicsystem that is interpreting the control-D as a signal. It thinks you want to send a DOS command. It swallows the control-D and the characters dragging their tails behind it and usually even has the nerve to call its nasty behavior your SYNTAX ERROR (since it can't make sense of the “command"). DOS 3.3 will do the same thing under slightly different circumstances. In both situations the specific problem isa result ofa widespread, poorty understood flaw that is characteristic of using control-codes and Escape sequences to send commands to devices such as disk drives, interface cards, modems, and printers. Control-codes and Escape sequences are here to stay, however, So it's probably best that we investigate this problem in some detail as we answer your specific question. First, let's make clear what's meant by “using control-codes and Escape sequences to control devices.” Take a printer. Usually you send it ASCII- encoded letters, numbers, and punctuation marks. It prints them. You also send it control-characters that aren't printed, but that tell the printer to do such things as returning to the left margin, underlining, and tabbing. These characters are embedded in the data stream yousend to the printer along with all the letters, numbers, and punctuation marks, Sometimes it’s necessary to send non-ASCII data to your printer. This might include the bytes that make upa custom character set, as in your example, orthe bytes that tell the printer how to print a copy of the Neanderthal on your high-resolution graphics screen. The ASCII meanings of this non-ASCII data will invariably include control codes, letters, numbers, and punctuation marks. Your printer doesn't print or respond to any of this, however. It knows you are sending non-ASCII data because you've told it so with ASCII codes that say “here come some custom characters” or “here comes a graphic.” However, there are at least two other creatures inspecting and sometimes manipulating the charac- ters you are trying to get to your printer from PRINT CHRS. These idiots don’t know you are sending non- ASCII data. They continue to search for, and respond to, what they think are ASCII command-codes embedded in your data stream. These folks are your printer interface card and DOS 3.5 or Basic.system. Your printer interface card watches the data you are sending to the printer very carefully. I's searching foracontrot-I character, which is supposed to mean that what follows is an interface-card command. When it sees a control-l, it eats it and at least one additional character. Then the card tries to make sense of its supper. If it can, it will take some action. If it can’t, your characters are simply digested and never reach the printer. Likewise, DOS 53.3 watches all the characters you print and pounces when it sees the two-character sequence control-M control-D (a control-M isa carriage return). In your examples, if you change the 28s to 15s youll find neither program will work with DOS 55, Because of all the problems programmers had with the DOS 3.3 command scheme, Apple's pro- grammers changed things slightly under Basic.system. Instead of watching for a Return, Basic.system secretly tums on Applesoft's TRACE mode and uses it to track the execution of Applesoft programs, statement by statement. Each time anew Statement is executed, Basic.system looks to see if it's PRINT. If it is, Basic.system further examines the statement to see if the first character that is to be printed will be a controt-D. If it is, Basic.system assumes that what follows, up to the next Retum character, is a DOS command. Note that in your first example the control-D is not the first character after the PRINT statement—that program works fine under Basic.system. In your troublesome second example, however, all the characters end up being “the first character after a PRINT,” including our friend CHRS(4). So we've identified your problem — but wait, there's more. Applesoft itself always "sets the high bit” on characters it prints. Thus, although you think you've sent 0, 100, 28, 4 and so on, what your printer actually has been recetving is bytes equal to those values plus 128—128, 228, 156, 132 and soon. You didn’t notice a problem, however, because the Imageuwriter automatically ignores the high bit unless you tell itnot to (either by sending acommand or setting a dip switch). Other people have encoun- tered this problem, however (see “A bit too many” in the April 1986 Open-Apple, page 2.24). To solve this general category of problems once and for all, we need to figure out some way to either bypass Applesoft, DOS, and interface cards, or to tell them we are sending non-ASCII data. In the April article just mentioned I included a short machine language routine for bypassing Apple- soft. Itwent lke this: 0300: F9 08 Loa 1800 0 ED FD JSR SFDED send it to COUT 2 RIS back to Applesoft The article shows how to poke this routine into memory. To use the routine, using your second example, for example, you would change line 120to: 120 POKE 769,8YTE : CALL 768 SFDED Is the address of a routine in the Apple Monitor, known as COUT (say “see-out"), that sends the character you want to print directly to the “current output device.” You may be surprised to learn, however, that both DOS 5.3 and Basic.system grab control of the critical current input- and output- device hooks and always appear to be the “current device.” They do this so they can spy on all the characters you print or type. By changing the JSR SFDED into a JSR directly to the interface card, however, you can bypass DOS as well as Applesoft. That will solve your control-D problem. Then the only problem left is deciding where to jump to on the interface card, All Apple I!-compatible load character Open-Apple 2.85 printer interface cards have machine language pro- grams built into them that show up tn the computer's memory at byte $Cs00, where "s” is the number of the slot the card is in, Byte $Cs00 itself on all cards is knownas the Basic entry point. After you doa PR# or IN# command, this is where control passes to print or get the next character. However, most cards use $Cs00 only as an initial- ization entry point. Only the first call to the card is supposed to use this address (although apparently even some commercial software sends all characters here). Sending subsequent characters to $Cs00 causes the card to be reinitialized with each character. According to the IIgs documentation, “This will currently work (to a degree) on the ligs, but applica- tions that do this are living on borrowed time, since it is almost certain that future firmware will not permit this practice.” As part of their initialization sequence, all interface cards I know of tell the Monitor where further characters should be sent (or where further characters can be input from) by changing the current-device hooks. Consequently, there are no standard locations for these calls. Actually monitoring the current- device hooks from inside an Applesoft program is difficult to impossible—DOS replaces the card's addresses with its own ina matter of microseconds. The only easy way to proceed from here is to dig the addresses we need out of DOS itself —both DOS 3.3 and Basic.system squirrel the card's addresses away where they can be used when needed. DOS 5.3, when at it's standard 48K location, stores the values we need at bytes 43603-4 ($AA53-4) for ‘output (43605-6 or $AA55-6 for input). Basic.system stores them at 48688-9 ($BE30-1) for output (43607- 8 or $BE32-55 for input). Wel show how to retrieve these values ina moment. Incidentally, many firmware cards also support a Protocol known as “Pascal 11” that does have identifiable locations for initialization, read, write, ‘status, and, on the Ilgs, control calls, You can use these entry points from any language—they were originally developed for Pascal but are now the entry points of choice for most languages. They are, however, more difficult fo use from Applesoft than the Basic entry points, because the microprocessor's registers have to be initialized to specific values before a call and because of some other important considerations—see Open-Apple June 1986, pages 2.34-35 fora little more on this. White it is relatively easy to bypass Applesoft and DOS, it is much more difficult to bypass an interface card. Itcan be done, however, by directly manipulating the interface card's soft switches and status registers —the card's “hardware.” This approach has the built- inadvantage of also automatically bypassing Apple- Soft and DOS. It is commonly used by commercial graphic printing programs, custom font downloaders, and software that works with modems, What makes this approach difficult is that there is no uniformity among interface cards at the soft- switch and status register level. | can give you ashort ‘subroutine that will solve the high bit and control-D problems of Applesoft and DOS on any Apple Il, but giving you subroutines to directly access the hardware on a multitude of interface cards Is much more complicated. Nonetheless, that's what I've been intending to do (as you know, we've had your letter for several months, already). But ! wanted to wait until the ligs came out so that we could include subroutines to directly access its hardware, since that aspect of the 2.86 Oper-Apple igs is very different from earlier Apple lis. Now that I've seen the serial port firmware, soft- ‘switches, and status registers on the ligs, however, Tve decided this is the wrong approach. The IIgs itself has serial port firmware that should permanently obviate any programmer's need to directly touch the hardware. In addition, using the firmware enhances your program's compatibility in the long run, since the firmware trick that gets non-ASCII data through the serial ports on the Iigs will work on any future ‘Apple Il, In fact. the trick works on the lc and on Il- Pluses and Iles equipped with Apple's Super Serial Card and with many other (but not all) interface cardsas well. The trick is to simply include the interface card command “control-I 2” in the output stream. The ‘Super Serial Card, the IIc, and the ligs all recognize this as a “zap” command. After the zap command, interface card command characters aren't acted upon, but instead are sent down the data stream with everything else, This continues until the card is reinitialized with a PR# command or the equivalent. (Note that you have to resend the control-I Zap) every time you doa PR#L) So we've distilled the solution to the “embedded command character” problem to: 108 REM * Initialize and “zap” serial port or card * 101 REN * You must give SLOT the proper value * 102 REM * before calling this subroutine. * 110 PRINT CHRS(4) ;“PRA”;SLOT 120 REM last chance to print any other control-I comands you need 130 PRINT CHRS(9) 3°27 140 POKE 768,169 : REM “LOR 8” 150 POKE 770,32: REM “JSR” 160 8=43603 : REM DOS 3.3 or 160 248688 : REM Basic.systen 165 POKE 771,PEEK(A) 170 POKE 772,PEEK(A1) 180 POKE 773,96: REM “RIS™ 190 RETURN 200 REM * Send data byte, avoiding ApplesoFt/00S * 201 REN * Data byte must be placed in D * 202 REN * before calling. . 21@ POKE 769,0 : CALL 768 : RETURN There is one other device we should mention that responds to embedded ASCII commands. That is the stand-alone modem. When on-line, Apple's Personal Modem and other “Hayes-compatible” products look for the character string "+++” and respond to it. What Apple's modem manual doesn’t make at all Clear is that it also looks for a one-second delay before and after the three plus signs. Without those delays the plus signs are not recognized as the beginning of acommand code. If you've had trouble getting macros to work with your modem, this is probably why, Simply add one-second delays before and after the plus signs in your macros and they should begin to work. Which revision A? ‘The manual that came with my Ile says | must have a revision B or later motherboard in order to use double high-res graphics, Buta knowledgeable friend says ifan “enhanced’” sticker was on my Ile, | can use double high-res, What's the straight dope? Also, is there any software for the Ife that uses double high- res? David A. Bixler ‘St. Louis, MO Apple's inability to count past “B” on its lle motherboard designations has confused lots of people. There are actually two vintages of lle moth- erboards that have an “A” following their serial number, The original revision A motherboard, which was not able to handle double high-res graphics, was confined to Apple Iles builtin early 1983; any He you buy now should be capable of double high-res unless you buy a very old used one that was never upgraded. The new revision A board, which can handle double high-res just fine, can be easily identified—most of the chips are soldered directly to the board rather than being placed in sockets. The presence of an “enhanced” sticker doesn’t necessarily mean you can do double high-res—a 1985-vintage revision A motherboard can be “enhanced” and the Apple Ile Enhancement Kit includes the sticker. Enhanced Iles that can't do double high-res are probably very rare, however. Double high-res graphics software is indeed avail- able; popular examples are Beagle Graphics from you-know-who and Dazzle Draw from Broderbund Software. ligs altemate display mode I went down to my local computer store with a couple of my own disks and used the new Apple IIgs. Guess what? It runs APPLEVISION without a hitch! (See Open-Apple, July 1985, page 50.) Granted, it worked better in the “normal” mode (in “fast” the song sounded like a 33 record played at 45 rpm), but itstill ran. One thing puzzles me, though: what is the “alternate display mode" that shows up on the IIgs control panel? | asked the salespeople at two stores, and no one seems to know. Eric Patterson Medford, OR “Alternate Display Mode’ is one of two ROM-based “desk accessory” programs on the ligs; the other is the control panel itself. Selecting the alternate display mode allows the Ilgs to display data from text page 2, which is unsupported by the Apple ligs hardware. So you can understand why, I'll have to explain a little about how the ligs works. We've talked several times in the past about the Apple II's “memory- ‘mapped I/O.’ This means that all the data that moves into or out of the computer passes through what appears to the microprocessor to be standard memory cells, For example, in the standard Apple Il, what appears on your monitor's text display is a reflection of data held in the memory area from $400 to $7FF. When you move the cursor across the AppleWorks screen, what is really happening inside your computer is that the applications software and operating system software are working together to change the values in this memory area so that what appears to be a cursor will appear to move. The Apple I! video generation hardware accesses memory in lock step with the microprocessor. Each gets its turn once every millionth of a second. Consequently, the timing of the video generation hardware and of the microprocessor are tied together. When the ligs was designed, the engineers wanted to let the microprocessor run faster while allowing the video generation hardware to continue to run at the old speed. To accomplish this, they split up the 256K of RAM that's built into the ligs into “fast RAM” and “slow RAM.” The slow RAM is the built-in RAM in banks $E0 and $E1. The fast RAM is in banks $00 through $7F (only $00 and $01 are built-in). Vol. 2, No. 11 Before anything can appear on the Ilgs screen, it must be stored in the proper place somewhere in bank $E0 or $EL However, programs written before the ligs appeared don't know anything about banks $E0 and $E1 They are loaded into and run in banks $00 and $01 In order to get the data that APPLEVISION and AppleWorks store in banks $00 and $01 to appear on the screen, Apple's engineers gave the IIgs the powerto “shadow anything written into the display-page areas of banks $00 and $01 into the equivalent position in banks $E0 and $E1. So, programs run in fast RAM while the video circuitry works like it always did in slow RAM. The ligs hardware automatically takes care of moving stuff from fast RAM to slow RAM for older nor-ligs ‘Software, while software written specifically for the igs will turn shadowing off, use bank $00 as prime real estate rather than as graphics pages, and use banks $E0 and $E1 for all 1/0. However, when accessing banks $EO and $E1, the ligs microprocessor has to slow down to match the pace of the video circuitry. The only hitch with all this is that the engineers didn'tinclude “text page 2” in the shadowing scheme because they didn’t think it had been used enough to become a compatibility issue. Text page 2 is the memory area from $800 to $BFF. It has always been available in terms of the Apple hardware, but Apple I operating systems have never supported it. After the hardware design of the ligs display modes had been locked in, however, several significant Integer Basic Apple Il programs that used the page 2 display were found to be incompatible with the ligs. To make them compatible, Apple's software engi- neers added “alternate display mode” as a desk accessory. When you turn on alternate display mode, ithooks itself into the IIgs “heartbeat interrupt.” At each heartbeat, alternate display mode quickly copies everything in the text page 2area in bank $00 to bank $EO. This solution allowed Apple to transpar- ently support text page 2 without having to re-design the igs hardware, For an comparison of the two modes, run the old Integer Basic program THE INFINITE NUMBER OF MONKEYS with and without alternate display mode enabled. RamFactor as hard disk You've mentioned Applied Engineering RamFactor card several times but never in much detail. The possibilities this card offered were too great to pass up. I got one with 1 megabyte of RAM and the battery backup to preserve the card's memory when the computer is off. The battery backup, by the way, was back ordered for the better part of 2 months. | thought you and your readers might like some first- hand impressions of this device. In a word—it's fantastic! The reviews of tin magazines have mostly emphas- ized it as a memory card for use with AppleWorks on an Apple Il-Plus. But RamFactor is more than that— in fact, | have a Ile that already had a RamWorks card installed. By putting RamFactor in slot 7 it became the device that boots when | tum my computer on. | have configured it as a RAMdisk containing ProDOS, Apple Writer, SuperCalc, Filing System, and various utilities. It boots instantly, then one Keypress gets me into any application within one or two seconds—no. waiting, no searching for the right disk. Changing applications is just as fast (open-apple/control/reset plus one keypress): from SuperCalc to Apple Writer takes three seconds total. The battery backup normally provides power to the December 1986 card from house current but switches to battery should house current fail. This feature works, by the way; we lost power for a few minutes a week ago and * the battery preserved every bit on the card. Should the card be erased for some reason, it can be reformatted and loaded in less than halfan hour with help from a good file copier (I use both FILE.MOVER from Beagle Bros Big Uand Copy Il Plus). | don’t use the card to store valuable data but this isn’t a drawback for someone who has lots of little files on floppies rather than a few big ones. In fact, the only drawback to this great conveniences the price tag— $440 for the whole setup, cheaper than a hard disk butnot cheap. Robert H. Holdsworth Wilbraham, Mass. Ive been using one of Apple's memory cards just as you describe for several weeks. I'd rather have a RamFactor—Apple’s card won't boot, doesn’t have a battery backup option (Ijust leave that computer on all the time — it's connected toa $250 uninterruptable power supply), and can’t be partitioned for various operating systems. I used the BACKUP program on Glen Bredon’s ProSel package to save the contents ofthe RAMdisk onto 3.5 inch disks after I loaded it the first time. When I have to tum the computer off for some reason | can reload the RAMdisk with Bredon’s RESTORE inless than 3 minutes. A buffer in headache Here is one that has had me climbing the walls for days. Enclosed is a program was intended to show how to direct output to the printer and return to the screen. Imagine my dismay when it didn’t work! As shown, the program will only activate the printer when the stars are aligned correctly or some other esoteric criteriaare met. When hard-copy is requested, you probably won't get it. It works just fine, however, if you change line 190 from: 190 PRINT X(Q);7 “4 to 190 PRINT x(Q) Using the Applesoft TRACE command even shows the line is being executed, but it doesn't activate the printer, (Well, usually doesn’t activate the printer.) Obviously, this isn’t how I intended it to work. There is no major problem with the program printing the values on new lines rather than the same one, but I _Justdon’t understand why it does (or doesn't) do what itdoes or doesn’t do. Dwayne C. Smith Noadron, Let. This one stumped me, but Dennis finally figured it out. The problem sequence is: 180 PRINT DS; “PRE” 185 FOR Q = 1 to A 190 PRINT X(Q);7 “3 200 NEXT Q 205 PRINT DS; “PRHO™ As you know, the semicolon at the end of line 190 ‘Suppresses a carriage retum each time through the loop. As it tums out, however, you never send a carriage return to the printer within your loop; then you terminate the printout with PR*0. Most of todays printers contain at least a small internal RAM buffer that receives characters and stores them. This is so that the printer can receive characters at a constant rate but print them in spurts (one line at a time, followed by a delay while the print head repositions itself). We suspect your printer is set up so that the contents of the buffer aren't printed until a carriage retum is received; this is a common configuration. If you send less than a bufferull of data to a printer without using a carriage return, nothing will appear to happen. But the data will be in there, ready to spoil the page of the next person who sits downat the computer and tries to print something — or to really fool you by printing out if you run the program asecond time (the return at the end of PR#1 will trigger it). With some printers, including Apple's, Pressing the select switch will also cause the contents Of the buffer to be printed. Add the following line to your program: 203 PRINT This will terminate the print out with a hard carriage return. If that doesn’t solve your problem, let us know and we'll give you Nibbie’s phone number. | write to you on behalf of CondiCom and your many readers who use Apple Writerand are not aware of CondiCom’s gem ofa utility called OpenApplewtiter, which was mentioned in a letter in Open-Apple last September (page 71). Instant Apple Writer on the Sider is a joy to behold. The gentleman at CondiCom had the uncommon courtesy to find my telephone number and call long distance to verify my particular hardware before shipping my order. Within half an hour of its arrival, Apple Writer was enhanced and tucked away deep inside my Sider. The documentation is like Open-Apple, sparse but potent. Peter Walmsley Fort Lauderdale, Fla. OpenAppleWriter is $59 for the DOS 3.5 version, $29 for the ProDOS version, $49 for both from CondiCom, 436 Berry Drive, Naperville, IL 60540 512-357-0274. RAM Van Lines How can I load large (>128K) programs into RAM disk automatically upon start-up? Marc Odin Minneapolis, Minn, It depends on which operating system you are using. For ProDOS, aBASIC.COPY program was published in Open-Apple in July 1985 (pages 50-52), with an important addition and correction in the October 1985 issue (pages 74-76). Its whole reason for-being was to demonstrate how to easily copy very large files. Most RAM cards come with asimilar program— look on the utility disk that came with your card— however, some of these may not handle large files. Another ProDOS alternative—the one we use around here —is to use the disk backup and restore utilities in Glen Bredon’s ProSel package ($40, 521 State Road, Princeton, NJ 08540). They allow you to backup the contents of a RAMdisk into a file, which can then be kept on one of your disks. The RAMdisk can be automatically restored from that file at Open-Apple 2.87 startup, or you can make restoration a manual procedure, For DOS3.3 the easiest way to proceed is to use an EXEC file with FID. The following EXEC file, for ‘example, will copy all the files on the boot disk in slot 6 to a RAM disk in slot 4, drive 1: BRUN FID 1 x9 Your boot disk must include both the EXEC file and FiDitself. If youname the EXEC file COPY TO RAM and you have room for a short HELLO program, the following will get all this to work automatically: 10 REM you may need to BRIN a program to turn 20 REN your menary card into a RAMdisk here 30 PRINT CHRS(4);“EXEC COPY TO RAN” 40 END The EXEC file BRUNs FID, enters a1" when FID's function menu appears (the "COPY FILES” option), enters slot 6, drive 1 for the source drive and slot 4, drive 1 for the target. The next prompt is for the filename; we enter an equals sign to indicate we want all files, followed by a “N” to indicate we do not want prompting after each filename. The two “X's in “XX9” start and end the copy (each "X” responding to FID’s request for a keypress to continue). The "9" takes us out of FID via menu option 9. For either DOS or ProDOS you might want to add commands to check for the RAM card and see if it already contains the files before you copy them. This would happen, for example, if you had to reboot your computer but hadn‘t turned tt off. Dennis says that for CP/M there are SUBMIT and XSUB commands that can be used to issue commands ‘similar to the EXEC command, SUBMIT allows you to enter CP/M system commands, while XSUB extends the ability to allow input into programs themselves. You can use these in conjunction with PIP to copy files. For example, a SUBMIT file containing the command PIPC:=A:’." would copyall files from drive A: to C;, using the “*.*” wildcard to represent all filenames. Some CP/M versions allow you to installa file to AUTORUN after CP/M boots; if your system has this feature and you can install the SUBMIT file you can automate the whole procedure. If there’s an easy way to load large files into a RAMdisk automatically from Apple Pascal, we don’t know what itis. NTSC and PAL Apples I would like to Know what are the differences between an American (NTSC) Apple Ile and a European (PAL) Apple. Could you please list out the differences? Tai Fan Li Kuala Lumpur, Malaysia Jim Sather has described the circuitry differences between the two Apples in his book Understanding the Apple Ile, published by Brady Communications of Bowie, MD. On pages 8-16 through 8-19 he describes them —they primarily involve video scan- ning and video signal generation —in great detall. ‘According to Sather, “if not for television system incompatibility, the Apple He could be made to operate in any country by installing a power supply that would operate from the line voltage of that 2.88 — Open-Apple country. Supporting the special text requirements of the various languages is no problem because you can simply plug in a keyboard ROM and video ROM for any language....The PAL circuitry is nearly identical to the circuitry of the Apple I Eurocolor card, so basically an Apple Ile PAL motherboard is an American motherboard with a 14.25 MHz oscillator (14.51818 MHz is standard on NTSC Apple Ils), a 50 Hz OU (60 Hz on NTSC), foreign language video and keyboard ROMS, and a built-in Eurocolor card.” ‘One factor Sather doesn't explain in detail is the difference in the component and slot layouts between the two motherboards. The two are not the same. Devices that plug into the motherboard of one flavor of lle or that use jumpers to motherboard components are unlikely to work with the other flavor. One Problem frequently mentioned in Apple User (the only European Apple magazine published in a lan- guage I can read) is that slot 3 and the auxiliary slot lie end-to-end on the PAL motherboard, consequently they can't both be used at the same time. RAM found in accelerators EJ, Martin's letter in your November issue (page 2.76) brings up an interesting point about accelerator cards. ‘These cards use fast-access RAM (150ns or faster) chips that can be accessed at 3 MHz plus, rather than at the standard 1023 Mlz that the motherboard RAM iswritten, ected, published, and © Copyri ht 1986 by ishaar SS cote Richard Barger Technical Consultant + Dennis Doms Circulation Manager —_Sally Tally Most rights reserved. Al programs pubished in Open-Apple are pec dona and may Be coped ana ctbute whan enaige {stare avatabeinthe MAUG lnraiyon CompuServe) Aope user he inpemieeen oop aria an ime 0 sme Dy specie wen equest Requests and cet editorial material, nluding lterso Unce DOS, shoud be sen -Apple x 7651 Overland Park, Kansas 66207 U.S.A. 11885-4017, bene ory ses Januar 185, Na de press in US dolar. arral dle 3 no tora Share| $24 tear $f 2 ors Sor yours ask eates ate curtenyavaldbe lr $2 each, abound, nderededion i S099 indexed wih Feary om, send a sxbseiptonrltdeorespendee Cre Syracuse, N.Y. 13217 U.S.A. Satu maaan Zenndsoecsterin cones ar ie Fos Baa Ve St AUstoae pers aalebieondklorepest sreszerusrs om sgebnterpaes PO Bon 986 Pov, eae OTOUTIS a ‘Es Unlike most commerical sotware, Open-Appte i sokt in an unprotected format for your comment. You are encourgaged 0 ‘make back-up Cara ‘easy oe enlarged copes for ur own use without charge. You may 880 copy Open Apple for Sas anes The srtnon ee 15cene per age pr copy ii WARRANTY AND LIMITATION OF LIABILITY. warrant that most of the formation in Open-Apple is uselu and core athough vel fd motes me eet fre bet me usualy attest Unsatisited subscribers may return ssues win 180dayso oeWvery fafa eed Base rie a or yoo cher <onfrg at alarcvalcneshawe ben dstoyes Then potion of any pa wil UABILTY FOR ERRORS AND PUBLICATIONS PURCHASE PRICE. In no case shall | or my Corus be late any nina consequat gamace, ro fr any damages in excess ofthe ees pad by a subse pon ppleissner fan wh or operate be Os ‘Apple Computer. Inc. “tnaja questing” 1s a trademark of Don Lancaster Source Mai: TCF238 CompuServe: 70120,202 can handle. The 80K accelerator Martin mentions has 48K to replace the motherboard memory, 16K for the language card, and 12K for a copy of what's in the motherboard ROMs. 4K is wasted simply because it’s easier and less expensive to put 80K of RAM on the board than 76K. However, Applied Engineering's TransWarp acceler- ator takes a different approach. It has 256K of RAM split between the 76K mentioned above and 64K used to accelerate Apple Ile auxiliary memory. This allows programs running in auxiliary memory to be accelerated. What isn’t documented is that some of the extra memory can be accessed as a RAM card. On an old Apple Ii or on a Il-Plus the 64K of auxiliary memory can be used! There are a couple of limitations—neither 80-columns nor double high- tes are added, since that circuitry doesn’t exist on these machines. In addition, most programs, induding ProDOS, do not e that the memory is there, since the signature bytes indicate that the machine is not an Apple Ile. Nevertheless, with programs that check to see if the memory is available, or with programs that can be fooled into thinking they are runningon a Apple lle, that memory can be accessed. For example, try a DOS 3.3 RAMdrive program that is designed to work with an extended 80-column card. Many will work on a II-Plus with a TransWarp. From the other point of view, fyou pluga TransWarp into an Apple Ile, then it will still have the 16K RAM card normally used for the II-Plus mode. Many pro- grams will access extra 16K RAM cards. Ifyoutell such Programs that you have a 16K card installed in the ‘TransWarp slot it will find and use it. Philip Chien Earth News Titusville, Fla. Some benchmarks Iam considering upgrading to a llgs, but | have some questions that ! hope you can answer, First of all, lwas originally considering a Macintosh, but since the IIgs has arrived | can’t make up my mind because of compatibility issues. Compatibility with the lle and IIcis no problem, but I'm interested in Mac compati- bility. | know that the Macintosh and the Ilgs are not software compatible, only hardware compatible. However, how identical is the IIgs 128K ROM with the 128K Mac ROM? Specifically, are the QuickDraw, math and other routines 100 per cent compatible on a functional level? As an example, can a Macintosh MicroSoft Basic program that calls QuickDraw routines be simply downloaded from a BBS and run ona ligs? By the way, have you run any benchmarks comparing the Iigs to the Ile or Mac Plus? Speed was one of the reasons why I considered dumping my Ile system for a Macintosh Plus, or even (gasp!) an IBM PC. J.M. Maing Honolulu, Hawaii Although the user interface shown in most figs demosis similar to the Macintosh, there is almost no other area of compatibility. The peripheral interface ports (disk ports, serial ports, desktop bus for the keyboard) are similar to what the Macintosh has (or is about to get) but only because Apple wants the ‘two computers to use.a common family of peripherals, Internally, the IIgs and Mac are nowhere near the same, This includes “ROM compatibility’. The design philosophy of the ligs ROMs is similar to the Mac's, but the actual routines are not the same. Afterall, the computers use different processors (68000 series forthe Mac, 65816 for the ligs) and the hardware that Vol. 2, No. 11 must be manipulated by the ROM-based firmware is different. The ROM routines are accessed as “tools” through a single entry point in each machine's ROM. Many of the tools have the same names and functions, but the exact nature of each call isn’t necessarily the same because of the differences between the machines. The ligs version of QuickDraw (QuickDraw 1), for example, is scaled for the pixel dimensions of the ligs display and must support color. Apple's engineers are working on some utilities to allow translating things such as graphics, fonts, and files between the two machines, but | will be surprised if we ever see any kind of compatibility at a program level. The folks who developed Apple's SANE packages Say that, based ona sieve of Eratosthenes benchmark involving SANE on the ligs and Mac, the ligs runs at about half the speed of the Mac. Since the 65816 has no multiply/divide instructions like the 68000, the SANE benchmark may be a worst-case (for the llgs) comparison between the two machines. The Apple II family shines, on the other hand, in the standard benchmark tests used by Byte magazine (see the June 1984 issue, page 327, and the October 1984 issue, page 33). Dennis and | ran Byte’s benchmarks onaile, allgs, anda lle witha TransWarp accelerator and found the latter two to be comparable to an IBM-PC/AT or to a Macintosh-Plus, As with all benchmarks, use care in forming opinions based on these numbers—in particular, they may say more about the Basics used than about the machines themselves (Applesoft on the II family, BASICA on the IBM, Microsoft Basic 10 on the Macintosh). On the Apple Ils, the disk read and write tests didn’t change with computer speed, but the type of disk drive used did make a big difference, so we've reported those numbers that way. ProDOS was used for the disk tests, The comparison data for the IBM PC and PC/AT were taken from Byte, May 1985, page 274; for the Macintosh and Macintosh Plus from November 1986, page 248, The benchmark programs use single- precision arithmetic—this means 5-byte precision for Applesoft versus 4-byte precision for the MicroSoft interpreters on the other machines. Byte magazine benchmarks, In seconds calc sieve rite Me 7 (245 - Tgs 35 96 - Tle+Transkarp 30 cy - - IT + 5.25 drive -- Dp II + Uni 3.5 % 2 TL + RAdisk = - 3 5 TBH-PC 63 1st 546 TpH-PC AT 2 60 B24 Macintosh 7 18 crt) Macintosh-Plus 79 36 Ears) As you can see, with these benchmarks the ligs and the accelerated le compare very favorably with the 6 MHz IBM PC/AT (for a lot tess money) and blow away the others, though the Macintosh appears to have faster drives. The tests don't take into account the use ofamath coprocessor for the IBM computers, which would give them a decided advantage if the language the benchmark was written in used the coprocessor (the standard interpreted Microsoft Basic used for these tests does not). On the other hand, a Basic uritten to take full advantage of 65816 chip on the ligs (there isn’t one at the moment) ‘should execute faster than Applesoft.
mp.ls