MACHID, Continued

While writing  the MACHID program, that sidetracked me from mapper, I learned a bit.

The MACHID byte has some information on the model of the computer, but not all is very specific.

  • It will identify the amount of memory the computer has, not counting third party memory cards.
  • It will tell you if you have an 80 column card.
  • It will tell you if you have a clock that ProDos recognizes.

It can tentatively identify the Apple model, however Apples Technical notes show six bytes in rom that be used to specifically identify the Apple II.

As you can see below, the program was quick and dirty top down coding.

]LIST

5  PRINT “MACHID”,,”10-AUG-13″

6  PRINT

10 MACHID =  PEEK (49048)

16  PRINT : PRINT “DECIMAL VALUE OF MACHID:”;

20  PRINT MACHID

25  PRINT “BINARY VALUE OF MACHID:”;

30  FOR BIT = 7 TO 0 STEP  – 1

40 BV = 2 ^ BIT

50  IF MACHID < BV THEN B$(BIT) = “0”: GOTO 80

60 B$(BIT) = “1”

70 MACHID = MACHID – BV

80  NEXT BIT

90  FOR BIT = 7 TO 0 STEP  – 1

100  PRINT B$(BIT);

110  NEXT BIT

115  PRINT

120 B76$ = B$(7) + B$(6)

130 B54$ = B$(5) + B$(4)

140  IF B$(3) = “1” THEN 190

150  IF B76$ = “00” THEN  PRINT “II”;: GOTO 200

160  IF B76$ = “01” THEN  PRINT “II+”;: GOTO 200

170  IF B76$ = “10” THEN  PRINT “IIE”;: GOTO 200

180  PRINT “/// EMULATING APPLE II”;: GOTO 200

190  PRINT “//C”;

200  PRINT ” WITH “;

210  IF B54$ = “01” THEN  PRINT “48K”;

220  IF B54$ = “10” THEN  PRINT “64K”;

230  IF B54$ = “11” THEN  PRINT “128K”;

240  IF B$(1) = “1” THEN  PRINT ” AN 80 COLUMN CARD”;

250  IF B$(0) = “1” THEN  PRINT ” A CLOCK”;  260  PRINT “.”

]RUN

MACHID                          10-AUG-13

DECIMAL VALUE OF MACHID:179

BINARY VALUE OF MACHID:10110011

IIE WITH 128K AN 80 COLUMN CARD A CLOCK.

]PR#3

I’ve posted a disk image with the Applesoft version of MACHID on it.  I’m polishing up a ZBasic  version which I’ll add to the disk image later.  It uses the more specific ROM bytes to identify the computer.

— (boring PC stuff to follow)

Today I played with speech recognition on my laptop.  I wasn’t feeling well, so I thought I’d be lazy and dictate this page.  It ended up taking more work than  I expected.

I started out by having to set up my microphone, actually my headset with microphone.  I had to reinstall the software and it finally worked.

I had to go through the tutorial because I haven’t done it before on this machine.  By going through the tutorial that computer learns how you speak.

One problem I found, it doesn’t work well with word press lines.

73/74

 

 

Posted in Apple //c, Apple IIe, Posts, Programming Tagged with: , , , , , ,

Leave a Reply

Your email address will not be published. Required fields are marked *

*