TweetFollow Us on Twitter

Mac II, SE
Volume Number:3
Issue Number:5
Column Tag:Macintosh II

Programming the New Macs

By Sue Goodin, Apple Computer & Dave Wilson, Personal Concepts

Sue Goodin is a Technical Communications Engineer for Apple Computer. Dave Wilson is President of Personal Concepts, a consulting firm specializing in training courses for the Macintosh. He is currently teaching Apple's MacApp programming course. In this article, Sue and Dave review the new Apple product offerings and the new ROM calls behind the new features.

Figure 1 summarizes the latest results of Apple's increased R & D spending, and certainly indicates that the folks in Cupertino have been busy. In this article, we want to review and preview information about some of these new products, emphasizing details of interest to programmers. Apple's new computers represent new market opportunities, and new programming challenges, so we should discuss both areas.

The evolutionary Macintosh SE should be an even more popular machine than the successful Macintosh Plus, since it offers somewhat better performance and an expansion slot for adding a peripheral board. Its 256K ROM offers some new features, as discussed below, but is primarily focused at retaining compatibility with present Macintosh software, so there are no earthshaking changes for programmers to worry about.

The revolutionary Macintosh II, on the other hand, is a very well-designed and powerful machine that will open up completely new markets and opportunities for us all. The only catch is that the Macintosh II is even more sophisticated and complicated than earlier Macintoshes, so we have a lot more to learn before our software can really shine. Will our present programs work on the II? They should. Apple believes that more than 2/3 of the present software will run unchanged, and almost all software that follows the compatibility guidelines should work fine.

The Macintosh SE

The Macintosh SE (stands for System Expansion) still has an 8 MHz 68000, but has new 256K ROMs, and one expansion slot. It has the standard built-in 9-inch monochrome monitor, but you can, of course, add other monitors using the expansion port. You can put up to 4 MB of RAM in an SE.

A tricky point is that both the Macintosh SE and the Macintosh II have 256K ROMs, but they are not the same. The Macintosh II's ROM has Color QuickDraw and other goodies that are not in the SE. The SE was designed for software compatibility, and over 90% of existing applications should run on it. The Macintosh II is less compatible, with over 60% of the software running unchanged. Macintosh II ROMs are complete, and its system software is in the final testing stages, while the SEs are in the stores now.

The SE provides somewhat improved performance over the Macintosh Plus, as we shall see. Apple still intends to sell both the Macintosh Plus and the 512K Enhanced, because they provide a lower-priced entry point in the product line.

The Macintosh II

Overview

The Macintosh II offers a 68020 microprocessor with a 68881 floating point coprocessor, 1M or more of RAM, and 6 NuBus expansion slots. The Macintosh II supports color and gray-scale display, and has four-voice sound capability. The Macintosh II includes:

• 68020 microprocessor, clocked at 16 MHz

• 68881 floating point coprocessor (always there - not an option)

• 1M RAM (expandable to 2, 5, or 8M on the logic board)

• 256K ROM

• 6 NuBus slots

• general memory management unit (or optional 68851 PMMU)

• Two Apple Desktop Bus (ADB) ports for the mouse, keyboard, tablets, etc.

• One or two internal 800K floppy drives

• Room for a 20, 40, or 80M internal SCSI hard disk

The Motorola 68020 microprocessor has a 32-bit data bus, which can speed up Macintosh Plus software by a factor of 4. Other properties of the 68020 add to that speed advantage, and with the inclusion of the 68881 floating-point coprocessor, certain types of Macintosh code may now run as much as 200 times faster on the Macintosh II than on existing members of the Macintosh family.

The ROM in the Macintosh II has been completely rewritten, and now includes Color Quickdraw, which supports the definition of as many as 248 colors (about 200 trillion). The Macintosh II Video Card with its Expansion Kit can display 256 colors (or shades of gray) on the screen at once.

The six NuBus slots provide a flexible means of expanding the architecture for such products as processor cards, video output, non-Apple Desktop Bus input devices, storage devices, and network cards.

NuBus, Texas Instruments' synchronous bus definition, allows any device to become master of the system. Therefore, 80286 cards, EtherNet cards, and other intelligent interfaces may, at times, gain control of the CPU. With this architecture, the Macintosh II could run MS-DOS software, act as a smart terminal, or drive a variety of output devices. Apple's NuBus implementation includes interrupt lines from each of the slots, and has changed the size of the interface card to conform to the Macintosh II case size.

The addition of 4-voice sound is also supported by the Macintosh II hardware. The firmware now contains synthesizers for MIDI, note, wave table, and sampled sound production.

Hardware

Although a number of the external ports on the Macintosh II are similar to those on previous Apple equipment, the logic board of this computer is significantly different than other members of the Macintosh family.

Memory management chores are handled by a general memory management unit, which allows the 68020 to devote its processing time to other tasks. A paged memory management unit (PMMU), the Motorola 68851, is available to support paged virtual memory management, and is required to run Apple A/UX, Apple's version of the UNIX operating system.

Eight SIMM sockets, organized into two groups, provide a starting configuration of 1M memory. Apple will offer RAM upgrades to increase available memory on the Macintosh II to 8M. As SIMM technology advances, the Macintosh II will be able to take advantage of up to 128M RAM on the logic board.

The 256K Macintosh II ROM has been written to support all of the previously mentioned devices and features. The ROM also includes all packages available on the Macintosh Plus. The following features are among those that have been added to the ROM:

• Color Quickdraw, and color support in other Managers

• Apple Desktop Bus support

• More fonts - Monaco 9, Chicago 12, Geneva 9 and 12

• Slot Manager to handle NuBus card communication

• 4 Voice Sound Manager

