TweetFollow Us on Twitter

Jul 85 Letters
Volume Number:1
Issue Number:8
Column Tag:Letters

Letters

Startup Disk

David Dunham

Maitreya Design

Goleta, CA.

I'd be willing to submit a DA that changes the default drive, but you should know that the default drive has absolutely nothing to do with the start-up disk [MacTutor, June 1985, p. 24]. To change the start-up disk, you'd need to close the open system file and open a new one. This could present problems, since the application may have handles to purged resources from the system file. I don't know what happens if the file's closed from under it. What are your writer's guidelines and how much do you pay? Nothing for tips in letters, I know from experience...

[Typical pay is $100 for a column. Another $50 if you become a regular contributing editor. We hope that some things (like letter tips) people will donate for the good of the cause; we only have so much $$ to go around...-Ed.]

MicroFinder Bug Fix

Shawn Mikiten

San Antonio, Tx.

MicroFinder [June MacTutor 1-7] works well as long as you do not select a file on the other disk drive. The bug appears in the way the _Launch trap runs the application. The filename is properly passed but not the volumne the file is on. The _Launch trap will automatically attempt to run the application on the disk the MicroFinder was started from because the filename did not have the volumne specifier before it. The solution lies in the _Pack3 reply record. The variable vRefNum contains the disk drive number of the file when it returns from a successful call. Using the vRefNum value obtained, it is put in a parameter block for the File Manager call _SetVol. The parameter used is ioDrvNum. The following are directions for patching the source code so that it will work (See File Manager /OS/FS.A.1, page 26 & 33 in the new "Inside Macintosh" phone book.)

Add _SetVol trap value:

.TRAP      _SetVol               $A015

The code following _PaintRect is to be added:

_PaintRect

;   Launch Routine here

LEA          PARMBLK, A0         ;get pointer
LEA           vRefNum, A1           ; get addr. of vRefNum
MOVE.W   (A1), 22(A0)           ; put vRefNum into the
                                                               ; ioDrvNum 
parameter.
_SetVol                                            ; set it. (note A0 
points to
                                                             ; the param. 
block!)

LEA        SFileName, A1          ; get addr. of filename

Next, add the data structures necessary for the Reply record and parameter block. Add vRefNum in the Reply record:

SFREPLY:         DC.B      0,0       ; good, copy 
                 DC.B      'TYPE'    ; FType     (ostype)
 vRefNum:        DC.W       0,0      ;  vRefNum, version 
SFILENAME:       DCB.B    63,0       ; fname (string[63]) 

And now the parameter block, to be added after the WHITEPAT definition (Note that the file name pointer must be nil to force invocation of vRefNum inserted into ioDrvNum.):

;  standard 8 field parameter block for setvol.

PARMBLK:           DC.L       0            ;ioLink ptr.
                                    DC.W      0           ; ioType
                                    DC.W      0           ; ioTrap
                                    DC.W      0          ; ioCmdAddr
                                    DC.L         0          ; ioCompletion 
ptr.
                                    DC.W        0          ; ioResult
                                    DC.L          0          ; ioFileName 
ptr.
                                    DC.W        0          ; ioDrvNum

I hope this bug fix will offset the cost of the MDS software I am about to purchase. I havebeen using a friends copy and find it the easiest assembler I have used in 7 years of Apple II's, Digital 2065, IBM PC and VAX computers!

[Shawn wins the $50 for being first with his bug fix. Thank you to the four other people who submitted a fix: Loftus Becker Jr. of Hartford, CT, who submitted a similar solution to Shawn's; Tom Taylor of Provo Utah and Neal Lebedin of Palm Bay, FL., both of whom submitted similar solutions but slightly different from Shawn's; And Paul Snively of Columbus, IN. in MacAsm...-Ed.]

More Bug Fix Comments

Loftus E. Becker, Jr.

Hartford, CT.

The bug in Chris Yerga's microfinder program (ID=26) is "failure to launch". This stems from the fact that the lanuch routine will look for the named file on the default volume unless it is told otherwise. Hence, when the microfinder program is run from the default volume (usually drive 1) and tries to launch a program on drive 2, Launch gets the filename, doesn't know it's on drive 2, and tries to launch from drive 1!

