From: Malcolm Sharman <sharman@norex.com.au>
To: Multiple recipients of <list-fantasm@mail.tau.it>
Subject:  Re: PF5.0 or Inside Mac?

>Well if I can find IM on the net, can I download it and save it on a CD ?
You betcha. To download all the inside Mac books from Apple's devworld 
site at
http://www.devworld.apple.com
all the books are there in either acrobat or docviewer format.
That is all I have to say so bye




Malcolm Sharman
Lead Programmer
Pcyclone Entertainment Software

From: twi@pac.com.au To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: NAND & NOR Hello everyone, I understand OR,AND,NOT,XOR and how and when to use them,but I haven't come across NAND and NOR before.Could someone please enlighten me as to what these are for? Thanks, Paul
From: Anthony Oren Loeppert <oren@mail.utexas.edu> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: NAND & NOR >I understand OR,AND,NOT,XOR and how and when to use them,but I haven't come >across NAND and NOR before.Could someone please enlighten me as to what >these are for? NAND is ANDing a bunch of stuff together then NOTing the whole thing. NOR is ORing a bunch of things and then NOTing the the whole. say the NAND and NOR are just for 2 inputs, A and B; NAND = (A*B)' = A'+B' NOR = (A+B)' = A'*B' where + is OR, * is AND, and ' is NOT. as to what they're for... well they're just another alternative to use I guess. Anthony Oren Loeppert *** http://www.cs.utexas.edu/users/oren/ * o* * ***> * * * * * | | * * | / * * |/ * * * * * * **\
From: Figaro Tea <humphret@ruby.winthrop.edu> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: NAND & NOR On Mon, 3 Nov 1997 twi@pac.com.au wrote: > I understand OR,AND,NOT,XOR and how and when to use them,but I haven't come > across NAND and NOR before.Could someone please enlighten me as to what > these are for? They fill up pages in textbooks! The only place I've come across them is when you're designing circuits for the hardware. If they're used for anything else I'd like to know too. ..._Tim_... --=[I know everything...just not at the same time.]=-- http://www.shack.org/zzhumphreyt zzhumphreyt@winthrop.edu
From: robot@writeme.com (Alok) To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Alok Hi, Well as you may have heard that the French truck drivers are on strick, it's the same over here. SO that allowed me to program!!! I have found few errors in my program: i was passing data on the stack instead of the registers! I have advanced a bit, will finish the initialization routine tonight Bye, Alok
Date: Tue, 4 Nov 1997 18:29:37 +1300 From: Steven Brown <sgb@wave.co.nz> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Alok >here is the first prog: A simple application to help you remember your Please don't send attachments to a mailing list. Send a message asking if anyone wants it, them send the attachments to those people individually. Thanks, Steven.
Date: Wed, 05 Nov 1997 22:10:04 +0000 From: twi@pac.com.au To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: BeOS Hello again, Does anyone here know what's happening re BeOS? It seems to have gone very quiet about it.Has it become a pointless product because of the hopeful release of the seemingly mythical Rhapsody (it is coming,right?)? Paul
Date: Wed, 5 Nov 1997 14:32:15 +0100 From: Salvo Privitera <salvo.privitera@tau.it> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: BeOS >Hello again, > >Does anyone here know what's happening re BeOS? It seems to have gone very >quiet about it.Has it become a pointless product because of the hopeful >release of the seemingly mythical Rhapsody (it is coming,right?)? > >Paul > > My copy of Preview Release 2 arrived on 4 November. Salvo
Date: Wed, 05 Nov 1997 15:25:30 +0100 From: Allan Jensen <maccoder@post6.tele.dk> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: BeOS twi@pac.com.au wrote: > > Hello again, > > Does anyone here know what's happening re BeOS? It seems to have gone very > quiet about it.Has it become a pointless product because of the hopeful > release of the seemingly mythical Rhapsody (it is coming,right?)? > > Paul > > www.macosrumors.com told me that Microsoft is shopping for a new OS since Win98 might be in a bit of trouble (what with the IE problems ("use our browser or we'll never talk to you again")). The rumor says that Rhapsody and BeOS is one of the two potentials. Another reason is, of course, that Windows is 'slightly' dated. I know I'm easy to fool. But it's a nice thought, isn't it? Allan
Date: Fri, 7 Nov 1997 15:38:45 +0000 From: robot@writeme.com (Alok) To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: help! Hi, I just have few questions: Who controls the switching between applications? That's when I click on a window behind my app that belongs to the finder, who will control the switching? I put my menu bar at the starting of my app, but then immidiatly it diseapears. Then when I leave my app (multi finder) and come back to it (without having quit it) my menu bar comes back and stays this time!? What's happening? Bye, Alok
Date: Fri, 7 Nov 1997 15:39:01 +0000 From: robot@writeme.com (Alok) To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Forget my last msg Hi, If you like reading my letters (good for getting some sleep?) then forget my last one. The finder takes care of the switching between apps, and the menubar prob has been solved (a typo mistake). Alok
Date: Sat, 8 Nov 1997 03:41:10 -0500 From: Stuart Ball <lightsoft@compuserve.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: MIDI Can anybody help Benny out? All suggestions greatly appreciated. Stu. ------------------------------------------------------------------- From Benny Ronnhager >The Serial Manager does not support the settings needed for MIDI. So my >question is: How do >you access the serial port chips directly in PowerPC assembler? > >The Studio 4 MIDI interface is connected to the modem or printer port. >You can have two >Studio 4 interfaces on the modem port and two Studio 4 interfaces on the >printer port >(if you need it). Then you have 512 MIDI channels in and 512 MIDI >channels out. > >The hardware MIDI interface operates at 31.25 (+/-1%) Kbaud, >asynchronous, with a start bit, >8 data bits and a stop bit. This makes a total of 10 bits for a period >of 320 microseconds >per serial byte. The start bit is a logical 0 (current on) and the stop >bit is a logical 1 >(current off). > >The MIDI protocoll is not new to me at all. I am a real MIDI wizard :-). >But to access >hardware directly is difficult because Apple computer is not so helpful, >they want you to >use the operating system calls. But you can not always do that. So what >can I do?
Date: Sat, 8 Nov 1997 20:40:05 +0000 From: robot@writeme.com (Alok) To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Idea!? HI, Here is any idea I have had since long, but i have noticed I won't be able to realize it, so here it is: Improve the email: ******* *** ****** First you take a forwarding email that forwards your mail to wo different server (let's take geocities and hotmail for example). Than write a program that does this: Knowing that an email server (SMPT or POP or somethin glike that) understand the following commands: retrieve msg n & delete msg n: Log into geocities: Retrieve msg 1 until word "subject" is incountered. Then retrieve 20 next bytes (or until CR is found) delete msg 1. Do the same for all others. Show all subjects with senders email to user. Let user say which msg to download and which not to. Log into hotmail. retreive all msg asked my user and delete all others. and that's it! You'll never have to download 30 Email newspapers when you come back from holidays, or download a msgs from someone you don't know, or don't want to hear from (eg: Me!, anything not "*MAC*", anything got to do with Schumacher and not Villeneuve, etc...) SO what do you think of it? BTW: Geocities: is a very cool server, that gives you free emails, and web space (http://www.geocities.com). Hotmail: i don't know what it is, but I guess it's also gives you free emails (the word "hotmail" come to my ears trough a friend). Schumacher: is the best driver under rain, but I hate him (personel view) Villeneuve: is the best driver, final. (also personel view) Alok: I hope you aren't angry with him! Bye, Alok. (BTW Steven Brown, doesn't your email prorgam let you select wether to download an attachment or not? Mine does....)
Date: Sat, 08 Nov 1997 14:14:11 +0000 From: Parker Beeson <parker@gobos.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Need *old* Fantasm... I'm new to the list, but understand that there is an *old* version of Fantasm that runs on the 68000 MacSE. I'd really appreciate an info anyone might have as to which version it was and where to get it. Thanks.
From: Kevin Avila <kevin@cache-computing.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Idea!? >SO what do you think of it? I think it's already done...atleast on the BeOS it is =)
Date: Sat, 8 Nov 1997 19:00:16 -0500 From: Stuart Ball <lightsoft@compuserve.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Need *old* Fantasm... Hi Parker, As far as I'm aware (although do not take this as gospel!) the only version that ran on a 68000 was the Atari ST version (the original was written with Devpac on the ST). However, I will venture down into the dungeon later ('tis a long way down from this tower and an even longer way up - those cats!) just to check - it may well be that version 1 or 2 for the Mac did not use 020 addressing modes and so _may_ run on a 68K based machine. I would not put money on it though... Stu.
Date: Sat, 8 Nov 1997 19:00:14 -0500 From: Stuart Ball <lightsoft@compuserve.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: BCD maths Whilst I'm here, a plea to this revered community: Anybody know the "trick" way to add and subtract BCD numbers without hardware support? "Use abcd and sbcd" is not the answer I'm looking for. Some old 8 bit code maybe? I tried my usual informers but they failed me most, most miserably this time. :-) Stu.
Date: Sun, 9 Nov 97 20:35:43 +0800 From: Malcolm Sharman <sharman@norex.com.au> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: MIDI Hello All Ages ago somebody on the list offered some asm code from an archive. (think it was Kevin actually)Anyway I got the acrhcive and in this archive there happened to be a rather large code file of midi routines for controlling the hardware as well as accessing the serial chips, without using toolbox calls. The only problem is that this code file is in 68k assembler. However I am pretty sure anyone with any brains can translate it with a bit of effort. Email me if you want a copy of the code. sharman@norex.com.au
Date: Sun, 9 Nov 1997 15:30:13 +0900 From: C'mell@JLKhp.koto.tokyo.jp (Akira Muraki) To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Stack usage question. Hi! I learned PPC assembler with Fantasm. And I have a question, that is "How to use default stack by system?". I read LS_PPC_macros.def and trace program execution, but guess were only two words in stack. If you know "How to use stack space by system/Fantasm?", please teach me. Following picture (sorry its too big) is result of my self analyse. If I'm mistake in this picture, please correct and teach me. So, spelling and grammars mistake too, because I'm not native English speaker. Thank you. Akira Muraki. ____\ +_0_1_2_3 useage (a) / -4| | r31 -8| | r30 -12| | r29 -16| | r28 -20| | r27 -24| | r26 -28| | r25 -32| | r24 -36| | r23 -40| | r22 -44| | r21 -48| | r20 -52| | r19 -56| | r18 -60| | r17 -64| | r16 -68| | r15 -72| | r14 -76| | r13 -80| | r12 -84| | r11 *r10-r31 fill by "stmw r10,-88(sp)" _____\ -88| | r10 in start_up (b) / 60| |(?????) teach me! 56| |(?????) teach me! 52| |(?????) teach me! 48| |(r9 ?) teach me! 44| |(r8 ?) teach me! 40| |(r7 ?) teach me! 36| |(r6 ?) teach me! 32| |(r5 ?) teach me! 28| |(r4 ?) teach me! 24| |(r3 ?) teach me! 20| | r2 *use in system call (like "Xcall" macro) 16| |(r1 ?) teach me! 12| |(r0 ?) teach me! 8| | LR *use in after mtctr to system call 4| |(CTR ?) teach me! ____\ 0|________|(?????) teach me! (c) / (a) is sp of under start_up macro is running (b) is default stack size for after start_up macro (c) is sp of leave start_up macro
Date: Sun, 9 Nov 1997 13:08:50 -0500 From: Ajay Nath <AjayNath@compuserve.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Alok >> here is the first prog: A simple application to help you remember your friends' telephone numbers! << this could easily be done by just using the program i wrote, URLtility, to just type in phone numbers instead of URLs...of course the program should be modified to dial the # chosen & also to do some sorting/searching of the #s...trivial code changes would be required to do it
Date: Sun, 9 Nov 1997 13:09:34 -0500 From: Ajay Nath <AjayNath@compuserve.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: BeOS last i heard they were all excited about the intel port of the beos
Date: Mon, 10 Nov 1997 04:09:27 -0500 From: Scott Lahteine <slur@world.std.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: BCD maths >Whilst I'm here, a plea to this revered community: >Anybody know the "trick" way to add and subtract BCD numbers without >hardware support? "Use abcd and sbcd" is not the answer I'm looking for. > >Some old 8 bit code maybe? > >I tried my usual informers but they failed me most, most miserably this >time. > Well, the old 6502 had the lovely D flag, so SED and CLD would change ordinary binary math in and out of BCD. But alas, we aren't in 6502 land anymore. The quickest way to do BCD is to use a pre-generated lookup table. The code to do this on the fly is pretty simple too. Basically you do a bunch of 4-bit add-with-carry's and fudge with the results. Go in a loop from the least significant nybble to the most. Anything over $09 is equal to $10 and above. So, if your result is $0A or greater you can add $06 to get $10 and up. Anything over $99 is $100, etc.. This is like subtracting $0A or $A0 and carrying up.... 0A = 0 carry 1 0B = 1 carry 1 0C = 2 carry 1 ... ... 12 = 8 carry 1 (the largest possible value is 09 + 09) IN PSEUDOCODE: clo = $00 // carry flags chi = $00 index = 5 do { xlo = byte1[index] & $0F // lo nybble xhi = byte1[index] & $F0 // hi nybble ylo = byte2[index] & $0F yhi = byte2[index] & $F0 zlo = xlo + ylo + clo clo = $00 if (zlo > $09) then { zlo = zlo - $0A : chi = $10 } zhi = zhi + yhi + chi chi = $00 if (zhi > $90) then { zhi = zhi - $A0 : clo = $01 ) sum[index] = (zlo OR zhi) dec index } loop while (index >= 0) This is the basic idea.
Date: Mon, 10 Nov 1997 08:22:58 -0500 From: Stuart Ball <lightsoft@compuserve.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: MIDI/BCD maths Thanks for the BCD code Malcolm - most helpful. Look up table - d'oh - always obvious when you see the code :-) Like counting the ones in a byte. I've passed your reply re: midi code onto Benny. Stu.
Date: Mon, 10 Nov 1997 17:07:50 +0000 From: robot@writeme.com (Alok) To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Search engine Hi, Just wanted to let you know, that I spent this week-end remaking my web page, and that I have learned how to insert search engines. So if you want one in your homepage (I'm thinking of Lightsoft's in particular, since it's grown quite big), pls let me know. BTW Glenn: Pls don't touch my pages, I have been remaking my home page, and it's become quite a mess (i lost control of things). But if you could pls replace the first page with: "Page in construction" i would appreciate. Bye Alok
Date: Mon, 10 Nov 1997 18:37:07 +0000 From: robot@writeme.com (Alok) To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Alok >>> here is the first prog: A simple application to help you remember your >friends' telephone numbers! ><< > >this could easily be done by just using the program i wrote, URLtility, to >just type in phone numbers instead of URLs.. I don't get it? What does your program do? I don't get the link between a url and a phone number? >.of course the program should >be modified to dial the # chosen & also to do some sorting/searching of the >#s...trivial code changes would be required to do it Why #? I don't think you got what my program does (or should do) Bye, Alok
Date: Tue, 11 Nov 1997 09:21:16 -0500 From: Stuart Ball <lightsoft@compuserve.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Stack usage question. Akira Muraki wrote: >Hi! I learned PPC assembler with Fantasm. >And I have a question, that is "How to use default stack by system?". > >I read LS_PPC_macros.def and trace program execution, but guess were >only two words in stack. > >If you know "How to use stack space by system/Fantasm?", please teach me. Hi Akira, This is off the top of my head so forgive anything that's obviously wrong! This may sound a bit complicated, but it just requires one to follow a simple rule; "You can't just push and pop onto and off of the stack like you can in 68K". Ok, so why? Before one can call a C function from assembler (such as an OS call) one needs to set up a stack frame. If you examine the Xcall macro you'll see we store (as you're investigations have found) some registers ABOVE the current stack pointer, so when we get control back we can restore our toc ptr etc. Also the routine we are calling will assume we have set up space for it to dump parameters into should it need to. So if we just pushed stuff onto the stack and then did an Xcall you can hopefully see that Xcall would possibly store it's current toc etc. over your pushed data leading to corrupt data on the stack. Thus, by all means push and pop onto the stack, BUT if you are going to call a C (OS function for example) function make sure you have the sp pointing to a valid stack frame. Either create one or ensure everything you have pushed is popped. In Fantasm, as soon as your assembly language program executes the start_up macro the stack is pointing to a valid empty stack frame created by stwu sp,-64+88(sp) . The +88 is because we have stored r10 to r31 in this space. As a side note, there is some debate about whether we need to save the registers at all. You may ask why don't we get Xcall to set up the stack frame? Speed is the main reason. By assuming a stack frame already exist immediately at the sp we do not need the instruction(s) necessary to allocate before and "tear down" a frame after a call to a C function. Of course, the Power PC does not have a hardware stack like the 68k (I know it's debatable :-)) so feel free to institute your own stack either via a few subroutines or macros. Just get some memory, point a register to the top of it and push and pop away. The best way of course is to avoid memory like the plague and use all those lovely registers! Stack frames and calling conventions are explained in detail in Inside Mac PowerPC system software. I hope this helps you out and nice diagram BTW! Stu.
Date: Fri, 14 Nov 1997 06:05:15 +1000 From: mrwhippy@pac.com.au To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Macsbug Help Hello , I've finally made the jump to PPC assembler,but when I use macsbug,I can still only see the 68k registers.Is there some simple command I'm missing that displays the PPC registers? I'm using version 6.5.2. Help! Thanks in advance Paul
Date: Thu, 13 Nov 1997 22:30:22 +0100 From: "MoonDark" <moondark@telemacus.it> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Macsbug Help At 06:05 +1000 14/11/1997, mrwhippy@pac.com.au wrote: >I've finally made the jump to PPC assembler,but when I use macsbug,I can >still only see the 68k registers.Is there some simple command I'm missing >that displays the PPC registers? I'm using version 6.5.2. Help! Be sure you're dropping into macsbug while PPC code is being executed, else you'll obviously see 68k code and registers only. The "Atvb" command would just do but you'd better use "Tvb" to avoid the annoying stepping process through ROM code. Best Regards, Mario
Date: Thu, 13 Nov 97 14:04:57 -0000 From: Kevin Avila <kevin@cache-computing.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Macsbug Help >I've finally made the jump to PPC assembler,but when I use macsbug,I can >still only see the 68k registers.Is there some simple command I'm missing >that displays the PPC registers? I'm using version 6.5.2. Well, your doing nothing wrong, that 68K stuff is the MacOS software doing it's thing in emulated mode, if you want to see your code, simple place a "DEbug" statment in your code and when you run your program you should drop into macsbug as PPC.
Date: Fri, 14 Nov 1997 13:57:28 +1000 From: mrwhippy@pac.com.au To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re:Re:Macsbug help Hello again, Many thanks to Mario and Kevin re my macsbug question.I'll have to go off and find something else to get stuck on now :) Cheers Paul
Date: Thu, 13 Nov 1997 21:58:44 -0500 From: Ajay Nath <AjayNath@compuserve.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Macsbug Help don't forget that you can type "?" in macsbug to get a list of commands that you can execute..one of them lets you toggle the mode that it drops into...either 68k or PPP...a quick look reveals that "r2db" will switch you to the PPC debugger
Date: Fri, 14 Nov 1997 14:29:06 +1000 From: mrwhippy@pac.com.au To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: CD access Hello, It didn't take too long to find something else to get lost in :) For reasons unknown,I want to write some code that opens the CD rom tray.I've found the information in inside mac re ejecting volumes which is all well and good if there's a CD in the drive,but unless I've missed something,this is no good if the drive is currently empty. Surely it must be possible to open the door without needing a CD to be in there first? Am I looking in the right place? If someone else here has already done this,could you let me know where in inside mac you found the info,please? Thanks, Paul
Date: Fri, 14 Nov 1997 17:28:12 -0500 From: Stuart Ball <lightsoft@compuserve.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Lightsoft - Fantasm bug report We have found a bug as detailed below. Whilst we believe it would be rare that a user would experience this bug we have published the details for your information and "just in case". BUG: PowerPC assembler prints some 5 digit negative numbers on pass 1 and when finished assembly reports the assembly failed but the error count reads zero and no error strings are reported. (You need to switch the assembler's "quiet mode" off to see the error count in the log window). Details: The PowerPC assembler in both PowerFantasm 4 and Fantasm 5 will reproduce this behavior whenever a SINGLE source file assembles to greater than 32k of code (i.e. pure instructions and not including data) and a backwards branch is assembled post the 32k mark. Work around: Keep the amount of code generated from a single source file below 32K. To Be Fixed? Fixed in Fantasm 5.1. Lightsoft 2210 14 Nov 1997.
Date: Mon, 17 Nov 1997 19:10:47 +1100 From: mrwhippy@pac.com.au To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Dialog boxes Hello All, I've been fumbling with dialog boxes today and trying to make them work via PPC assembler.I'm not begging for code because I've got the thing to work,but I need an answer to something related. I made my dialog resource in ResEdit,wrote some pointless text in it,and gave it an ok button.All seemed well... When I run the app,it displays the dialog box window,in the right place on the screen,but the pointless text and ok button are invisible.If you click where the ok button should be,it works and exits normally. Can anyone tell me why this might be happening? Any help/suggestions greatly appreciated. Paul
Date: Mon, 17 Nov 1997 22:18:16 +1100 From: mrwhippy@pac.com.au To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Boot sector Hello Does anyone have,or can anyone point me in the direction of some information about the boot sector on Mac disks,please? Thanks in advance, Paul
Date: Mon, 17 Nov 1997 10:05:59 -0500 From: Stuart Ball <lightsoft@compuserve.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Dialog boxes >Text not displayed in dialog box... >Can anyone tell me why this might be happening? > >Any help/suggestions greatly appreciated. You probably need to do something like this Paul: After the call to ShowWindow (DlgPtr) or whatever one is using, call WaitNextEvent (-1,evt rec ptr,1,0 or something similar) so the OS can update the window for you. Stu.
Date: Tue, 18 Nov 1997 09:18:23 +1100 From: mrwhippy@pac.com.au To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Dialog boxes (last time :) Hello, I found out what I was doing wrong.I had the dialog record bit set up wrong :( Thanks for the help,Stu. Paul
Date: Mon, 17 Nov 1997 17:50:11 -0500 From: Ajay Nath <AjayNath@compuserve.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Dialog boxes make sure your dialog items are marked as being visible...also use resedit to preview your dialog to make sure it is ok...if all this doesn't work then copy a dialog from another app & stick it in your app to see if it works
Date: Mon, 17 Nov 1997 22:18:16 +1100 From: mrwhippy@pac.com.au To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Boot sector Hello Does anyone have,or can anyone point me in the direction of some information about the boot sector on Mac disks,please? Thanks in advance, Paul
Date: Mon, 17 Nov 97 15:09:35 -0000 From: Kevin Avila <kevin@cache-computing.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Boot sector >Does anyone have,or can anyone point me in the direction of some >information about the boot sector on Mac disks,please? Take it from me, it's a royal pain in the ass. The best way to learn is to simply look at one. Open your System file with ResEdit (or the like) look at the 'boot' resource #1. That is a copy of the boot sector on the disk. Also note that if your on a PCI PowerMac (i.e. you have OpenFirmware) the boot sector is ignored by the newer Apple ROM.
Date: Tue, 18 Nov 1997 01:11:39 -0500 From: Stuart Ball <lightsoft@compuserve.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Boot sector > Take it from me, it's a royal pain in the ass. Spelling's getting better Kev! <G>
Date: Tue, 18 Nov 1997 21:40:55 +0000 From: robot@writeme.com (Alok) To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Dialog boxes >Hello All, > >I've been fumbling with dialog boxes today and trying to make them work via >PPC assembler.I'm not begging for code because I've got the thing to >work,but I need an answer to something related. > >I made my dialog resource in ResEdit,wrote some pointless text in it,and >gave it an ok button.All seemed well... > >When I run the app,it displays the dialog box window,in the right place on >the screen,but the pointless text and ok button are invisible.If you click >where the ok button should be,it works and exits normally. > >Can anyone tell me why this might be happening? > >Any help/suggestions greatly appreciated. > >Paul Hi, Well I have a question: How do you crete a dialog box with buttons under res edit? I know how to do alertes but not dialogs. COuld you send the res file pls? Thx Alok
Date: Thu, 20 Nov 1997 15:39:26 +1000 From: mrwhippy@pac.com.au To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: File access Hello all, I've started to have a look at file access,and it seems reasonably straightforward except for the most important part,ie the FSSpec / Parameter block bit.I am plum stuffed :) I just don't get it at all :( I like the sound of having more control over the process,but figuring out the parameter block information seems a much bigger nightmare,so I was thinking I'd try to get the hang of the FSSpec method first,then hopefully better armed,try to tackle the parameter block method. Could someone please explain how you get the vRefNum and FSSpec information that every process seems to ask for? I've browsed through some 68k source,but I want to do it in PPC.Sadly,reading through the 68k code has left me just as bewildered :( Any help,no matter how small,very gratefully accepted! :) Paul
Date: Thu, 20 Nov 1997 07:44:26 -0500 From: Stuart Ball <lightsoft@compuserve.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: File access Hi Paul, File access isn't that frightening once you get into your head you have many options available. Here's my major list of file handling do's for System 7 onwards. 1. If possible work with aliases. 2. If not, work with Fsspecs 3. Failing that, go for parameter blocks. Easy said, how to do? 1. Write a little routine that takes 4 paramters and returns an fsspec, viz: parm1: vrefnum - int16 parm2: DirID - int32 parm3: fname char(256) (It would be unwise to go for anything less) parm4: ptr to where you want the fsspec The routine actually just calls FSMakeFSSpec which takes the four parameters above (in that order weirdly). From the fsspec you can make an alias for persistent storage or pass the fsspec to various file handling routines you may need to use. Next, how to get the vrefnums and dirid's? Two ways: 1. The stdfile package returns these items in the sfreply item at offset 6 where you'll find an FSspec describing the object selected by the user. An FSspec looks like: volume reference number - VRefNum - int16 Directory ID - DirID - int32 Name - pstring 2. If you need to find files relative to your application you can get the fsspec of your application, then using the vrefnum and dirID along with your new filename create a new fsspec. Getting the fsspec of your application is a multistep process, viz: *************************************************************************** lea PIpsn(pc),a0 where our psn will go OSGetCurrentProcess a0,d0 lea PIpir(pc),a0 lea temp_string(a5),a1 *Fsspec of app into temp_string please move.l a1,56(a0) lea PIpsn(pc),a0 *ProcessInformationRecord lea PIpir(pc),a1 OSGetProcessInformation a0,a1,d0 lea PIpir(pc),a0 lea 56(a0),a0 point to Fsspec move.l (a0),a0 *->Fsspec data **Now you can pass the vrefnum and dirID along with your filename to make a new fsspec for a file in the same folder as your app.. ***Data PIpsn: ds.l 2 psn goes here PIpir: dc.l 60 process info rec goes here - length dc.l 0 we don't want the name ds.l 2 PSN dc.l 1 type dc.l 1 sig dc.l 1 flags dc.l 1 address of partition dc.l 1 size dc.l 1 dc.l 2 psn of launcher dc.l 1 date dc.l 1 active time ds.l 1 pointer to Fsspec ds.l 4 ******************************************************* Anyway, once you do have these three crucial items - an vrefnum, a dirid and a filename then you can use the parameter block based routines if you can't find a higher level routine to do the job. Normally when you need to call say pbgetcatinfo or any other pb based routine you only need to fill in the fields that are absolutely relevant - the OS will make do with what it's got so generally the vrefnum, DirID and ptr to filename are fine. Nearly always, these pieces of information go in the same place in the parameter block, viz: Ciocompletion: equ 12 long Cionameptr: equ 18 long Ciovrefnum: equ 22 word Ciodrdirid: equ 48 long Ciofdirindex: equ 28 word CioDRParID: equ 100 long CioFRefnum: equ 24 *file refnum on output from getcatinfo bsr.l clear_pb *always start with a clear pb lea temp_pb(a5),a0 *the pb clr.l Ciocompletion(a0) *no completion routine lea tpf_name(pc),a1 move.l a1,Cionameptr(a0) *poke the ptr to filename move.w tf_vrefnum(a5),Ciovrefnum(a0) *the vrefnum lea PMIps_fsspec(pc),a1 move.l 2(a1),Ciodrdirid(a0) *the dirid Call your PB based OS call If you do need to use pb based file calls I would strongly recommend you print out the filing system C header file or use think reference or similar to get the various pb layouts. If this is all too vague or general, just repost with specifics and sorry if this is disjointed but my wife is tidying up around me and yacking ON PURPOSE just to wind me up. Think I'll go walk the cats... Stu.
Date: Thu, 20 Nov 1997 18:04:45 +0000 From: robot@writeme.com (Alok) To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: HTML Hi, Is there a way of using FileMaker Pro files in a web page with the search features? If yes, how? Bye, ALok
Date: Thu, 20 Nov 1997 17:56:31 -0500 From: Stuart Ball <lightsoft@compuserve.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: A result! Thought you might all like to know that Benny got his midi code working - thanks to all who helped, 'specially Malcolm. >Hi Stu! > >The MIDI code that Malcolm Sharman sent me is working!!! And I am very >happy. > >I am now working on a PowerPC assembler version. Thanks for all help >with this.
Date: Fri, 21 Nov 1997 18:22:12 +0000 From: Benny Ronnhager <benny.ronnhager@soderhamn.mail.telia.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Help me please to convert 68000>PowerPC Hi! I am trying to convert MIDI source from 68000 to PowerPC source. But I am not able to convert all instructions. I need some help. Most of the instructions are doing things with the stack. Best regards Benny benny.ronnhager@soderhamn.mail.telia.com MOVE.L #0,-(SP) MOVE.L (SP)+,D0 MOVE.W D0,-(SP) MOVE SR,-(SP) MOVEM.L D0/A0-A2,-(SP) ORI #$0300,SR MOVE.L (SP),(SP) MOVE.L 0(A0,D0),(A1) MOVE.L A1,0(A0,D0) MOVEM.L (SP)+,D0/A0-A2 MOVE (SP)+,SR LINK A6,#0 TST.B (A3) MOVE.B 9(A6),0(A2,D0) BTST.B #0,0(A0,D0) UNLK A6 MOVE.L #0,8(A6) MOVE.L 0(A2,D0),D1 MOVE.L D1,8(A6) MOVE.L D1,0(A2,D0) BTST.B #0,(A0) MOVE.B 0(A2,D0),0(A1,D1) ANDI #$F8FF,SR
Date: Sat, 22 Nov 1997 00:25:20 -0500 From: Stuart Ball <lightsoft@compuserve.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: NFtT 22nd Nov 1997 News From the Tower 22nd Nov '97. --------------------------------- Here's another one of those rather irregular news posts we put out from time to time, letting you know what's happening and coming up. These go out fairly infrequently so it's not exactly spam city, but if you do find this mail annoying, please get thee hence to <http://www.tau.it/lightsoft/links.html> where you may unsubscribe from this list. X-----------------X 1. Fantasm 5 tips/bugs/questions 2. Site updates this week 3. Other/Misc. news 4. Forthcoming... X-----------------X 1. Fantasm 5 tips. Here is this weeks "problems and tips" from users for your information (edited for brevity): a). >"Every time I start a build, Anvil gives me a very cryptic dialog box with just a >generic Mac error code - no explanation string at all. The code given is -43 which is >a file not found error. >I finally worked it out - I had moved an old file to the trash. What I didn't >realize was that the file I had moved was still "included" into one of my source >files. Even so, a *%$&(*&! explanation message would have been nice!" Yes, we agree. The DDBACC tool is not sending it's identifier or a reasonable explanation for the error to the "front end" so you don't get the "Message from DDBACC" title to the dialog box, instead you get a generic Build error. This we appologize for and will fix in the next version. b). >Fantasm keeps giving me a "macro not defined" error for one of my "includeh" lines. >I traced this one to the fact that I had a label on the same line as the >includeh directive. This is a long standing "limitation" of Fantasm. The included files are picked out and merged during a preprocessing phase - and labels mean nothing to the preprocesor. If it does find an include directive with a label it will leave it alone and not include the file. Fantasm itself has no idea about include directives and eventually gives up assuming the identifier must be an undefined macro. This behaviour is documented on page 38 of LSA0040. c). >Do you plan on having a version of Fantasm that will take advantage of COS? If COS does appear, and, as they say, it does have a custom API, and it offers all the benefits of the normal MAC OS and they don't get sued to death, then we'll certainly investigate taking advantage of any goodies COS offers. d). >No matter what I try, I simply can't get a file with no code in it to link. I >really want to have all my data separate, but it seems as if I have to put a dummy >piece of code in to get it to link. It's not a major problem, but why? You took out >the need for a global definition in link files with these new linkers - can't you >remove this restriction as well?" There appears to be no good reason why the linker requires some code. Maybe we were a little paranoid when error checking/divide by zero's? We'll look into getting it fixed in the next release. e). > Anvil does not appear to be compatible with the Japanese Language Kit. Thank you, we will fix that in the next release. f). >Hello and greetings, > >I just wanted to say that I'm very impressed that you chose to offer a >special price for youth, and low-income persons!! Much of the software >industry lacks any kind of social conscious whatsoever, and here in the >US, virtually everyone lacks the slightest bit of class consciousness. >You are to be commended for making an issue of it. OK, so this isn't a Fantasm problem or tip, but we thought it nice. -------------- 2. Site updates this week Nothing major has gone on. We uploaded a new demo a few days back, published pricing details for students, those under 18 and on low incomes. A new section "Dear diary" has been started and we linked with the "Mac Programmers Web Ring" which isn't fully operational yet. -------------- 3. Other news You can play "Spot the Lightsoft advertisment" in MacFormat next month - out 11th Dec. -------------- 4. Forthcoming... Fantasm 5.1, LXT add on for Fant 5.1. Still no concrete news on Fanta_C. Fantasm 5.1 just rounds out Fantasm 5. It'll fix the few minor bugs that crop up and look a bit smarter. There are some new directives to allow macros to override instructions and better macro handling and facilities. Soft linking to import libraries is also planned. If all goes well the whole lot will be FAT and for the very first time ever may even run on 68000 machines (theoretically only - a fast 040 is the recommended minimum). Interestingly, because it is written with itself in assembly language, we do not expect to gain much of a speed boost in the fully native version. We may be suprised though. LXT is a translation add on set for Fantasm 5.1 that auto converts 68K source to a PowerPC fragment. Just merge the LXT PPC project with 68K one, or vice versa and get a fat app from 68K source. ----------------------- Comments, feedback and announcements for inclusion in NFtT can be sent to either of our normal addresses. We reserve the right to edit and snip as necessary. END Lightsoft 0500 22 Nov 97
Date: Sat, 22 Nov 1997 04:02:37 -0800 (PST) From: Allan Jensen <maccoder@yahoo.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Intersecting lines I think this is so simple that Im ashamed to ask, but (deep breath): How do you find out if two lines are colliding (intersecting)? The lines are defined in the format (x1,y1)(x2,y2), and I want to know if it collides with another of the same form. I saw one way to do it in the an algorithm faq, but it seemed way too complicated. I think I could work it out with a pencil and some graph paper, but I havent got the graph paper (or a pencil, would you believe). I seem to remember this being fairly low on the elementary school scale of complexity, but I just cant remember how. Anyone? Romeo (Definitely not Allan, whos knowledge of math is exceptional) P.S. If anyone feel the need to give me a long personal letter really explaining the ins and outs of math, my e-mail adress is maccoder@post6.tele.dk. I had to resort to yahoo mail, since tau.it has been cancelled from my mailserver for a short time because of some very nasty spammers (or so I was told). I can still recieve mail from tau.it ... go figure.
Date: Sat, 22 Nov 1997 14:09:12 +0000 From: robot@writeme.com (Alok) To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: (No subject) 3) Check each field and check if the date of birth is within 3 days. 4) If yes, display that name and go on Basically I need this script for my school's web page. Another script I need is a VR MAP script. Basically it's for a virtual visit of the school. Each image is a 360 degree photo (where the left end matches with the right end). What I want the script to do is display part of this image and allow the user to rotate it from left to right or from right to left. Plus the picture contains a map. So if you click on a door, it must execute a link. I hope you can help me by writting these scripts or helping me find someone who can write them. Thanks for helping. Alok
Date: Sat, 22 Nov 97 13:04:35 -0000 From: Kevin Avila <kevin@cache-computing.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Intersecting lines >How do you find out if two lines are colliding (intersecting)? >The lines are defined in the format (x1,y1)(x2,y2) You might be able to use SectRect, the C calling convention is: if ( SectRect ( &rect1, &rect2, &resultRect ) ) if SectRect returns TRUE then they are colliding, FALSE if not.
Date: Sat, 22 Nov 97 19:17:26 -0700 From: James Hague <jhague@dadgum.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Intersecting lines >How do you find out if two lines are colliding (intersecting)? >The lines are defined in the format (x1,y1)(x2,y2) I'm not sure if you are talking about lines or line segments. Checking for intersection of lines is easy. Line segments, though, are messier. I would guess that you're confusing the two somewhat, which is why you were surprised at the complexity of the line segment intersection algorithm you found.
Date: Sun, 23 Nov 1997 02:31:09 -0800 (PST) From: Allan Jensen <maccoder@yahoo.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Intersecting lines >>How do you find out if two lines are colliding (intersecting)? >>The lines are defined in the format (x1,y1)(x2,y2) >I'm not sure if you are talking about lines or line segments. Checking >for intersection of lines is easy. Line segments, though, are messier. >I would guess that you're confusing the two somewhat, which is why you >were surprised at the complexity of the line segment intersection >algorithm you found. After a good nights sleep, I may have stumbled over the blatantly obvious solution A few compares to see if the two coordinate-sets are within the same boundry (check if the other line is between x1,x2 and y1,y2). Is this the fastest solution? I just convinced myself I needed to solve some equations. Having said that, I'm not sure I see the difference of a line segment and a line. Both would have the same equation, and could be solved the same way as above? Or maybe I'm confused about line segments? Allan
Date: Sun, 23 Nov 1997 13:37:24 +0000 From: robot@writeme.com (Alok) To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Intersecting lines >I think this is so simple that Iim ashamed to ask, but (deep breath): > >How do you find out if two lines are colliding (intersecting)? >The lines are defined in the format (x1,y1)(x2,y2), and I want to know >if it collides with another of the same form. > >I saw one way to do it in the an algorithm faq, but it seemed way too >complicated. I think I could work it out with a pencil and some graph >paper, but I havenit got the graph paper (or a pencil, would you >believe). > >I seem to remember this being fairly low on the elementary school scale >of complexity, but I just canit remember how. > >Anyone? > >Romeo (Definitely not Allan, whois knowledge of math is exceptional) > >P.S. If anyone feel the need to give me a long personal letter really >explaining the ins and outs of math, my e-mail adress is >maccoder@post6.tele.dk. I had to resort to yahoo mail, since tau.it >has been cancelled from my mailserver for a short time because of some >very nasty spammers (or so I was told). I can still recieve mail from >tau.it ... go figure. Hi, Well I think I have an idea. The two segments are [AB] and [CD] If you connect A with C with B with D with A, you get a quadrilatere. Now if it's connexe, there is intersecion. Now to check that, you must calculate the angles. If angle ADB, ACB, DAC or DBC is greater than 180 than there isn't any intersection. If it's 180, one point is on a line. Of course, this methode won't help you know if two lines are intersecting on the screen (pixel wise). Bye, Alok
Date: Mon, 24 Nov 1997 01:26:02 +1200 From: Steven Brown <sgb@wave.co.nz> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Intersecting lines >>How do you find out if two lines are colliding (intersecting)? >>The lines are defined in the format (x1,y1)(x2,y2) ... >Having said that, I'm not sure I see the difference of a line segment >and a line. Both would have the same equation, and could be solved the >same way as above? Or maybe I'm confused about line segments? > >Allan In standard Euclidean geometry, lines go on forever and 2 lines (in the same plane) will always have an intersection unless they are parallel. Line segments have a definite beginning and ending, they are parts of lines. A line could be defined as passing through 2 points (x1,y1) and (x2,y2), while a line segment could be defined as starting at (x1,y1) and ending at (x2,y2). Two lines ((x1,y1)(x2,y2) and (x3,y3)(x4,y4)) will be parallel if their slopes are equal ((x1-x2)/(y1-y2)=(x3-x4)/(y3-y4)), otherwise they will intersect at some point. For 2 line segments to intersect, the point at which the 2 lines defined by the beginning and ending points of the line segments intersect, would need to fall within both line segments. Steven
Date: Sun, 23 Nov 1997 14:44:24 +0100 From: "MoonDark" <moondark@telemacus.it> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Intersecting lines At 02:31 -0800 23/11/1997, Allan Jensen wrote: >After a good nights sleep, I may have stumbled over the blatantly >obvious solution >A few compares to see if the two coordinate-sets are within the same >boundry (check if the other line is between x1,x2 and y1,y2). Is this >the fastest solution? >I just convinced myself I needed to solve some equations. >Having said that, I'm not sure I see the difference of a line segment >and a line. Both would have the same equation, and could be solved the >same way as above? Or maybe I'm confused about line segments? Well, I'm not sure this is what you're looking for, anyways: line equations may have 2 known forms, the express forms will either be y=mx or y=mx+q, in the second case, our line will not pass by the origin of the axis, you can obtain the coordinates of the collision point ( IF any ) by using a simple algebra system, on a substitution, Kramer or compare implementation, in your case, I'd suggest the last. Let's assume line r is y=6x + 8 and r' is y=3/4x + 9 we may want to use the compare system as we already have our coordinates by y, so it'll be 6x + 8 = 3/4x +9 Solving this first grade equation will provide you the x coordinate of the collision point, then you'll have to replace the value for x you've found into the primary equation and you'll obtain the y coordinate of the collision point, say R (7;9). If the equation will show impossible, then the lines don't collide. However, Kev's suggestion sounds better =) Best Regards, Mario
Date: Sun, 23 Nov 1997 11:38:30 -0500 From: Scott Lahteine <slur@world.std.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Intersecting lines >I think this is so simple that Im ashamed to ask, but (deep breath): > >How do you find out if two lines are colliding (intersecting)? >The lines are defined in the format (x1,y1)(x2,y2), and I want to know >if it collides with another of the same form. > >I saw one way to do it in the an algorithm faq, but it seemed way too >complicated. I think I could work it out with a pencil and some graph >paper, but I havent got the graph paper (or a pencil, would you >believe). > After lots of remedial algebra my friend and I came up with this snippet of C code to do the trick, which I presume is NOT for the simple case of infinite line segments: SetRect(&aRect, ax1, ay1, ax2, ay2); SetRect(&bRect, bx1, by1, bx2, by2); ainfinity = (ax2 == ax1); binfinity = (bx2 == bx1); if ( !ainfinity ) { aslope = (ay2 - ay1) / (ax2 - ax1); aoffy = ay1 - aslope * ax1; } if ( !binfinity ) { bslope = (by2 - by1) / (bx2 - bx1); boffy = by1 - bslope * bx1; } if ( !ainfinity && !binfinity ) { if (aslope != bslope) { x = (boffy - aoffy) / (aslope - bslope); y = aslope * (boffy - aoffy) / (aslope - bslope) + aoffy; if ( PtInRect(&aRect, x, y) && PtInRect(&bRect, x, y) ); intersect = true; } else { if (aoffy == boffy) if ( SectRect ( &arect, &brect, &tempRect ) ); intersect = true; } } else { if ( ainfinity ) ( if ( binfinity ) { if (ax1 == bx1) intersect = true; } else { y = bslope * ax1 + boffy; if ( ( y >= ay1 && y <= ay2) || ( y >= ay2 && y <= ay1) ) intersect = true; } } else if ( binfinity ) ( y = aslope * bx1 + aoffy; if ( ( y >= by1 && y <= by2) || ( y >= by2 && y <= by1) ) intersect = true; } } If only it could be simple. Unfortunately SectRect will not work for some cases, say for example with a 'y'-shaped pair of lines. So this routine treats your lines as infinite length, solves for the point where they cross, deals appropriately with lines with slope of infinity and parallel lines. If you need the length of a line use length = sqrt( (x2 - x1) ^ 2 + (y2 - y1) ^2). Scott Lahteine
Date: Sun, 23 Nov 1997 14:25:59 -0800 (PST) From: Allan Jensen <maccoder@yahoo.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Intersecting lines Thanks to everyone for the suggestions. As it turned out, it was line segments I was dealing with instead of lines of infinite length. Truth be told I didnt sleep *that* well, which might be the reason why my own suggestion was less than useful (yes, a line segment can lie within the boundries of another line without intersecting it, but I guess you all knew that). The best and fastest solution seemed to come from Scott Lahteine & friend. Thanks, exactly what I needed, except ... Im not a fan of system-calls ;) So: what exactly does SetRect, SectRet and PntRect do (so I can make them myself)? Would I be wrong in assuming that Setrect defines a rectangle by (x1,y1)(x2,y2). PntRect returns true if x and y if within the rectangle defined before, and Sectrect determines if two sectors are colliding? Im probably wrong (especially about the last one, or that check would have been first?) Thanks everyone Allan P.S. I was glad to see it was *that* simple
Date: Mon, 24 Nov 1997 17:28:07 +1000 From: mrwhippy@pac.com.au To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Gestalt Hello, I know this is a lot less high brow than the recent intersecting line thing,but could someone help me,please? If you want to play with gestalt functions,you need to supply a type,such as "sysv" to find the OS version.I've tried the following,but it always returns 0. Could someone tell me what I'm doing wrong? Be gentle :) lwz r3,Type(rtoc) la r4,Response(`bss) Xcall Gestalt lwz r10,Response(`bss) Type: dc.b 4,"sysv" Response: rs.w 1 Thanks in advance, Paul
Date: Mon, 24 Nov 1997 04:31:15 -0400 From: mikobe@tallships.istar.ca (Meikal Oestebo) To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: How to Unsubscribe? If the listmom, or some other good soul who knows how, could they please give me the address and instructions for unsubscribing from this list? Thanks. I have given up on assembly as it has proven too complicated for my meger mind. Have settled into CrossBasic instead. Much more my speed! Many thanks to all for their help in the past. I'm afraid I just didn't have what it takes to cross that elite line into Assembler-Hood. My hat is off to all of you! Mike.
Date: Mon, 24 Nov 1997 22:00:21 +1000 From: mrwhippy@pac.com.au (Paul) To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Sound resources Hello again, What a surprise - I'm back again.I thought I almost had this for a second,but 99 revisions and re-builds later,it still doesn't do anything worthwhile :( It assembles fine.I paste the sound resource into it,double click it, then..... nothing.At least it doesn't lock up :) Could someone point out some stupid,simple error(s) I'm making,please? Then I think I'll lay low for a while. (At least 24 hours without using this mailing list :) Thanks again, Paul BTW- Am I the only one who finds Inside Mac to be just a touch under-helpful at times? With the difference between my questions and some of the others I've read on this list,I tend to feel a bit like a dumb kid standing among the rocket scientists :) lis r4,"sn" ori r4,r4,"d " li r5,128 Xcall Get1Resource la r3,SoundResourceHandle(`bss) ;------------------------------- la r3,Channel(`bss) li r4,0 li r5,0 li r6,0 Xcall SndNewChannel stw r3,SoundChannelHandle(`bss) ;------------------------------- li r3,0 la r4,Channel(`bss) la r5,SoundResourceHandle(`bss) li r6,-1 Xcall SndPlay ;------------------------------- SoundResourceHandle: rs.w 1 SoundChannelHandle: rs.w 1 Channel: rs.w 1
Date: Mon, 24 Nov 1997 20:47:52 -0500 From: Ajay Nath <AjayNath@compuserve.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Sound resources well i didn't bother to look thru all the code you posted because i think i found the source of soe of your errors.. you have << Xcall Get1Resource la r3,SoundResourceHandle(`bss) << i think you want to use stw r3,SoundResourceHandle(`bss) which will store the handle in SoundResourceHandle probably the rest of the problems that you are having are related to this error
Date: Mon, 24 Nov 1997 22:19:28 +0000 From: robot@writeme.com (Alok) To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Intersecting lines >>How do you find out if two lines are colliding (intersecting)? >>The lines are defined in the format (x1,y1)(x2,y2) > >I'm not sure if you are talking about lines or line segments. Checking >for intersection of lines is easy. Line segments, though, are messier. >I would guess that you're confusing the two somewhat, which is why you >were surprised at the complexity of the line segment intersection >algorithm you found. Hi, What's a line segment? A segment? And a line? A droite how we call it here in French? This thing that's an alinment of infinity points? In both cases, it's quit simple to solve. Bye, Alok
Date: Mon, 24 Nov 1997 15:11:34 -0500 From: Scott Lahteine <slur@world.std.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Intersecting lines >Thanks, exactly what I needed, except ... Im not a fan of >system-calls ;) Yes, they can be a bit slow, and you never know if there isn't some emulation going on. >So: what exactly does SetRect, SectRet and PntRect do (so I can make >them myself)? >Would I be wrong in assuming that Setrect defines a rectangle by >(x1,y1)(x2,y2). PntRect returns true if x and y if within the >rectangle defined before, and Sectrect determines if two sectors are >colliding? Im probably wrong (especially about the last one, or that >check would have been first?) SetRect does as you assume. SectRect returns true for rects that intersect and also returns the rect which is the intersection. PtInRect returns true if the Point (h+1, v+1) is inside the Rect. And yes, the SectRect would best be done first, and this would obviate the need for the final SectRect check. Admittedly this was a slapped-together routine. To get rid of the non-integer stuff (i.e., aslope) you can do anum = (ay2 - ay1); aden = (ax2 - ax1); and use "y = (x * anum) / aden" in place of things like "y = x * aslope." In assembler you can get pretty accurate results when you take the remainder into account in your comparisons. Scott Lahteine
Date: Mon, 24 Nov 97 11:24:19 -0700 From: James Hague <jhague@dadgum.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Sound resources >BTW- Am I the only one who finds Inside Mac to be just a touch >under-helpful at times? With the difference between my questions and some >of the others I've read on this list,I tend to feel a bit like a dumb kid >standing among the rocket scientists :) The info is all there, but Inside Mac is far too wordy and repetitive for my tastes (and full of dumb commentary like "you should never use this routine" :-)
Date: Tue, 25 Nov 1997 14:41:56 +0000 From: robot@writeme.com (Alok) To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Sound resources HI, Here are my tips: a) Look in the beginner's guide to power PC assembly in the middle (or rather 2/3) b) Ask me if you want some 68k code. Bye, ALok
Date: Tue, 25 Nov 1997 15:36:24 +0100 From: Allan Jensen <maccoder@post6.tele.dk> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Inside Mac essential? Paul wrote: > BTW- Am I the only one who finds Inside Mac to be just a touch > under-helpful at times? With the difference between my questions and some > of the others I've read on this list,I tend to feel a bit like a dumb kid > standing among the rocket scientists :) In some recent posts, it has been stressed that Inside Mac is essential. I'd say it was only 'rather nice to have'. I suppose it depends on your style of coding (and what you're coding). In my most recent project I think the number of system routines called so far wouldn't number more than 5 or 6 (dealing with memory and the CLUT). Having said that, I also break at least 4 of Apple's '10 golden rules of writing directly to the screen'. I only have a few of the Inside Mac files, and I haven't really read them yet. I suppose when the times comes, and I have to think about compatibility, the answer will be: not very. I'm not sure how 'close to metal' it's okay to go. On the good ol' Amiga, Commodore spend a lot of time trying to make people use system calls. Not many people did, and it still worked out okay. As far as I can tell, the example game that came with Fant 5, is done more or less without too many systemcalls, and it works fine (although it does freeze up my Mac at exit ;)). So, to the guys who program big applications/game: How big an issue is compatibility? How close to metal can you go (weird expression, I know)? An important point if you're programming in assembler, and are tempted to do the whole thing yourself. Allan
Date: Tue, 25 Nov 1997 13:12:57 -0500 From: Scott Lahteine <slur@world.std.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Intersecting lines >What's a line segment? A segment? > A straight line is a circle with a radius of infinity. A line has infinite length. A segment has boundaries defined by "endpoints." A segment - in general - is a portion of a whole. >In both cases, it's quit simple to solve. > Pretty simple for 5% of the world population, irrelevant to the rest. Scott Lahteine
Date: Tue, 25 Nov 97 21:23:14 -0700 From: Jessica Hague <jhague@dadgum.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Inside Mac essential? >So, to the guys who program big applications/game: How big an issue is >compatibility? How close to metal can you go (weird expression, I know)? >An important point if you're programming in assembler, and are tempted >to do the whole thing yourself. Writing to the screen is no big deal; I have yet to see a single compatibility problem on Power Macs (it was mildly stickier on old 68K machines, because different machines used slightly different formats for screen memory, or so I'm told). I don't see a need to go to the metal in any other ways. Well, you can bypass most of the sound routines by using SndPlayDoubleBuffer and doing the mixing yourself. I did this, but I'm not sure if it was worth it, truth be told. On newer Power Macs with video acceleration, there's a definite speed benefit to using CopyBits. But (1) writing your own blitter is easier than using GWorlds, in my own strange opinion; and (2) on machines like the G3, your own blitter may be slower than the system's, but it's gonna fly anyway :-)
Date: Thu, 27 Nov 1997 17:18:24 +0100 From: robot@writeme.com (Alok) To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Help HI, I just switched on my Mac and surprise: a) The screen was set to 640*480 instead of 1024*7?0 but switched to 1024 after booting. b) My clock was showing 27/08/56 (instead of 27/11/97). c) My speakers were making a strange noise until I press the volum up botton. d) A window came up telling me to set back the time, cos it wasn't showing the correct time. SO what happened? Nothing else was lost. Bye, Alok
Date: Wed, 26 Nov 1997 18:10:10 +0000 From: Benny Ronnhager <benny.ronnhager@soderhamn.mail.telia.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Machine State Register? Hi! I wonder if someone can help me with this code. I want to disable and enable interrupts in PowerPC assembler. I suppose it is the EE bit in the MSR I should play with (in supervisor mode), but how? How do I return from interrupt? With the RFI instruction? The code here is in 68000 assembler. YES, I know that you know that :-) --- MOVE SR,-(SP) ; save interrupts ORI #$0300,SR ; disable interrupts ; do what you have to do... MOVE (SP)+,SR ; enable interrupts RTS ; and return --- Best regards Benny
Date: Wed, 26 Nov 1997 19:40:23 +0000 From: Benny Ronnhager <benny.ronnhager@soderhamn.mail.telia.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: HELP, MY MAC IS DEAD!!! Hi! Here comes a little tip. I don't realy know if anyone need it but... Some month ago my PowerMac 6100/60 died. I was very sad. Read on... One day when I turned on my Mac the time was wrong. 3-4 days later the screen was black. And I was starting to think, OK, a new Mac but I have no money! HELP!!! Lucky me, it was not a big problem with my Mac, just a battery change. My Mac was 3 years old when this happened. A month later the same thing happened with my friend's computer (PowerMac 6100/60). I just thougt you would like to know. Best regards Benny
Date: Wed, 26 Nov 97 12:10:39 -0000 From: Kevin Avila <kevin@cache-computing.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Machine State Register? >I wonder if someone can help me with this code. I want to disable and >enable interrupts in >PowerPC assembler. I suppose it is the EE bit in the MSR I should play >with >(in supervisor mode), but how? How do I return from interrupt? With the >RFI instruction? >The code here is in 68000 assembler. YES, I know that you know that :-) Well, first you have to get into supervisor mode (this means the MacOS can NOT be running) so I don't know what your trying to do, however, here is code to enable/disbale them: _disable_interrupts: mfmsr r0 li r3, 0 ori r3, r3, MSR_EE andc r0, r0, r3 mtmsr r0 sync blr _enable_interrupts: mfmsr r0 ori r0, r0, MSR_EE mtmsr r0 sync blr
Date: Wed, 26 Nov 97 12:11:44 -0000 From: Kevin Avila <kevin@cache-computing.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Help >SO what happened? Dead internal battery, replace it, you can get one at Radio Shack or any electronics store.
Date: Wed, 26 Nov 1997 21:12:20 +0100 From: "MoonDark" <moondark@telemacus.it> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Help At 17:18 +0100 27/11/1997, Alok wrote: >I just switched on my Mac and surprise: > >a) The screen was set to 640*480 instead of 1024*7?0 but switched to 1024 >after booting. > >b) My clock was showing 27/08/56 (instead of 27/11/97). > >c) My speakers were making a strange noise until I press the volum up botton. > >d) A window came up telling me to set back the time, cos it wasn't showing >the correct time. > >SO what happened? Nothing else was lost. That's the PRAM, even if things seem to work fine now, zap it anyway. Best Regards, Mario
Date: Thu, 27 Nov 1997 22:39:19 +1000 From: mrwhippy@pac.com.au (Paul) To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: File renaming Hello, I included the "Files.def" file and made a call to FSpRename.When I tried to build the file,it caused the following error... ***Error*** 'PBSetAltAccessAsync' is not exported in any of the shared libraries being linked to.Please ensure you have the correct shared libraries selected. Could someone please tell me why? I didn't make any calls to PBSetAltAccessAsync,so why is it causing this error? Thanks, Paul
Date: Thu, 27 Nov 1997 08:45:20 -0800 (PST) From: robot@writeme.com (Alok) To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: By batt is under the mother board!!! Hi, I contacter a guy who told me that my battery will cost 18 bucks (it's ok) but he said it's located under the motherboard so it'll cost me about 40 bucks to change it!!! WHat's this! I can't believe it! Pls tell me it's not true. Bye, Alok
Date: Thu, 27 Nov 1997 08:45:04 -0800 (PST) From: robot@writeme.com (Alok) To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Help me Hi, Well each startup destroys my clock and date and screen setup. (and also sound setup). WHat's the prob? Internal battery? How can I change it? (I have got a powermac 5200). How much does a new one cost? Is it dangerous for things like my hard disk set ups? May I lose files if I don't change it quickly? Bye, Alok
Date: Thu, 27 Nov 1997 20:12:06 +0000 From: Benny Ronnhager <benny.ronnhager@soderhamn.mail.telia.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: SUPERVISOR MODE? Hi Kevin Avila! Thanks for the code. The thing I am trying to do is to convert MIDI code from 68000 to PowerPC assembler. The reason for disable interrupt is because I am going to replace the Tx and Rx vectors for the SCC ship to my own vectors so I can take care of the interrupt myself. How do I get into supervisor mode in PowerPC assembler? And what are SYNC doing? _disable_interrupts: mfmsr r0 li r3,0 ori r3,r3,MSR_EE andc r0,r0,r3 mtmsr r0 sync blr _enable_interrupts: mfmsr r0 ori r0,r0,MSR_EE mtmsr r0 sync blr
Date: Thu, 27 Nov 97 14:54:58 -0000 From: Kevin Avila <kevin@cache-computing.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: SUPERVISOR MODE? >How do I get into supervisor mode in PowerPC assembler? >And what are SYNC doing? The sync just makes sure that the ppc does not start to do other before the supervisor code finishes, because normal instructions usualy only take one cycle, but most supervisor level instructions take 3 cycles to compleate. Here is a asm function in C to enter supervisor mode. If you goto the lightsoft web site and look though the mailing lists archives, I posed this same code with commets that might help you. You must understand however that the MacOS CAN NOT be loaded when you switch, which means you don't have access to the mac toolbox on powerpc, however, you can run the macos in supervisor mode in 68K machines, anyway, here's the code. asm void TakeOver ( register Ptr kern, register long kernelSize, register bootVars* vars, register void *theToc, register long tocSize, register void *proc, register void *kernelentry ) { stw kern, 0x40(r0) stw kernelSize, 0x44(r0) stw vars, 0x48(r0) stw theToc, 0x4C(r0) stw tocSize, 0x50(r0) stw kernelentry, 0x54(r0) // F*ck Gary and his birthday, im doing it my way. lwz proc, 0(proc) lis r30, 0x6000 subi r30, r30, 0x1c8c stw proc, 0(r30) sync @1: b @1 // We never get here blr }
Date: Fri, 28 Nov 1997 13:27:02 +1000 From: mrwhippy@pac.com.au (Paul) To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Import Hello, How does the IMPORT macro work? I want to be able to Xcall some functions that aren't defined in any of the header files,and I don't know where to start. How is this macro structured,and where does it IMPORT from? Any suggestions? Thanks in advance, Paul
Date: Fri, 28 Nov 1997 02:48:00 -0500 From: Stuart Ball <lightsoft@compuserve.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Import Paul wrote: >Hello, > >How does the IMPORT macro work? I want to be able to Xcall some functions >that aren't defined in any of the header files,and I don't know where to >start. >How is this macro structured,and where does it IMPORT from? Any suggestions? > >Thanks in advance, > >Paul Hi Paul, Xcall provides in-line code to set up the toc and save some stuff before calling an OS routine. It is defined in LS_PPC_macros.def Check with a reply I made a few days back about the PPC stack for some more info. The import directive tells the assembler to export a given label to the linker which tries to bind with the system shared libraries at the end of the static link to verify your fragment will dynamically link to the system libs. If you needed to call a function not currently defined in any of the definition files, you simply import it in the file you wish to call it from then Xcall the function after setting up the parameters needed. For example suppose Apple had just released a new library called MakeCoffee and one of the functions exported from that library was Coffee_Strength then you could call it as: import Coffee_Strength li r3,3 *how strong? Xcall Coffee_Strength You may like to wrap the import in a conditional to prevent possible errors, viz: ifnd Coffee_Strength *If we haven't imported this label import Coffee_Strength *Import it endif Just as a side note - most filing system calls can either be Sync or Async and they end as such: PBGetCatInfoSync or PBGetCatInfoAsync Hope this explains? Stu.
Date: Sat, 29 Nov 1997 15:54:56 -0500 From: Ajay Nath <AjayNath@compuserve.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: SUPERVISOR MODE? can't you just use apples midi code?
Date: Sat, 29 Nov 97 13:41:24 -0000 From: Kevin Avila <kevin@cache-computing.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: the supervisor solution Benny, Please take a look at http://devworld.apple.com/ngs/lpp/adrpub/docs/dev/techsupport/insidemac/Pro cesses/Processes-120.html. It has all the information you need to run your software ontop of interrupts, while it's not PowerPC spesfic, it does work just as well on both chips.
Date: Sun, 30 Nov 1997 13:15:41 +1000 From: mrwhippy@pac.com.au (Paul) To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Put pixel ? Hello, Once again,I have some PPC code that doesn't work :) I'm trying to get a simple put pixel routine.I fully understand the concept and know how to do it in theory,but I'm obviously coding it wrong :( I've narrowed it down to one of two things.I'm either not getting the absolute VRAM address properly and it's writing to the wrong memory,or I'm not using the right instruction to actually load the byte when I've found the correct VRAM address. (Not that there's anything else...except for that magical element that makes sure everything I code doesn't work :) Assuming I've got the right address,would I use an "stb" instruction? Thanks, Paul ------------------------------------------------------------------------------- Xcall GetMainDevice stw r3,GDeviceHandle(`bss) lwz r3,(r3) lwz r3,GdPMap(r3) lwz r3,(r3) lwz r10,(r3) ;Is this the absolute VRAM address? --------------------------------------------------------------------- li r3,500 ;The x value li r5,1024 ;width of 1 screen row mulli r6,r5,5 ;multiply it by the y value add r6,r6,r3 ;add the x value to it add r10,r6,r10 ;add it to the VRAM address lbz r10,colour(rtoc) ;write the colour to the address --------------------------------------------------------------------- GDeviceHandle: rs.w 1 colour: dc.b 0 ;black
Date: Sun, 30 Nov 1997 08:49:32 +0000 From: Benny Ronnhager <benny.ronnhager@soderhamn.mail.telia.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: SUPERVISOR MODE? Hi Ajay! >>>You wrote, can't you just use apples midi code? Thanks for the tip but, can you please be a bit more specific please. Best regards Benny
Date: Sun, 30 Nov 1997 12:54:43 +0100 From: robot@writeme.com (Alok) To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Alok, geometry prob Hi, Well I have a geometry prob: a plane a is given by two lines (d and e). I would like to calculate where P falls on a (where the perpendicular falls on the plane). This hasn't got anything to do with programming, but I think there must be someone on this chat (very) good in maths. BTW I should be learning this in 3 years time, but why I need to learn this is cos I would like to have more precise constructions. SO remember I really don't know much 3d geometry theory. Thx for helping... Bye, Alok
Date: Sun, 30 Nov 1997 23:15:17 -0500 From: Stuart Ball <lightsoft@compuserve.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Put pixel ? Hi Paul, The store instructions write from a processor register to memory - stb, sth, stw etc The load instructions load a register from memory - lbz - load a byte and zero the upper 3 bytes of the register. lhz - load a half and zero the upper two bytes. lha - load a half and sign extend into the upper two bytes of the register etc. Have a look at the source to init_graph_lib and also some of Eclipse's routines. init_graph_lib (found in P_Video_library) will return a pointer to a table - ytab - that contains the start address of every physical screen line. Using this it's easy to plot a given pixel with a stb instruction - the y coord indexes into ytab, and you add on the xcoord (times 8 for 256 colours) - this addition can be done with a stbx instruction,viz: slwi rx,rx,3 *x coord times 8 stbx r3,rx,ry *Where ry contains the contents of the ytab for y coord, rx is the x offset alogn the video line *and r3 contains the color code for the pixel. I would aim at plotting 4 pixels a go with a stwx for speed. Stu.
Date: Mon, 1 Dec 1997 09:40:12 -0500 From: Ajay Nath <AjayNath@compuserve.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: SUPERVISOR MODE? well i thought that there was some kind of midi support built into quicktime now...i don't know that much about it tho..certainly there is already a midi api for the mac...a quick search of my hard drive reveals files called midi.def & midi.h & midi.p
Date: Mon, 1 Dec 1997 12:22:13 -0500 (EST) From: Figaro Tea <humphret@ruby.winthrop.edu> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: PowerPC Architecture I'm taking a class on computer architecture and we've finally gotten to the section on pipelining and it got me thinking about the PPC. Here are some questions of mine: I know the FPU is pipelined, but are the other units? How does the PPC handle data and branch hazards? Is there hardware than can detect them and automatically stall, or is the programmer/compiler forbidden from even coding them, or a combination? The PPC is superscalar only, not superscalar and superpipelined right? Just a curiosity. Aside from the backside cache is there anything radically different in the PPC 750 that makes it so fast? ..._Tim_...
Date: Mon, 1 Dec 97 10:44:40 -0000 From: Kevin Avila <kevin@cache-computing.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: PowerPC Architecture >I know the FPU is pipelined, but are the other units? > >How does the PPC handle data and branch hazards? Is there hardware than >can detect them and automatically stall, or is the programmer/compiler >forbidden from even coding them, or a combination? > >Just a curiosity. Aside from the backside cache is there anything >radically different in the PPC 750 that makes it so fast? I really don't know if any other units are piplined, but i'm sure it says so in the manual, so you might want to look there. On the Mac, the VIA handles alot of the hazards, if one rises it will usually post an a call to IRQ 18, which really don't exist and then the the OS will pick up on that an usually give you a bus error. As for the 750, I don't know for sure yet because I have not read about the chip, but I think if you take away the backside cache, your simply left with a 604e, but there are other atvantages. The new memory controler chip in the g3 macs is really, really fast and handles interleaving even if you have mixed chips. So for example say you have the backside cache, a 32MB DIMM and a 16MB DIMM. The chip can grab data from the cache, the 32MB DIMM and the 16MB DIMM att at the same time givving you a super speed boost. And then there is always the faster data/address bus, faster chips, the SCSI chip has been upgraded to 75Mhz i think, so time your instructions right, and to async operations when ever possible, your app can very well be 100-200% faster on a g3 then on a 604.
Date: Mon, 1 Dec 1997 16:05:30 -0500 From: Ajay Nath <AjayNath@compuserve.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Free Apple Tools Apple is now making MPW C/C+ available for free on the web with other tools too! The quality of the code from these compilers was quite good! why are they doing this? perhaps because with the move to objective-c in apple they won't be supporting or selling these tools anymore so they might as well give them away. should LightSoft continue in their quest to make a C compiler when a very good one is now free?
Date: Mon, 1 Dec 1997 23:06:18 +0100 From: "MoonDark" <moondark@telemacus.it> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Monitors and Power Manager I scrolled through all the conventional documentation regarding Power Manager functions but found no reference to what I'm looking for: I actually need to find out how to turn on/off monitor devices via software, I've got an Audivision monitor and I know it supports this kind of energy saving features, programs like Sleeper are able to control devices this way, any info on this topic would be warmly appreciated Thanks in advance, Mario
Date: Tue, 2 Dec 1997 09:10:12 +1000 From: mrwhippy@pac.com.au (Paul) To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: stwx instruction Hello, After writing my put pixel routine,I changed from an stb instruction to an stwx to try and write four pixels at a time,as Stu suggested.Trouble is,I haven't gained any speed increase.It still draws to screen at the same speed :( I wrote 4 bytes to a register before using stwx (instead of 1 for the stb) but it's just too slow.I should see a noticeable difference in speed,surely?! Am I expecting too much,or do I need to draw it offscreen and flip it over just so it *looks* faster? :) Thanks, Paul
Date: Mon, 1 Dec 97 20:30:03 -0000 From: Kevin Avila <kevin@cache-computing.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Free Apple Tools >should LightSoft continue in their quest to make a C compiler when a very >good one is now free? heh.From my experinsewith MPW, I think it sucks, and the code it outputs is horable. There just doing it because MPW it old, outdated, and no one whats to support a product when everyone uses codewarrior, however , i'm betting my money on Fanta-C. I was hoping it would be ready for x-mas, but I guess not, Rob, hurry up =)
Date: Mon, 1 Dec 97 20:26:35 -0700 From: James Hague <jhague@dadgum.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: PowerPC Architecture >I know the FPU is pipelined, but are the other units? The integer unit is pipelined as well. The branch unit is a strange little beast, that works rather differently from the others :-) >How does the PPC handle data and branch hazards? Is there hardware than >can detect them and automatically stall, or is the programmer/compiler >forbidden from even coding them, or a combination? Yes, the PPC handles it all. You can code however you like and never have to worry about doing something that will cause the processor to go nuts--weird rumors about the 750 aside :-) The neat thing is that this code *doesn't* cause a stall on the 601/603: addi r3,r3,2 addi r3,r3,2 (On the 604 it doesn't stall either, but one of the integer units will be idle).
Date: Tue, 2 Dec 1997 00:29:10 -0500 (EST) From: Figaro Tea <humphret@ruby.winthrop.edu> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: PowerPC Architecture On Mon, 1 Dec 1997, Kevin Avila wrote: > On the Mac, the VIA handles alot of the hazards, if one rises it will > usually post an a call to IRQ 18, which really don't exist and then the > the OS will pick up on that an usually give you a bus error. What's the VIA? So basically, hazards are a no-no because the processor can't stall for them. But I hear about stalls a lot on here though, and Fantasm 5 has a stall detection thing, am I missing something? Are the stalls I'm thinking about in reference to branch hazards and not data hazards? If the integer unit isn't pipelined then I don't see a way for data hazards to arise, unless the floating point unit causes it. Maybe I'm just confusing myself; still, some clarification on PowerPC stalls and hazards would be nice, for my sake:) P.S. You can probably tell that I'm just learning about this. I know I'm a computer nerd now because I actually find it interesting! ..._Tim_...
Date: Tue, 2 Dec 1997 23:26:38 +0000 From: Rob Probin <rob@zedworld.demon.co.uk> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Free Apple Tools >>should LightSoft continue in their quest to make a C compiler when a very >>good one is now free? > > heh.From my experinsewith MPW, I think it sucks, and the code it outputs >is horable. There just doing it because MPW it old, outdated, and no one >whats to support a product when everyone uses codewarrior, however , i'm >betting my money on Fanta-C. I was hoping it would be ready for x-mas, >but I guess not, Rob, hurry up =) > >------------------------------------------ >Kevin Avila kevin@cache-computing.com >http://www.cache-computing.com > > Metroworks (and Symantec) obviously aren't worried. Apple wouldn't have released it for free if Metroworks were worried. I know the 'reason' given was to encourage Mac development, but it sounds a bit weak to me. Are these tools still under a full development effort? I think not. Therefore would a developer touch them? Hmmm. As for Lightsoft: they aren't worried about either Metroworks or Symantec. Kev: Lightsoft has had a very busy year. It is coming, we just don't want to rush it out. >why are they doing this? perhaps because with the move to objective-c in >apple they won't be supporting or selling these tools anymore so they might >as well give them away. I know Next was/is Objective-C based, but are apple really going to go with it? In terms of languages, the top ten must be C, Assembler, C++, Pascal, Cobol, Fortran, Basic, Java, Forth, Object-Pascal. approximately in that order (depending on the percentages of legacy code/against new written code/embedded/Microcomputer weighting ratios). Do you see objective-C? A Good way to gain programmers?? Regards Rob Probin at Lightsoft
Date: Wed, 3 Dec 1997 13:15:08 -0500 From: Ajay Nath <AjayNath@compuserve.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Free Apple Tools >> Do you see objective-C? A Good way to gain programmers?? << well they may force us to become obj-c programmers to work with rhapsody! or at least we may have to use their dev tools to get the benefit of all the (supposedly) great rhapsody tools
Date: Wed, 3 Dec 97 13:12:48 -0000 From: Kevin Avila <kevin@cache-computing.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Re: Free Apple Tools >well they may force us to become obj-c programmers to work with rhapsody! >or at least we may have to use their dev tools to get the benefit of all >the (supposedly) great rhapsody tools Well, thats not really true because I have written a couple small Rhapsody apps using just normal C, and as soon as I figure out the inlining formats of GCC, i'll code a few apps in assembly as well, the only thing that is hard as hell to develop for is the BeOS because it's all object orented and a pain in hte neck.
Date: Wed, 3 Dec 97 16:07:10 -0000 From: Kevin Avila <kevin@cache-computing.com> To: Multiple recipients of <list-fantasm@mail.tau.it> Subject: Debugger Disable? Hey, Would anyone happen to have a code snippet on how to temp. disable the Debugger? I take it you have to change the systems exception vector, but how?
BACK