• SCSI Driver

The Macintosh II has two lithium batteries, with a lifetime rated at 7 years, soldered on the logic board. These replace the removable dry cell battery found on earlier Macintosh computers. If your program crashes and writes garbage into Parameter RAM, you may have up to seven years of bad luck, so be sure to write perfect programs! Actually, Macintosh II users may continue to use ParmBlaster -type programs to erase parameter RAM, should it become irretrievably corrupted.

Six Macintosh II slots follow Texas Instruments' NuBus standard, with Apple modifications. The NuBus definition allows any NuBus device (of which the 68020 is one) to become the "system master". With its open architecture, the Macintosh II will encourage developers to sell processor cards, graphic interfaces, memory devices, and drive interface cards.

One of the NuBus slots will normally be used by a video card, since the Macintosh II does not contain video signals on the logic board. Apple has a Macintosh II Video Card available for use with the Apple High Resolution Monochrome Monitor and the AppleColor High Resolution RGB Monitor. The card's factory-installed memory can allocate up to 4 bits per pixel, for a maximum display of 16 colors or shades of gray. With the optional 8-Bit Expansion Kit, as many as 256 colors and gray-scales may be shown.

Macintosh II Video Card

The Macintosh II graphics plug-in video card provides color capability for simultaneous display of up to 256 colors on the Apple High Resolution Color Monitor. This capability is further enhanced by its three 8 bit digital to analog converters (RGB) providing more than 16 million possible colors to choose from. Color modes range from one bit per pixel (2 colors) to an optional eight bits per pixel (256 colors).

On the same card, using the Macintosh II control panel desk accessory options, you may select true grey scaling. With the Macintosh II Video Card , the grey shading is intensified or diminished by hue and brightness values. The user no longer has to rely on the spaced dot patterns of previous grey schemes. When grey scaling is selected from the control panel, each of the presently available colors is translated into a shade of grey.

PMMU

A Motorola MC68851 co-processor is used by the Macintosh II to implement paged memory management. This chip replaces the standard memory management chip in the Macintosh II, and is used by systems programmers to implement advanced and multi-user operating systems, like Apple's A/UX. While the standard MMU simply offers two modes of translation (a 32 to 24 bit mode for software compatibility with programs for older Macintoshes, and a straight-through 32 bit mode), the PMMU offers such features as:

• 32 bit logical to physical address translation with 4-bit function codes.

• memory protection by access level and access type.

• hardware maintenance of address translation, and address translation cache (ATC).

• 16 extensions to the 68000 family that provide control for:

- loading and storing of MMU registers.

- testing access rights, and conditionals based on the results of this test.

- MMU control functions.

Expansion through NuBus

The 68020 communicates through the memory management unit with each of the six synchronous NuBus slots through a full 32-bit address/data transfer between each slot and the 68020. Each slot is identified to the microprocessor by 4 ID lines, which the bus master uses to determine the source of the communication. Power, timing, and acknowledge lines are also implemented. Apple has changed Texas Instruments' NuBus definition by adding an interrupt line from each slot, so that each card can generate an interrupt to the on-board logic.

The 32-bit address space (equating to 4G bytes) available for all NuBus slots is partitioned to provide space for each slot. First, the top 256M of address space is divided into 16 "slots". This allows each physical slot to "own" 16M, which is referred to as its Slot Space. Each NuBus slot is also allocated 256M (although it may request more!) of "SuperSlot Space" from the portion of memory remaining in the 4G of address space.

Each NuBus card should contain a configuration ROM mapped to the top of its Slot Space. This ROM provides information so the Macintosh II operating system can identify the card at startup time. The Macintosh II looks at the ROM to determine the type of card, how it is to be accessed, and its slot resource data.

Pre-defined NuBus card categories include display, network, terminal emulator, serial, parallel, intelligent bus, and human input devices. Each category is further defined by a type indicator. For example, the network category is subdivided into AppleTalk, EtherNet, TokenRing, etc. With this information, slot drivers can then locate any appropriate card by checking these bytes in configuration ROM on each card.

NuBus cards may be designed to be "masters" of the bus, or as slaves only. A master card must be able to initiate bus transfers of 8, 16, or 32 bits, and must be able to arbitrate requests for bus mastership. It may have the ability to lock the bus from access by other NuBus devices for a specified period of time. A slave card responds to requests, but can only send a "non-master request", and need not support the full 32-bit transfer.

Keyboards

Two new keyboards were announced that each hook up to the Apple Desktop Bus, along with the mouse. The larger one will look quite friendly to those of you who sell to the IBM world, with 15 function keys that you can have your program interpret in any way that you wish. The keyboard has an output for other ADB devices, so the mouse can be connnected directly to the keyboard (on either side).

The ROM

New Managers in the ROM

The Macintosh II ROM features have been greatly extended from those found in the Macintosh Plus. A number of new managers have been added to the ROM, and most existing managers have been modified to support the new hardware capabilities of the Macintosh II.

The modifications most frequently introduced involve color support - QuickDraw, menus, dialog boxes, and TextEdit are among those items that have been extended with color features. The NuBus slots are also a prime candidate for causing additions and changes. The Macintosh II introduces a Slot Manager, an Operating System Utilities Manager, and the Deferred Task Manager to support Apple's NuBus implemen-tation.

Other managers have been rewritten to remove previous limitations: the Macintosh II is an open machine, so the ROM designers have made every effort to permit developers the freedom to design products for the Macintosh II without being concerned with ROM limitations.

We'll list information about some of the new managers, in roughly alphabetical order. In some cases we include descriptions of new data structures and ROM calls, but you should remember that these are preliminary specs. A.P.D.A. should now be shipping a draft of Inside Macintosh Volume V to provide all the hairy details.