Two points may be of some interest. First this is a bomb that is not trapped by Macsbug. Second, a similar bug appears in the MDS development system: If you are developing a program with the .asm, .link, and other files on the external drive, but the program itsef on the internal drive, an attempt to run it from the TRANSFER menu in the linker will produce the same error.My compliments on a magzine that has gotten better with every issue.

Alternate Bug Fix

Tom Taylor

Provo, UT

This is similar in function , but uses the stack for the parameter block...

ioVQElSize           EQU   $40     ;io param blk length
ioCompletion       EQU   $C       ;offset (ptr.)
ioVNPtr                   EQU   $12     ;offset (ptr. or nil)
ioVRefNum          EQU   $16     ;offset (word)

SUB.L    #ioVQElSize, SP    ;allocate block on stack
MOVE.L  SP, A0                        ;block ptr. to A0
CLR.L     ioCompletion(A0)  ; I always clear this
LEA         SFReply, A1             ; reply record ptr to A0
MOVE.W 6(A1), ioVRefNum(A0)  
CLR.L      ioVNPtr(A0)             ;clear name ptr.

_SetVol                                           ; go for it...
ADD.L      #ioVQElSize, SP  ; dump block

MacAsm Version of Bug Fix

Paul Snively

Columbus, IN

Apparently the standard file package, even though it automatically senses the presence of a second disk drive and, if one is present, gives you the "Drive" button in the standard dialog box, does not automatically change the default volume if the "Drive" button is hit. Where I come from, features like this are called "bugs." In other words, as far as I'm concerned, the bug is in the standard file package, not Chris' code

.

01150 *--------------------------------
01160 *        Launch Routine (MacAsm)
01170 *--------------------------------
01180          LEA     ParamBlock(PC),A0       ;File Manager paramBlock
01190          LEA     vRefNum(PC),A1          ;Volume Reference Number
01200          MOVE.W  (A1),22(A0)             ;Move to paramBlock
01210          OST     SetVol                  ;Make the default volume
01220          LEA     SFileName(PC),A1        ;Get address of file name
01230          LEA     LaunchPtr(PC),A0        ;Get address of launch 
ptr
01240          MOVE.L  A1,(A0)                 ;Move pointer to name
01250          TBX     Launch                  ;And call Launch...

Don't Like Glossy Look

Warren Michelsen

Page, Az.

I may as well comment on your new glossy look. In a word, YUCK! The gloss degrades the readability. The older stock could be viewed at any angle without glare. The older stock holds up better too; (they receive very heavy use as I refer back to them constantly). [We agree; how do you like this look? -Ed.]

Need Pascal Detective on this Bug!

Jack Cassidy

San Diego, CA.

Put a MacPascal detective on this one! The program below causes a system error (ID=02). Needless to say, I discovered this bug in a much longer program and was very confused.

program SystemBomb;
type
   count = (one, two, three, four, five);
var
   simple:array[count] of integer;

begin
    simple[five]:=31;
end.

