1F8D

90

AF

NORMX

BCC NORM

IF EXEN, NORMALIZE PRODUCT, ELSE COMPLEMENT

1F8F

38

 

FCOMPL SEC

SET CARRY FOR SUBTRACT

1F90

A2

03

 

LDX =$03

INDEX FOR 3 BYTE SUBTRACTION

1F92

A9

00

COMPL1

LDA =$00

CLEAR A

1F94

F5

08

 

SBC X1,X

SUBTRACT BYTE OF EXP1

1F96

95

08

 

STA X1,X

RESTORE IT

1F98

CA

 

 

DEX

NEXT MORE SIGNIFICANT BYTE

1F99

D0

F7

 

BNE COMPL1

LOOP UNTIL DONE

1F9B

F0

BC

*

BEQ ADDEND

NORMALIZE (OR SHIFT RIGHT IF OVERFLOW)

 

 

 

 

 

 

 

 

*

 

 

*EXP/MANT2 / EXP/MANT1 RESULT IN EXP/MANT1

1F9D

20

0D

1F

FDIV

JSR MD1

TAKE ABS VAL OF MANT1, MANT2

1FA0

E5

08

 

 

SBC X1

SUBTRACT EXP1 FROM EXP2

1FA2

20

CD 1F

 

JSR MD2

SAVE AS QUOTIENT EXP

1FA5

38

 

 

DIV1

SEC

SET CARRY FOR SUBTRACT

1FA6

A2

02

 

 

LDX =$02

INDEX FOR 3-BYTE INSTRUCTION

1FA8

B5

05

 

DIV2

LDA M2,X

 

1FAA

F5

0C

 

 

SBC E,X

SUBTRACT A BYTE OF E FROM MANT2

1FAC

48

 

 

 

PHA

SAVE ON STACK

1FAD

CA

 

 

 

DEX

NEXT MORE SIGNIF BYTE

1FAE

10

F8

 

 

BPL DIV2

LOOP UNTIL DONE

1FB0

A2

FD

 

 

LDX =$FD

INDEX FOR 3-BYTE CONDITIONAL MOVE

1FB2

68

 

 

DIV3

PLA

PULL A BYTE OF DIFFERENCE OFF STACK

1FB3

90

02

 

 

BCC DIV4

IF MANT2<E THEN DONT RESTORE MANT2

1FB5

95

08

 

 

STA M2+3,X

 

1FB7

E8

 

 

DIV4

INX

NEXT LESS SIGNIF BYTE

1FB8

D0

F8

 

 

BNE DIV3

LOOP UNTIL DONE

1FBA

26

0B

 

 

ROL M1+2

 

1FBC

26

0A

 

 

ROL M1+1

ROLL QUOTIENT LEFT, CARRY INTO LSB

1FBE

26

09

 

 

ROL M1

 

1FC0

06

07

 

 

ASL M2+2

 

1FC2

26

06

 

 

ROL M2+1

SHIFT DIVIDEND LEFT

1FC4

26

05

 

 

ROL M2

 

1FC6

B0

1C

 

 

BCS OVFL

OVERFLOW IS DUE TO UNNORMALIZED DIVISOR

1FC8

88

 

 

 

DEY

NEXT DIVIDE ITERATION

1FC9

D0

DA

 

 

BNE DIV1

LOOP UNTIL DONE 23 ITERATIONS

1FCB

F0

BE

 

 

BEQ MDEND

NORMALIZE QUOTIENT AND CORRECT SIGN

1FCD

86

0B

 

MD2

STX M1+2

 

1FCF

86

0A

 

 

STX M1+1

CLR MANT1 (3 BYTES) FOR MUL/DIV

1FD1

86

09

 

 

STX M1

 

1FD3

B0

0D

 

 

BCS OVCHK

IF EXP CALC SET CARRY, CHECK FOR OVFL

1FD5

30

04

 

 

BMI MD3

IF NEG NO UNDERFLOW

1FD7

68

 

 

 

PLA

POP ONE

1FD8

68

 

 

 

PLA

RETURN LEVEL

1FD9

90

B2

 

 

BCC NORMX

CLEAR X1 AND RETURN

1FDB

49

80

 

MD3

EOR =$80

COMPLIMENT SIGN BIT OF EXP

1FDD

85

08

 

 

STA X1

STORE IT

1FDF

A0

17

 

 

LDY =$17

COUNT FOR 24 MUL OR 23 DIV ITERATIONS

1FE1

60

 

 

 

RTS

RETURN

1FE2

10

F7

 

OVCHK

BPL MD3

IF POS EXP THEN NO OVERFLOW

1FE4

00

 

 

OVFL

BRK

 

 

 

 

 

*

 

 

 

 

 

 

*

 

 

*CONVERT EXP/MANT1 TO INTEGER IN M1 (HIGH) AND M1+1(LOW)

*EXP/MANT2 UNEFFECTED

 

 

 

*

 

 

1FE5

20

5F

1F

JSR RTAR

SHIFT MANT1 RT AND INCREMENT EXPNT

1FE8

A5

08

FIX

LDA X1

CHECK EXPONENT

1FEA

C9

8E

 

CMP =$8E

IS EXPONENT 14?

1FEC

D0

F7

 

BNE FIX-3

NO, SHIFT

 

 

 

 

 

 

Page 89
Image 89
Apple II manual Normx BCC Norm If EXEN, Normalize PRODUCT, Else Complement

II specifications

The Apple II, launched in April 1977, was one of the first highly successful mass-produced microcomputer products. It marked a significant leap in personal computing, setting standards for future developments in the industry. Created by Steve Wozniak and Steve Jobs, the Apple II differentiated itself with its user-friendly design, appealing aesthetics, and robust capabilities.

One of the standout features of the Apple II was its open architecture, which allowed users to expand and enhance the computer's functionality. This design enabled hundreds of third-party hardware and software developers to contribute to its ecosystem, resulting in an array of peripherals, including printers, modems, and storage devices. The Apple II utilized a MOS Technology 6502 microprocessor running at a clock speed of 1 MHz. Initially equipped with 4 KB of RAM, the machine could be expanded to 48 KB, accommodating more complex applications and programs.

The Apple II was also notable for its colorful graphics. It was one of the first computers to support color display, offering a 6-color palette with a resolution of 280x192 pixels in 16 colors when using its Color Graphics Card. This feature significantly enhanced the visual appeal of games and educational software developed for the platform, making computing more accessible and entertaining for various audiences.

Apple's commitment to user experience was evident in the design of the machine. It featured an integrated keyboard and a plastic case, which was both durable and visually appealing. The self-contained design included drive bays for floppy disk drives, allowing for quicker data access than traditional tape drives. It also supported audio output, enabling sound effects and music, a novelty at the time.

The introduction of the Apple DOS operating system further underscored the machine's capabilities. DOS streamlined file management and made it easier for users to navigate and manage their data. The combination of hardware and software positioned the Apple II as an educational tool and a gaming platform, fostering a vibrant software ecosystem.

The Apple II family continued to evolve, with variations like the Apple II+, IIe, and IIgs being introduced over the years. These iterations brought enhancements in memory, processing power, and graphics capabilities. The legacy of the Apple II endures, not only as a foundational product in personal computing but also as a symbol of innovation that paved the way for future advancements in technology. Its impact is still felt today, as it inspired countless developers and shaped the trajectory of the computer industry.