Apple DeskTop Bus Manager

The Apple Desktop Bus was introduced with the Apple IIGS last fall. Apple is now implementing the same technology on the Macintosh SE and Macintosh II. Apple Desktop Bus provides a low-cost, simple local bus network used by low speed input devices, such as keyboards and mice. The ADB can control as many as 16 devices on its network, each of which is identified to the ADB controller by a unique identifier. The CPU can issue commands to the network at large, or to a particular device on the bus. Four ADB commands are supported:

• Reset Forces a hardware reset of ADB devices.

• Flush Initializes the addressed ADB device.

• Talk Requests information from ADB device.

• Listen Sends an instruction from the CPU to ADB device.

Color Capabilities

The Macintosh II supports both QuickDraw color, as implemented in Macintosh Plus ROMs, and a new Color QuickDraw, as defined in the sections below.

"Classic" QuickDraw color was designed to conform to a planar model, where each of the bits used to describe a color turns a particular color plane on or off. QuickDraw used this technique to define eight standard colors, each with a unique bit pattern, to be used as the foreground or background color of a GrafPort, in RGB display, or in color printing. If you write programs using classic QuickDraw, they will run perfectly well in black and white on a Macintosh Plus or SE, but will appear in color on the Macintosh II.

The new Color QuickDraw uses an absolute approach to determine color representation. A new data type, RGBColor, is defined to be a record containing three 16-bit integers, each of which represents an intensity value for one of the three additive primary colors red, green, and blue.

TYPE
 RGBColor = RECORD
 red:   INTEGER; {Red component}
 green: INTEGER; {Green component}
 blue:  INTEGER; {Blue component}
 END;

Under Color QuickDraw, the application need not be concerned with the type of output device. The application specifies a color in RGBColor format, but the Color Manager then uses information from the display device's driver to translate the RGBColor definition into the best available match on the output device. Some output devices may be limited to 8 or 16 colors; others use a lookup table to select from a wide range of possible display colors. In any event, the Color Manager handles these details independently of Color QuickDraw or the application.

On the Macintosh II, the user may choose the depth to which the screen image should be displayed, up to the limits of the video hardware, by using the Control Panel desk accessory. This permits the customer to choose a display that is consistent with the type of program. A word processing application may need only black and white, and a greater selection of colors (i.e., greater depth) would only slow down the application. On the other hand, drawing and charting applications benefit from the ability to use more colors, so the user might choose to use a greater pixel depth.

Pixel depth must be a power of 2. A display of 4 bits per pixel permits each pixel to choose from among 16 colors, while 8 bits per pixel allows a selection of 256 colors. Normally, the device will implement these choices through a color lookup table controlled by the Color Manager.

Color QuickDraw

Color QuickDraw includes the same types of procedures and calls found in "old" QuickDraw, but it has expanded to support color on the Macintosh II in GrafPorts, pixel maps, icons, polygons, and cursors.

A new data type, the CGrafPort, is analogous to a GrafPort, but it replaces pattern and map information with handles to a PixMap, pnPixPat, bkPixPat, and pnFillPat. The resulting free bytes have been used to add RGBColor records for the foreground and background of the port.