[We'll ask our resident guru, Steve Brecher to research out this one!]

Mental Starvation of MacWorld

Rick Barrett

Dallas, TX.

AH! EUREKA,

This is the publication that I've been looking for. It's not glossy [well...-Ed.], slick, or condescending. It's meat, fact, it's wonderful! Keep up the good work...I've been rescued from the mental starvation of MacWorld.

Desperately Seeking Chief Wizard

James Muirhead

I was dissappointed to see Chris Derossi's Pascal Procedures column missing from the last issue. I was all psyched for learning window dynamics and then there was a no-show. His column is a must. Please let him know that he is sorely needed and most appreciated.

[Chris has stopped writing for reasons known only to him; perhaps your plea will awaken him...-Ed.]

MacTutor leaves me Codeless

R. Onzo

FW. Inc.

I have just recieved your complimentary issue of MacTutor and I must admit that it was an immediate sale. Your "Journal" is certainly unique compared to anything I've ever seen and the anticipation of finally being able to associate myself with a first rate tech journal leaves me almost "codeless". You've honestly made me feel like I've been trapped inside my Mac. You seemd to have just peeked inside, found me there tangled in the chips and guided me to the nearest exit showing me in the interum, the vast highways leading outward (and subsequently, inward). [Wow! we did all that? Thanks for those kind words...-Ed.]

Changing Basic Poke Codes

Terry Bartelmey

Chicago, Il.

My print routines are set up with pokes to change PRINT to LPRINT and back. I have inquired with Microsoft as to the poke locations required for the Mac, but to no avail. Could you help? [YES! See Mike Steiner's column on the structure of a Basic Program. It has all the info you need to change PRINT to LPRINT under program control.-Ed.]

Imagewrite Cutesy, but...

David Haupt

Littleton, CO.

It is cutesy to have the magazine printed out on an imagewriter but unprofessional in appearance. It is not as easy to read as a typset style woulld be. One would think that any magazine would be able to at least afford 7 grand for the Apple laser printer, wouldn't one? That would drastically increase the readability and the perceived professional level of MacTutor simultaneously.

[MacTutor is run by individuals, who, like any of us, are poor! Seven grand is seven grand, no matter if you publish a magazine or not! However, we have sacrificed the baby's milk money and now have the laser, after a three month delivery delay from Apple! How do you like it now?-Ed.]

Untested Code?

Inexcuseable is the only word for publishing untested code. Just plain sloth. Yet that is exactly what Robert Denny confesses to print [in the May issue]. I like his column on C, but I am startled at his lack of professional pride.

[ I think your letter was a little hard on us; Bob's code was taken from a much longer program that is running, but the code fragments were not re-assembled into a program just to test them specifically, hence the warning. -Ed.]

 

Community Search:
MacTech Search:

Software Updates via MacUpdate

Latest Forum Discussions

See All

Whitethorn Games combines two completely...
If you have ever gone fishing then you know that it is a lesson in patience, sitting around waiting for a bite that may never come. Well, that's because you have been doing it wrong, since as Whitehorn Games now demonstrates in new release Skate... | Read more »
Call of Duty Warzone is a Waiting Simula...
It's always fun when a splashy multiplayer game comes to mobile because they are few and far between, so I was excited to see the notification about Call of Duty: Warzone Mobile (finally) launching last week and wanted to try it out. As someone who... | Read more »
Albion Online introduces some massive ne...
Sandbox Interactive has announced an upcoming update to its flagship MMORPG Albion Online, containing massive updates to its existing guild Vs guild systems. Someone clearly rewatched the Helms Deep battle in Lord of the Rings and spent the next... | Read more »
Chucklefish announces launch date of the...
Chucklefish, the indie London-based team we probably all know from developing Terraria or their stint publishing Stardew Valley, has revealed the mobile release date for roguelike deck-builder Wildfrost. Developed by Gaziter and Deadpan Games, the... | Read more »
Netmarble opens pre-registration for act...
It has been close to three years since Netmarble announced they would be adapting the smash series Solo Leveling into a video game, and at last, they have announced the opening of pre-orders for Solo Leveling: Arise. [Read more] | Read more »
PUBG Mobile celebrates sixth anniversary...
For the past six years, PUBG Mobile has been one of the most popular shooters you can play in the palm of your hand, and Krafton is celebrating this milestone and many years of ups by teaming up with hit music man JVKE to create a special song for... | Read more »
ASTRA: Knights of Veda refuse to pump th...
In perhaps the most recent example of being incredibly eager, ASTRA: Knights of Veda has dropped its second collaboration with South Korean boyband Seventeen, named so as it consists of exactly thirteen members and a video collaboration with Lee... | Read more »
Collect all your cats and caterpillars a...
If you are growing tired of trying to build a town with your phone by using it as a tiny, ineffectual shover then fear no longer, as Independent Arts Software has announced the upcoming release of Construction Simulator 4, from the critically... | Read more »
Backbone complete its lineup of 2nd Gene...
With all the ports of big AAA games that have been coming to mobile, it is becoming more convenient than ever to own a good controller, and to help with this Backbone has announced the completion of their 2nd generation product lineup with their... | Read more »
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 »

Price Scanner via MacPrices.net

B&H has Apple’s 13-inch M2 MacBook Airs o...
B&H Photo has 13″ MacBook Airs with M2 CPUs and 256GB of storage in stock and on sale for up to $150 off Apple’s new MSRP, starting at only $849. Free 1-2 day delivery is available to most US... Read more
M2 Mac minis on sale for $100-$200 off MSRP,...
B&H Photo has Apple’s M2-powered Mac minis back in stock and on sale today for $100-$200 off MSRP. Free 1-2 day shipping is available for most US addresses: – Mac mini M2/256GB SSD: $499, save $... Read more
Mac Studios with M2 Max and M2 Ultra CPUs on...
B&H Photo has standard-configuration Mac Studios with Apple’s M2 Max & Ultra CPUs in stock today and on Easter sale for $200 off MSRP. Their prices are the lowest available for these models... Read more
Deal Alert! B&H Photo has Apple’s 14-inch...
B&H Photo has new Gray and Black 14″ M3, M3 Pro, and M3 Max MacBook Pros on sale for $200-$300 off MSRP, starting at only $1399. B&H offers free 1-2 day delivery to most US addresses: – 14″ 8... Read more
Department Of Justice Sets Sights On Apple In...
NEWS – The ball has finally dropped on the big Apple. The ball (metaphorically speaking) — an antitrust lawsuit filed in the U.S. on March 21 by the Department of Justice (DOJ) — came down following... Read more
New 13-inch M3 MacBook Air on sale for $999,...
Amazon has Apple’s new 13″ M3 MacBook Air on sale for $100 off MSRP for the first time, now just $999 shipped. Shipping is free: – 13″ MacBook Air (8GB RAM/256GB SSD/Space Gray): $999 $100 off MSRP... Read more
Amazon has Apple’s 9th-generation WiFi iPads...
Amazon has Apple’s 9th generation 10.2″ WiFi iPads on sale for $80-$100 off MSRP, starting only $249. Their prices are the lowest available for new iPads anywhere: – 10″ 64GB WiFi iPad (Space Gray or... Read more
Discounted 14-inch M3 MacBook Pros with 16GB...
Apple retailer Expercom has 14″ MacBook Pros with M3 CPUs and 16GB of standard memory discounted by up to $120 off Apple’s MSRP: – 14″ M3 MacBook Pro (16GB RAM/256GB SSD): $1691.06 $108 off MSRP – 14... Read more
Clearance 15-inch M2 MacBook Airs on sale for...
B&H Photo has Apple’s 15″ MacBook Airs with M2 CPUs (8GB RAM/256GB SSD) in stock today and on clearance sale for $999 in all four colors. Free 1-2 delivery is available to most US addresses.... Read more
Clearance 13-inch M1 MacBook Airs drop to onl...
B&H has Apple’s base 13″ M1 MacBook Air (Space Gray, Silver, & Gold) in stock and on clearance sale today for $300 off MSRP, only $699. Free 1-2 day shipping is available to most addresses in... Read more

Jobs Board

Medical Assistant - Surgical Oncology- *Apple...
Medical Assistant - Surgical Oncology- Apple Hill Location: WellSpan Medical Group, York, PA Schedule: Full Time Sign-On Bonus Eligible Remote/Hybrid Regular Apply Read more
Omnichannel Associate - *Apple* Blossom Mal...
Omnichannel Associate - Apple Blossom Mall Location:Winchester, VA, United States (https://jobs.jcp.com/jobs/location/191170/winchester-va-united-states) - Apple Read more
Cashier - *Apple* Blossom Mall - JCPenney (...
Cashier - Apple Blossom Mall Location:Winchester, VA, United States (https://jobs.jcp.com/jobs/location/191170/winchester-va-united-states) - Apple Blossom Mall Read more
Operations Associate - *Apple* Blossom Mall...
Operations Associate - Apple Blossom Mall Location:Winchester, VA, United States (https://jobs.jcp.com/jobs/location/191170/winchester-va-united-states) - Apple Read more
Business Analyst | *Apple* Pay - Banco Popu...
Business Analyst | Apple PayApply now " Apply now + Apply Now + Start applying with LinkedIn Start + Please wait Date:Mar 19, 2024 Location: San Juan-Cupey, PR Read more
All contents are Copyright 1984-2011 by Xplain Corporation. All rights reserved. Theme designed by Icreon.