3rd July 1996.

In this "issue":




What's Happening?

Hmm, well, as always we're busy, and held up at the same time. Well, when I say held up, I don't really mean it, just that we're waiting on some hardware that brains here forget to pick up! We placed a largish order, with our normal supplier, which included lots of little bits, like cache cards, dimms - that kind of thing. All in, there were probably twenty or so items - and I forgot to check the complete order - hence we are waiting for some stuff to come in the mail - most notably my long awaited cache card for this 7200 - how could I forget it :-(

I think we made a mistake on the keyboards - rather than buy Apple, we bought clone keyboards at a very good price - the only problem is, that there are two double quotes keys, and no colons! Ho hum...

Development

As usual, it's hectic. We've got hold of another machine (Yes, Apple of course) which should speed the compiler work up quite a lot.

Coming up for release shortly we have:
1. PF 406, which is 405 with a much better evaluator.
2. Eddie 130 - printing (who said "at last!":-)), switchable large font and generally better than 120.
3. New video library in 68k and PPC forms - yes that old stalwart is finally going to get updated/natified.

First of these to be released will be PowerFantasm V406, which naturally will be a free upgrade - we're about half way through testing. Eddie 1.30 may be ready for 4.06 but if not, it'll be posted as soon as it's ready, and the video library will be posted here when available.

General

We're looking at having a major reorganisation of these pages, into a more structured format - when this will happen, I don't know, but don't be suprised to see it all change in the near future. Away from the development side, I'm trying to get to grips with PageMill. It seems a fine program, but I get the impression the hype surrounding it is more to do with marketing than the actual capabilities of the program. I do realise that V2 is out sometime this month, but to be honest some of the shareware is far better - for example, I personally think that PageSpinner and Netscape do a better job. My current method is Eddie for raw input, then PageMill for fine formatting - maybe PageMill holds your hand too much - dunno?