CGrafPort = record device : integer; (Device ID font select)
 portPix: PixMapHandle  (Port's pixel map)
 portVersion: integer;  (Color QuickDraw ver. no.)
 cgRsrv1: longint; (Reserved)
 cgRsrv2: longint; (Reserved)
 portRect : Rect;(Port Rectangle)
 visRgn : RgnHandle; (Visible region)
 clipRgn: RgnHandle; (Clip region)
 bkPixPat : PixPatHandle; (Background Pattern)
 rgbFgColor : RGBColor; (request foreground color)
 rgbBkColor : RGBColor; (request background color)
 pnLoc  : Point; (Pen location)
 pnSize : Point; (Pen Size)
 pnMode : Integer; (Pen Transfer Mode)
 pnPixPat : PixPatHandle  (Pen pattern)
 pnFillPat: PixPatHandle  (Fill pattern)
 pnVis  : integer; (Pen Visibility)
 txFont : integer; (Font number for text)
 txFace : Style; (Text's character style)
 txMode : integer; (Text's transfer mode)
 txSize : integer; (Font size for text)
 spExtra: fixed; (Extra Space)
 fgColor: longint; (Actual foreground color)
 bkColor: longint; (Actual background color)
 colrBit: integer; (Plane being drawn)
 patStretch : integer;  (Used internally)
 picSave: Handle;(Picture being saved)
 rgnSave: Handle;(Region being saved)
 polySave : Handle;(Polygon being saved)
 grafProcs: QDProcPtr;  (Low-Level draw routines)
         END;

Here are some of the new calls for setting colors:

PROCEDURE RGBForeColor (color: RGBColor);    $AA14;
PROCEDURE RGBBackColor (color: RGBColor);    $AA15;
PROCEDURE SetCPixel (h,v: INTEGER; cPix: ColorSpec);     $AA16;
FUNCTION  GetCPixel (h,v: INTEGER): ColorSpec;     $AA17;
PROCEDURE GetForeColor (VAR color: RGBColor);      $AA19;
PROCEDURE GetBackColor (VAR color: RGBColor);      $AA1A;

Color cursors and color icons are implemented through two new data structures, CCrsr and CIcon. Both structures remove size limitations from items by using handles to the actual data, rather than keeping data within the structure itself. Both cursors and icons access a pixmap, which allows the use of color at a depth of the user's choosing.

All drawing by Color QuickDraw is done in a pixel map, which is analogous to the bitMap of old. New fields have been added to track the horizontal and vertical resolution in pixels per inch, the number of bits per pixel, and the handle to the pixel map's color table.

PixMap = record
 baseAddr : Ptr; (Pointer to pixel image)
 rowBytes : integer; (Offset to next row)
 bounds : Rect;  (Boundary Rectangle)
 pmVersion  : integer;  (Color QuickDraw version number)
 packType : integer; (Packing format)
 packSize : longint; (Size of data in packed state)
 hRes   : fixed; (Horizontal Resolution)
 vRes : fixed; (Vertical Resolution)
 pixelType  : integer;  (Format of pixel image)
 pixelSize  : integer;  (Physical bits per pixel)
 cmpCount : integer; (Logical Components per pixel)
 cmpSize  : integer; (Logical bits per component)
 planeBytes : longint;  (Offset to next plane)
 pmTable  : CTabHandle; (Absolute colors for image)
 pmReserved : longint;  (Reserved for future expansion)
    END;

Here are two routines for handling PixMaps:

PROCEDURE CopyPix (srcPix,dstPix: PixMap; srcRect,dstRect: Rect; mode: 
INTEGER; maskRgn: RgnHandle);        $A8EC;
PROCEDURE CopyCMask (srcPix: PixMap; maskBits: BitMap; dstPix: PixMap; 
srcRect,maskRect,dstRect: Rect);         $A817;

Color QuickDraw includes color patterns. It provides an undefined limit to the size of the pattern, and a variable pattern depth. Although Color QuickDraw is capable of translating the depth of a pattern to the current screen display depth, this can be a time-consuming process, and should be avoided. As always, color patterns provide a method of dithering, which increases the number of perceived colors shown on the screen by trading off resolution.

Here are some of the new calls for drawing in color:

PROCEDURE FillCRect (r: Rect; pp: PixPatHandle); $AA0E;
PROCEDURE FillCOval (r: Rect; pp: PixPatHandle); $AA0F;
PROCEDURE FillCRoundRect (r:Rect; ovWd,ovHt: 
 INTEGER; pp: PixPatHandle);             $AA10;
PROCEDURE FillCArc (r: Rect; startAngle,arcAngle: 
 INTEGER; pp: PixPatHandle);             $AA11;
PROCEDURE FillCRgn (rgn: RgnHandle; pp: PixPatHandle);$AA12;
PROCEDURE FillCPoly (poly: PolyHandle; pp: PixPatHandle);      $AA13

Color Manager

The Color Manager controls the task of translating an application's color requests to a color capable of being displayed by the current hardware. In order to handle this task, the Color Manager keeps information about the display in a device record known as a GrafDevice.

GrafDevice = record
 gdUnitNum: integer; (Unit number of driver)
 gdID : integer; (Client Id for search proc)
 gdType : integer; (Device type)
 gdITable : ITabHandle; (Inverse table)
 gdResPref: integer; (Preferred resolution)
 gdSearchProc  : ProcListPtr; (List of search procedures)
 gdCompProc : ProcList Ptr; (List of complement procs)
 gdMap  : PixMapHandle; (Pixel map for display image)
 gdReserved : longint;  (Reserved)
      end;

The GrafDevice holds information concerning the type of search mechanism to be used for color matching and inverting, as well as a handle to its pixel map.

The Color Manager sets up an initial color table for each GrafDevice with default values, which correspond to the colors defined by the original QuickDraw. Color Manager procedures can also manipulate individual colors in a color table, so that an application can "fine tune" the mapping of the program's color description to the color displayed on the screen device.

Deferred Task Manager

Because the Macintosh II supports interrupts through all six NuBus slots, a manager is needed to handle the interrupts in an orderly fashion. The Deferred Task Manager determines the appropriate time to service each of the requested interrupts, depending on the level of interrupt requested and other activity occurring within the Macintosh II.

Operating System Utilities

These three routines in the Operating System Utilities which provide the ability to switch between 24-bit address mode, required for compatibility with existing Macintosh applications, and 32-bit address mode allowing access to the full 32-bit addressing capability of the MC68020 and NuBus slots:

 FUNCTION GetMMUMode (var mode: integer);
 FUNCTION SetMMUMode (mode: integer);
 FUNCTION RestoreMMUMode;

Note that the 68851 PMMU is needed for full 32-bit operation.

Script Manager

The Script Manager will normally be transparent to the Macintosh II application programmer, but it is used by TextEdit, which is commonly called by applications. The Script Manager provides the means for an application to be written independently of the language (or script) in use which should be a particular boon to programs written in Japanese and Arabic languages, as well as those based on the Roman alphabet.

Shutdown Manager

The Shutdown Manager is designed to provide a consistent way for the Macintosh to be turned off or to be rebooted from the Finder as well as from within an application. It allows the system to perform some housekeeping prior to turning off or rebooting. The Shutdown Manager is contained in the system resource file as "INIT" resource 4, making it available to any Macintosh that has been booted from a system file containing this resource.

A Shutdown Alert is defined in "INIT" resource 2 and is also found in the system resource file. This alert is used on a Macintosh without power-off capabilities, such as the Macintosh Plus or Macintosh SE. Custom ShutDown procedures may be installed and removed through routines available in the ShutDown Manager.

Slot Manager

The Slot Manager in the Macintosh II provides the means for the on-board ROM and logic to communicate with cards in the NuBus slots. The process of sending information to and from the slots requires an address translation between 24 and 32 bit addresses; this function is provided by Operating System Utilities. The Slot Manager concentrates on interpreting the information supplied by NuBus cards, and arbitrates requests for bus mastership. Each NuBus card is expected to have a declaration ROM which allows the Macintosh II Slot Manager to classify it and communicate with the card according to its capabilities.

Sound Manager

The Macintosh II Sound Manager replaces the 64K and 128K ROM Sound Driver. All previous data structures, routines, and synthesizers are supported in the Sound Manager, and new routines have been added to take advantage of the new Apple Sound Chip on the Macintosh II logic board. There are four standard synthesizers defined within the Sound Manager:

• Note synthesizer, for simple, monophonic sounds

• Wave table synthesizer, for monophonic or polyphonic sound

• M.I.D.I synthesizer, for playing music on external MIDI devices through the serial port

• Sampled sound synthesizer, for playing pre-recorded sounds

If a programmer wishes to expand upon the synthesizers provided in the Macintosh II ROM, he may do so by defining a synthesizer or sound resource. The Sound Manager can call the new resources to play existing channels, using the rules defined by the new synthesizer. This feature permits developers the flexibility to develop external sound hardware via NuBus slots, while using the Sound Manager to provide a consistent interface for sound software.

Start Manager

The Start Manager controls (what else?) the bootup process on the Macintosh II. Once power is supplied to the Macintosh II and control has been transferred to the ROM, the Startup Manager determines which microprocessor is present and initializes the Operating System Utilities, global variables, the system heap, and other ROM Managers as needed.

Changes to Existing Managers

All existing Manager Calls are supported in the Macintosh II ROM. Many of the changes to existing Managers are to provide compatibility with the new color capabilities of the Macintosh II. Here are some of the changes, again listed in alphabetical order.

AppleTalk Manager

The AppleTalk Manager incorporates significant increases in its capabilities and resources. Several of these changes result in easier programming for server, workstation, and spooler machines.

Control Manager

The Control Manager has been expanded to include color support with the definition of a new data structure, AuxCtlRec, and its corresponding resource type cctb. These structures define a color table associated with the control and determine the border color, fill color, and text color for the control.

Device Manager

The Device Manager has been modified to include support for NuBus cards, both as boot devices, and through the interrupt process.

The user-written device package added to the Chooser in the Macintosh Plus ROM has been extended in the Macintosh II so that device packages can now position the buttons displayed in the Chooser window. The programmer may also supply, through the List Manager, the list of devices to be associated with a particular Chooser icon.

Dialog Manager

Two new resource types, actb and ictb, add color and style information to alerts and dialogs, and dialog item lists. These resources are associated with a dialog or alert by assigning them the same resource ID as the parent ALRT or DITL.

The contents of the color table resources are similar to those found in TextEdit style records: face, size, font, and color fields are present to specify the look of an alert or dialog item.

File Manager

The Macintosh II File Manager can be used with an external file system other than the traditional Macintosh code. The File Manager documentation in Volume V of Inside Macintosh describes the method used to integrate such file systems into the File Manager.

Font Manager

Fonts in ROM now include Monoco 9, Geneva 9 and 12, as well as Chicago 12. There are also 4 and 8-bit versions of Chicago 12 and a 4-bit Geneva 9 font to increase the speed with which those fonts can be displayed when using 4 or 8 bit color or gray-scale. The fontType structure has been modified to support color fonts. The new font color table resource, fctb, specifies one or more absolute colors in the font.

International Utilities Package

The International Utilities Package has been extended to support the new Script Manager. It now includes multiple resources within a given script, and new date and time formatting options. International scripts with non-Roman sorting rules may specify the details via hooks in this package, so that characters such as "ä" and "á" may be treated as equals for sorting purposes.

Menu Manager

The menu manager has also been extensively rewritten. Modifications include:

Hierarchical Menus. The Menu Manager now implements hierarchical menus; if another level of menu is "beneath" a menu item, a right or left arrow is shown next to the menu item. The user moves the mouse to the left or right as needed, and another menu "pops out" to the side of the original item. The mouse is used to select an item from that menu, or to go up or down to another menu level. Five levels of hierarchical menus are permitted, but they look terribly confusing if you use more than one extra level.

Color Menus. Color menus are not implemented through a standard Color Lookup Table, but use a unique definition, the Menu Color Information Table. A distinct MCInfoRec may exist for the menu bar and for each menu title and item. Within each MCInfoRec, you find RGBColor information for the item in question and its background color.

Printing Manager

The Printing Manager has been moved to ROM. All routines are now available through a single trap, $A8FD, which is then vectored to the particular Printing Manager call.

SCSI Manager

The Macintosh II and Macintosh SE ROMs implement an SCSI "blind" transfer mode. The types of SCSI drives Apple will use support hardware handshaking, so blind transfer capabilities will result in faster transfer rates in those situations.

TextEdit

TextEdit records have not changed in size or structure, but they may now be interpreted in a different way. If the TextEdit field, txsize, has a value less than zero, the TextEdit record has style information associated with it. In that case, a handle to a TEStyleRec structure replaces the TextEdit fields txFont and txFace. This style record holds an array of "runs", each of which may use a different text style (font, face, size, color, line height, and font ascent).

With the addition of multiple runs within a TextEdit record, the existing limitation of one type of font and style has been removed. Further, an RGBColor can be specified with the STElement for each run, so TextEdit now supports color. You can therefore use TextEdit to write a paragraph like this one, which should make many programs much easier to write (if not easier to read). You did notice that some of these characters are in green, while others are in red, didn't you?

Style information can be passed from TextEdit to the application through a TextStyle record, which includes font, face, size, and color information. When the scrap is used to cut and paste style information, a new scrpSTElement type is used to transfer style and start character information.

Here are some new TextEdit calls:

FUNCTION  TEStylNew (destRect,viewRect: Rect):     TEHandle;   $A83E;
PROCEDURE SetStylHandle (theHandle: TEStyleHandle;       hTE: TEHandle);
FUNCTION  GetStylHandle (hTE: TEHandle):     TEStyleHandle;
FUNCTION  TEGetOffset (pt: Point; hTE: TEHandle):  integer;    $A83C;
PROCEDURE TEGetStyle (offset: integer; VAR theStyle:     TextStyle; VAR 
lineHeight,fontAscent: integer; hTE: TEHandle);
PROCEDURE TEStylPaste (hTE: TEHandle);
PROCEDURE TESetStyle (mode: integer; newStyle:     TextStyle; redraw: 
BOOLEAN; hTE: TEHandle);
PROCEDURE TEReplaceStyle (mode: integer;     oldStyle,newStyle: TextStyle; 
redraw: BOOLEAN; hTE: TEHandle);
PROCEDURE StylTextBox (theHandle: TEStyleHandle; theText: Ptr; 
 theLength: longint; box: Rect; just: integer);

[Unfortunately, a number of limitations still remain. Chief among them are a 32K limit on text and problems with teScroll using integer offsets which cause Text Edit to crash if the number of lines times the line height exceeds the integer offset for the number of pixels to scroll. Also the limitations of integer rectangle coordinates in the destination rectangle still exits. -Ed]

Vertical Retrace Manager

The Vertical Retrace Manager has been changed slightly to take into account the flexible video interface on the Macintosh II.

Window Manager

A new data type, CWindowRecord, has the same structure and size as the old WindowRecord, except the field port is now defined as a CGrafPort rather than the old GrafPort. A few other new data types are also provided.

Monitors

The 12-inch monochrome monitor runs at 75 pixels per inch, displaying 640 by 480 pixels. This represents a screen about 8.5" wide, and 6.4" tall, with 1.75 times more pixels than the old Macintosh. The 13-inch analog RGB color monitor runs at 68 pixels per inch, but has the same 640 by 480 pixels. Both monitors have a screen refresh rate of 66.7 Hz, because flicker was still visible at the normal 60 Hz rate. The Vertical Retrace Manager still provides "ticks" at a rate of 60 Hz for compatibility.

After comparing both screens side-by-side, you can see that the color monitor is excellent, but still not quite as sharp as the monochrome monitor. It is still very sharp, however. We do believe that you could use the color monitor all day, even for word processing, since you could use a larger font if necessary. Which monitor should you order? The monochrome will ship before the color one, so if you are in a hurry you might choose it. On the other hand, the color digitized images are spectacular, and even color More™ (version 1.1c) is quite attractive. If you need to do presentations, color More will be just the thing.

You will definitely need a color monitor, if you plan on writing color software.

Several other companies have announced other video options for the Macintosh II. For example, SuperMac has shown a 19-inch, high-resolution color monitor connected to a Macintosh II, just in case you are addicted to full page displays. It also seemed very sharp.

System Software

Finder 5.4 and System 4.0 are temporary versions offering a fancier Control Panel, Trash Can, Chooser, and other changes, including many new resources in the System file. Finder 5.4 and System 4.1 will actually be shipped with the Macintosh II, and will eventually be the choice for all Macintoshes except the original 128K RAM Macintosh, and the Macintosh XL. There is reason to suspect that the new System file will contain enough library routines to support using the new calls to TextEdit and some of the other Managers on existing Macintoshes. In this way, we could write programs that would run on the all Macintoshes with at least 512K of RAM, and still use many of these new features.

LaserWriter driver version 3.4 is on the way, offering numerous enhancements and bug fixes.

A/UX is a version of UNIX which conforms to AT&T System V, Version 2, Release 2, with Berkeley and Apple enhancements. You can, of course, use all the ROM calls from within this multi-tasking environment, and therefore write "proper" Macintosh programs.

Comments about the new Macintoshes

The Macintosh SE

The SE is probably more important than it seems at first glance, because it can be expanded relatively painlessly, and offers better performance than a Macintosh Plus. In particular, the internal SCSI hard disk is considerably faster than Apple's external HD-20SC on a Plus. The Apple field people like the SE, and think it will sell extremely well.

The Macintosh II

Obvious strong points include:

It has very few limitations to limit future expansion and growth of the product line.

You can put giant display screens showing thousands of colors in it. The color monitors seem to be very crisp and clear. We will actually be able to look at them all day long without going blind. You can also use up to six monitors simultaneously!

You will eventually be able to directly address up to 128 MB of RAM on the motherboard. Each NuBus card can address more than 256 MB (that's right, megabytes).

You can add processors and co-processors that can take over the NuBus (80386s, perhaps 68030s next year and who knows what a few years later).

The ROM software is designed, as always, with device independence in mind, so that well-written applications should continue to work as the hardware progresses.

Limitations include:

DMA was not implemented on the logic board, so this means that the processor still has to give disk I/O its full attention. NuBus cards, however, can use DMA.

There is no floppy drive port, so we can't connect our HD-20s to the II. How do we get our data over to it's SCSI disks? We need an adapter to attach old HD-20s to the internal floppy connector - here is another opportunity for an enterprising individual.

Many people feel that Apple needs a multi-tasking O/S to succeed in the workstation market, but they do not have one yet (except A/UX, of course). [A new Finder is under development, inspired by Andy Hertzfeld's Servent, which Apple purchased last year. Unfortunately, developer's have been signed to non-disclosure on the development efforts so we can't comment on it. Apple has been very sensitive on the issue of Servent and it's influence on this effort. -Ed]

The price is high. Will the MS-DOS clone wars make the Macintosh II too expensive for business? Perhaps, but the Macintosh II does look cheap as an engineering workstation - if we write some great software for those markets. So don't stand there, get busy! Recent announcements by IBM make those products even more expensive, and the delay in delivery of their new OS should make the Mac II an attractive price/performance alternative over the next ten months.

Performance

Here are some benchmark results from the Macintosh SE and the Macintosh II. Noted that Macintosh II graphics performance depends on the graphics mode, with one-bit per pixel color (or grey scale) naturally operating faster than eight-bit per pixel color.

The raw numbers, in ticks, are given in the table below. The chart that follows has a vertical axis of Time, relative to the Macintosh Plus as a standard.

PlusSEIIProdigy 4
256 colors
(2 colors)
Integers2011744038
Reals528537104111
Extended3193175758
Transcend.55255963 or 14***10
Sieve543442116106
Lines301265244 (170)102
Windows393356165 (99)124

One prototype Macintosh II gave a benchmark result of 63 ticks for a program that computes transcendental functions, such as logarithms, cosines, arctangents, and square roots. Another prototype gave a much shorter time of 14 ticks. Since this test depends on SANE's use of the 68881 math co-processor, we need to run these tests again after the system software is finalized. We show the longer time in the chart.

What do these numbers mean? Here are some tentative conclusions:

1. The SE is up to 15% faster than the Macintosh Plus. This is because the video circuits no longer steal as much processor time for RAM refresh. Although we did not test the hard disk, other tests indicate that the SE's hard disk performance may be up to two times faster than that of a Macintosh Plus, due to improvements in the SCSI driver in the SE.

2. The Macintosh II is similar in performance to a Macintosh Plus with a Levco Prodigy board. This is reasonable, since both have a 16-MHz 68020 with a 68881 math co-processor. The Macintosh II is often 4 to 5 times faster than a Macintosh Plus, but may be 50 times faster on some number crunching. Again, our test results are not clear in this area yet.

3. The number crunching tests reflect the Macintosh II's use of a newly written SANE package. SANE will use the math co-processor if it is there. If you were to write your program directly using 68881 instructions, you would see even better performance. One Apple test showed that direct calls to the 68881 were about 6 times faster than using the patched SANE. You can write instructions to access the 68881 with MPW Assembler, a version of Consulair C, and Absoft FORTRAN. Other support, such as MPW Pascal version 2.0, is on the way. Note however, that SANE is more accurate than the 68881 alone due to some problems with certain functions in the math chip. If accuracy is important, you might want to use the more accurate algorithms in SANE for SINE and COSINE functions rather than calling the 68881 directly.

4. Other tests indicate that the Macintosh II has much faster hard disk performance than other Macintoshes, running up to three times faster than a Macintosh Plus. It is not as fast as it might be however, and early indications are that if the II has any weakness at all it might be in this area of disk access.

All in all, the Macintosh II looks like a superior computer - one that presently offers the best combination of performance, price, and superior software. We think that you will like it.

 

Community Search:
MacTech Search:

Software Updates via MacUpdate

Dropbox 193.4.5594 - Cloud backup and sy...
Dropbox is a file hosting service that provides cloud storage, file synchronization, personal cloud, and client software. It is a modern workspace that allows you to get to all of your files, manage... Read more
Google Chrome 122.0.6261.57 - Modern and...
Google Chrome is a Web browser by Google, created to be a modern platform for Web pages and applications. It utilizes very fast loading of Web pages and has a V8 engine, which is a custom built... Read more
Skype 8.113.0.210 - Voice-over-internet...
Skype is a telecommunications app that provides HD video calls, instant messaging, calling to any phone number or landline, and Skype for Business for productive cooperation on the projects. This... Read more
Tor Browser 13.0.10 - Anonymize Web brow...
Using Tor Browser you can protect yourself against tracking, surveillance, and censorship. Tor was originally designed, implemented, and deployed as a third-generation onion-routing project of the U.... Read more
Deeper 3.0.4 - Enable hidden features in...
Deeper is a personalization utility for macOS which allows you to enable and disable the hidden functions of the Finder, Dock, QuickTime, Safari, iTunes, login window, Spotlight, and many of Apple's... Read more
OnyX 4.5.5 - Maintenance and optimizatio...
OnyX is a multifunction utility that you can use to verify the startup disk and the structure of its system files, to run miscellaneous maintenance and cleaning tasks, to configure parameters in the... Read more
Hopper Disassembler 5.14.1 - Binary disa...
Hopper Disassembler is a binary disassembler, decompiler, and debugger for 32- and 64-bit executables. It will let you disassemble any binary you want, and provide you all the information about its... Read more

Latest Forum Discussions

See All

Zenless Zone Zero opens entries for its...
miHoYo, aka HoYoverse, has become such a big name in mobile gaming that it's hard to believe that arguably their flagship title, Genshin Impact, is only three and a half years old. Now, they continue the road to the next title in their world, with... | Read more »
Live, Playdate, Live! – The TouchArcade...
In this week’s episode of The TouchArcade Show we kick things off by talking about all the games I splurged on during the recent Playdate Catalog one-year anniversary sale, including the new Lucas Pope jam Mars After Midnight. We haven’t played any... | Read more »
TouchArcade Game of the Week: ‘Vroomies’
So here’s a thing: Vroomies from developer Alex Taber aka Unordered Games is the Game of the Week! Except… Vroomies came out an entire month ago. It wasn’t on my radar until this week, which is why I included it in our weekly new games round-up, but... | Read more »
SwitchArcade Round-Up: ‘MLB The Show 24’...
Hello gentle readers, and welcome to the SwitchArcade Round-Up for March 15th, 2024. We’re closing out the week with a bunch of new games, with Sony’s baseball franchise MLB The Show up to bat yet again. There are several other interesting games to... | Read more »
Steam Deck Weekly: WWE 2K24 and Summerho...
Welcome to this week’s edition of the Steam Deck Weekly. The busy season has begun with games we’ve been looking forward to playing including Dragon’s Dogma 2, Horizon Forbidden West Complete Edition, and also console exclusives like Rise of the... | Read more »
Steam Spring Sale 2024 – The 10 Best Ste...
The Steam Spring Sale 2024 began last night, and while it isn’t as big of a deal as say the Steam Winter Sale, you may as well take advantage of it to save money on some games you were planning to buy. I obviously recommend checking out your own... | Read more »
New ‘SaGa Emerald Beyond’ Gameplay Showc...
Last month, Square Enix posted a Let’s Play video featuring SaGa Localization Director Neil Broadley who showcased the worlds, companions, and more from the upcoming and highly-anticipated RPG SaGa Emerald Beyond. | Read more »
Choose Your Side in the Latest ‘Marvel S...
Last month, Marvel Snap (Free) held its very first “imbalance" event in honor of Valentine’s Day. For a limited time, certain well-known couples were given special boosts when conditions were right. It must have gone over well, because we’ve got a... | Read more »
Warframe welcomes the arrival of a new s...
As a Warframe player one of the best things about it launching on iOS, despite it being arguably the best way to play the game if you have a controller, is that I can now be paid to talk about it. To whit, we are gearing up to receive the first... | Read more »
Apple Arcade Weekly Round-Up: Updates an...
Following the new releases earlier in the month and April 2024’s games being revealed by Apple, this week has seen some notable game updates and events go live for Apple Arcade. What The Golf? has an April Fool’s Day celebration event going live “... | Read more »

Price Scanner via MacPrices.net

Apple Education is offering $100 discounts on...
If you’re a student, teacher, or staff member at any educational institution, you can use your .edu email address when ordering at Apple Education to take $100 off the price of a new M3 MacBook Air.... Read more
Apple Watch Ultra 2 with Blood Oxygen feature...
Best Buy is offering Apple Watch Ultra 2 models for $50 off MSRP on their online store this week. Sale prices available for online orders only, in-store prices may vary. Order online, and choose... Read more
New promo at Sams Club: Apple HomePods for $2...
Sams Club has Apple HomePods on sale for $259 through March 31, 2024. Their price is $40 off Apple’s MSRP, and both Space Gray and White colors are available. Sale price is for online orders only, in... Read more
Get Apple’s 2nd generation Apple Pencil for $...
Apple’s Pencil (2nd generation) works with the 12″ iPad Pro (3rd, 4th, 5th, and 6th generation), 11″ iPad Pro (1st, 2nd, 3rd, and 4th generation), iPad Air (4th and 5th generation), and iPad mini (... Read more
10th generation Apple iPads on sale for $100...
Best Buy has Apple’s 10th-generation WiFi iPads back on sale for $100 off MSRP on their online store, starting at only $349. With the discount, Best Buy’s prices are the lowest currently available... Read more
iPad Airs on sale again starting at $449 on B...
Best Buy has 10.9″ M1 WiFi iPad Airs on record-low sale prices again for $150 off Apple’s MSRP, starting at $449. Sale prices for online orders only, in-store price may vary. Order online, and choose... Read more
Best Buy is blowing out clearance 13-inch M1...
Best Buy is blowing out clearance Apple 13″ M1 MacBook Airs this weekend for only $649.99, or $350 off Apple’s original MSRP. Sale prices for online orders only, in-store prices may vary. Order... Read more
Low price alert! You can now get a 13-inch M1...
Walmart has, for the first time, begun offering new Apple MacBooks for sale on their online store, albeit clearance previous-generation models. They now have the 13″ M1 MacBook Air (8GB RAM, 256GB... Read more
Best Apple MacBook deal this weekend: Get the...
Apple has 13″ M2 MacBook Airs available for only $849 today in their Certified Refurbished store. These are the cheapest M2-powered MacBooks for sale at Apple. Apple’s one-year warranty is included,... Read more
New 15-inch M3 MacBook Air (Midnight) on sale...
Amazon has the new 15″ M3 MacBook Air (8GB RAM/256GB SSD/Midnight) in stock and on sale today for $1249.99 including free shipping. Their price is $50 off MSRP, and it’s the lowest price currently... Read more

Jobs Board

Early Preschool Teacher - Glenda Drive/ *Appl...
Early Preschool Teacher - Glenda Drive/ Apple ValleyTeacher Share by Email Share on LinkedIn Share on Twitter Read more
Senior Software Engineer - *Apple* Fundamen...
…center of Microsoft's efforts to empower our users to do more. The Apple Fundamentals team focused on defining and improving the end-to-end developer experience in Read more
Relationship Banker *Apple* Valley Main - W...
…Alcohol Policy to learn more. **Company:** WELLS FARGO BANK **Req Number:** R-350696 **Updated:** Mon Mar 11 00:00:00 UTC 2024 **Location:** APPLE VALLEY,California Read more
Medical Assistant - Surgical Oncology- *Apple...
Medical Assistant - Surgical Oncology- Apple Hill WellSpan Medical Group, York, PA | Nursing | Nursing Support | FTE: 1 | Regular | Tracking Code: 200555 Apply Now Read more
Early Preschool Teacher - Glenda Drive/ *Appl...
Early Preschool Teacher - Glenda Drive/ Apple ValleyTeacher Share by Email Share on LinkedIn Share on Twitter Read more
All contents are Copyright 1984-2011 by Xplain Corporation. All rights reserved. Theme designed by Icreon.