Talking of pages, has anybody got a fast enough connection to Apple's "Mission Impossible" site? They weren't joking when they named it (I can't believe I just typed that...) - it's so slow - busy I guess, and on a vaguely related note...(Errm, not at all really)

It's true - a 7200 does double up it's video bus width when additional VRAM DIMMS are plugged in - gobsmacked is not the word! As a matter of fact, DIMMS are pretty amazing things - the way you can just mix and match them.

I see that Apple is designing a low end SIMM based motherboard for clone manufacturers. The acronym attached to said beasty eludes me now, but they've publicly stated that it will have a life of just over one year, then be superceded by the prep/chrp platform - is this a good idea? Would you buy an architecture that's dead almost as soon as you buy it? I wouldn't. I want 33MHz 32 bit PCI. I want 64bit DIMMS.

Actually, you have to admire Apple for going with DIMMS for PCI Macs - they were very expensive at the start, and now, they're the same price as SIMMS.Now this could be sheer coincidence - we know the memory market is about as stable as 7.5.3 without the update, so it does have peaks and troughs - but we haven't had DIMMS at this price - ever! My advice is to buy 'em now if you have the ready's, cause you'll need it next year.

What's the average life of your typical, work horse Mac? We work to three years, and most home users will still be using the same machines years after that. An average PC is pretty whacked out at one year, and not just in technological terms either. Ok, so you can get decent PC's, but they cost an arm and leg. By the time you've got SCSI, added ethernet and a decent graphics card, you wont get much change out of 2 grand, and it's still emulating 8 bit instructions deep in the core (Ok, maybe two of them at a time) - pahh!
Um, where is this drivel leading...oh yes, the point I think I'm making is that it is worthwhile upgrading your Mac. Ok, so you have a 6200 and can't run Open Transport - believe me, unless you have a 64kbit or better direct line, you won't notice any difference between MacTCP and TCP/IP. So you can't run QD3d - we'll neither can anybody else unless they have a 250MHZ 620 or a QD3D graphics accelerator. What you can do with virtually any Mac, specially any PPC based Mac, is write whatever you want, safe in the knowledge that it will have a long "shelf life" (I keep typing : for " - I will crack it!) and run on generations of future Macs. Can't say that about PC's :-)

Well, Lightsoft have finally replaced my ageing old Apple monitor - now I'm working on a nice (very actually) Sony 15" - the difference is amazing, bigger desktop too! I guess they are expensive for a 15" monitor, but the picture is great, and it's multisync, which helps a great deal with testing. I would have liked a 17", but the price difference is horrendous - it's an extra two hundred pounds - that's a lot of money for an extra two inches! (no, I won't slip in anything even remotely funny about an extra two inches, apart from the phrase "slip in", which I already seem to have managed...umm).

Ok, those long time readers of this drivel may well remember my lack of love for Open Transport - well the good news is that it finally seems to have settled down (but it still eats memory!). My only remaining gripe is why do I have to load a different configuration file in tcp/ip when I want to use Ethernet rather than PPP? Why can't we have a simple "configuration" toggle switch in tcp/ip, rather than having to load a new config in from the file menu. My main Mac is connected to three networks - an Ethernet link to the server, PPP to the Internet and the old AppleTalk network to Elsie. It is sometimes very confusing knowing what's going on. That's the problem with the Mac, sometimes I expect it to "know" I want to connect to a server in the States, and not the PC across the room - of course, the poor machine is not psychic, but maybe one day....

Interlude
And finally, a little bit of coding we've been doing you may find interesting. We've just added support in Eddie for extended keyboards, and while we were there, thought it a good idea to use the "scroll lock" LED (Light Emitting Diode) to show when Eddie is running a background task. We realised that we could flash this LED to show anything we wanted. Well, by writing two routines - one to light the LED and the other to extinguish it, we could see when a routine was running - handy. And of course, the relative brightness of the LED indicates how busy the routine is - you may find it useful (unless of course you don't have an extended keyboard...).

Below are the routines - LED_ON and LED_OFF. They call a few smaller routines - read_leds and set_leds, so as to ensure that the current contents of keyboard register #2 are not destroyed. The only weird thing about the following code is that parameter passing to system routines are in registers, and the completion routine ("my_comp") for the send_data routine passes our data buffer in a2! (we set a flag in the data buffer to indicate to the main routine that the data has been sent to the keyboard).The code looks more complicated than it really is - it took longer to format and extra comment it for this piece, than it did to write!

Note, that both routines check for an extended keyboard - this is just time wasting - you could get the kbd address on boot up and pass that to led_on and led_off.

See

Inside Macintosh Devices chp 5

and tech note

HW01 - ADB The Untold Story : Space Aliens Ate My Mouse

for more details.

 

****Led_on lights the scroll lock led.
led_on:
	save_all		*as this is an example, I'd better save all the regs..
	bsr	find_extended	*get first extended kbd, if there is one
				*d0=0=no extended
	tst.w	d0
	beq.s	cant_lo		*There is no extended keyboard, so don't do it.
**address of first extended kbd in d0 abd param_block set up
**set all leds
	move.w	d0,d7	*save address for read_leds/set_leds
	bsr.s	read_leds	*into d0
	lea	adb_data_buffer(pc),a0
	move.w	1(a0),d5
	bclr	#2,d5		*scroll lock led on - 0=on, 1=off
	bsr	set_leds
cant_lo:
	restore_All		*and now put em back the way they were...
	rts_	"led_on"

****led_off extinguishes the scroll lock LED.
led_off:
	save_all
	bsr	find_extended	*get first extended kbd, if there is one
				*d0=0=no extended
	tst.w	d0		*dont assume flags is set, check!
	beq.s	cant_lo
**address of first extended kbd in d0 abd param_block set up
**set all leds
	move.w	d0,d7		*save address
	bsr.s	read_leds	*into d0
	lea	adb_data_buffer(pc),a0
	move.w	1(a0),d6	*save current value in case we need it later...
	move.w	d6,d5		*current value for modification
	bset	#2,d5		*scroll lock led off
	bsr.s	set_leds
	restore_all
	rts_	"led_on"


****************************************************************
*******************Subroutines follow***************************
****************************************************************


**Needs adb address in d7,returns led register contents in adb_data_buffer (1...2)
**0 is byte count which will be 2 in this case
read_leds:
**make adb instruction in d0 as per IMDevices
	move.w	d7,d0
	lsl.b	#4,d0		*move address
	bset	#3,d0
	bset	#2,d0		*talk
	bset	#1,d0		*reg 2
	lea	adb_pb(pc),a0	*param block for adbop
	lea	adb_data_buffer(pc),a1	*the data buffer - in this case its a receive buffer.
	clr.b	(a1)		*So we know when we've read
	move.l	a1,(a0)		*pointer to data buffer
	clr.l	4(a0)		*no completion routine as we can monitor the rx buffer
	clr.l	8(a0)		*no completion data
	dc.w	_adbop
	tst.b	d0
	bmi.s	read_leds	*adb command queue full, so try again

**Wait for data to come from adb processor (it's a 2 MHz Motorola 68HC11)
	lea	adb_data_buffer(pc),a1
wait_for_it:
	tst.b	(a1)
	beq.s	wait_for_it	*Guess whats going on here then...
	rts_	"Read_leds"

****
**needs 16 bit reg data in d5,address in d7
set_leds:
**make op
	move.w	d7,d0
	lsl.b	#4,d0		*move address
	bset	#3,d0
	bclr	#2,d0		*listen
	bset	#1,d0		* to reg 2
	lea	adb_pb(pc),a0	*param block for adbop
	lea	adb_data_buffer(pc),a1
	move.w	d5,1(a1)	*the data for said reg
	move.b	#2,(a1)		*the size of the data - 16 bits
	move.l	a1,(a0)		*pointer to data buffer
	lea	my_comp(pc),a1
	move.l	a1,4(a0)	*no completion routine
	lea	my_comp_data(pc),a1
	clr.b	(a1)		*clear completion routine flag
	move.l	a1,8(a0)	*no optional data
	dc.w	_adbop
	tst.b	d0
	bmi.s	set_leds	*command queue full
	lea	my_comp_data(pc),a1	*completion routine sets this =1 
wait_for_it_send:
	tst.b	(a1)
	beq.s	wait_for_it_send	*wait for completion proc to run
	rts_	"Set_leds"	

****Find address of extended keyboard if there is one			
****Return d0=address of kbd or zero if no kbd.
find_extended:
	moveq	#1,d7		*device index 1-16
fe_loop:
	lea	adb_data_block(pc),a0
	move.w	d7,d0		*index
	dc.w	_getindadb	*returns in d1!
	lea	adb_data_block(pc),a0
	cmpi.w	#0x0202,(a0)	*is extended kbd? (handler ID and default address are both 2)
	beq.s	got_extended
	addq.w	#1,d7		*No, so next device
	cmpi.w	#17,d7
	bne.s	fe_loop		*done all possible devices?	
	clr.l	d0		*yes, clr d0=no extended
	rts_	"Find_extended"
got_extended:
	rts
**Completion routine for set_led
my_comp:
	move.b	#1,(a2)		*set my_comp_data so we can see it's finished
	rts_	"My_comp"
*************************************************************
********************Data follows*****************************
*************************************************************	
my_comp_data:	ds.w	1	*flag set by completion routine for send	
adb_data_block:
	ds.b	1		*devtype
	ds.b	1		*original adb address
	ds.l	1		*handler
	ds.l	1		*data area
adb_data_buffer:
	ds.b	12		*1st byte is count byte a la pascalish
	align
adb_pb:
	ds.l	3		*PB for adbOP

	global	led_on,led_off

 

Code on!
Stu.


Send mail to Stu



Back to Stu's Page Top Level
Back to Home Page