the transactor v5 05 1985

88
8/7/2019 The Transactor V5 05 1985 http://slidepdf.com/reader/full/the-transactor-v5-05-1985 1/88

Upload: cubemanpdx

Post on 08-Apr-2018

230 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 1/88

Page 2: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 2/88

A ^ P A L 6 T h f a s t e s t a n e a s i e s t t o u s e/ / / ^ ^ a s s e m b l e r f o r t h e C o m m o d o r e 6 4

P a 6 e n a b l e s t h e u s e r t p e r f o r ma s s e m b l y l a n g u a g e p r o g r a m m i n g u s i n g t h s t a n d a r d M O m n e m o n i c s . 5 6 9 . 9 5

6 I a a b s o l u t e l y i n d i s p e n s i b l e a i t t h p r o g r a m m e r u s i n g C o m m o d o r e

6 4 B A S I C . P o w e r 6 t u r b o - c h a r g e sr e s i d e n t B A S I C w i t h d o z e n s o n e s u p e ru s e f u l c o m m a n d s l i k e M E R G E , U N D O ,T E S T a n D I S K a w e l l a a l t h o l s t a n d b y s s u c h a R E N U M a n S E A R C HR E P L A C E . I n c l u d e s M o r e P o w e r 6 4 S 6 9 . 9 5

r T O O L B O 6 I t h u l t i m a t e p r o g r a m m e r ' s u t i l i t yp a c k a g e . I n c l u d e s P a 6 a s s e m b l e r

a n P o w e r 6 B A S I C s o u p - u p k i a l t o g e t h e r i o n f u l l y i n t e g r a t e d a n e c o n o m i c a l p a c k a g e . $ 1 2 9 . 9 5

A - ^ S P E L L P R O 6 K I a e a s y t o u s e s p e l l i n g c h e c k e rw i t h s t a n d a r d d i c t i o n a r y e x p a n d a b l e

t 2 5 , 0 0 0 w o r d s . S p e l l P r o 6 q u i c k l ya d a p t s i t s e l f t y o u r p e r s o n a l v o c a b u l a r ya n b u s i n e s s j a r g o n a l l o w i n g y o t a d d a n dd e l e t e w o r d s t o / f r o m t h d i c t i o n a r y , e d i td o c u m e n t s t c o r r e c t u n r e c o g n i z e d w o r d sa n d o u t p u t l i s t s o u n r e c o g n i z e d w o r d s t p r i n t e r o s c r e e n . S p e l l P r o 6 w a d e s i g n e dt w o r k w i t h t h W o r d P r o S e r i e s ' a n do t h e r w o r d p r o c e s s i n g p r o g r a m s u s i n g t h W o r d P r o f i l e f o r m a t . $ 6 9 . 9 5

N O S H I P P I N G ! ! !F o Y o u r N e a r e s t D e a l e r

C a l l( 4 1 6 ) 2 7 3 - 6 3 5 0

t C o m m o d o r e 6 a n C o m m o d o r e a r t r a d e m a r k s o C o m m o d o r e B u s i n e s s M a c h i n e s I n c .P r e s e n t l y m a r k e t e d b P r o f e s s i o n a l S o f t w a r e I n c .

S p e c i f i c a t i o n s s u b j e c t t c h a n g e w i t h o u t n o t i c e . . .

A W P 6 4T h i s b r a n d n e o f f e r i n g f r o m t h

/ / / " N o r i g i n a t o r s o t h W o r d P r o S e r i e s *b r i n g s p r o f e s s i o n a l w o r d p r o c e s s i n g t o t h eC o m m o d o r e 6 f o t h f i r s t t i m e . T w y e a r s u n d e r d e v e l o p m e n t , W P 6 4 f e a t u r e s1 0 0 % p r o p o r t i o n a l p r i n t i n g c a p a b i l i t y a

w e l l a 4 0 / 8 0 c o l u m n d i s p l a y , a u t o m a t i cw o r d w r a p , t w c o l u m n p r i n t i n g , a l t e r n a t ep a g i n g f o h e a d e r s f o o t e r s , f o u r w a s c r o l l i n g , e x t r a t e x t a r e a a n b r a n d n e ' O O P S ' b u f f e r t h a t m a g i c a l l y b r i n g s b a c kt e x t d e l e t e d i e r r o r . A l y o e v e r d r e a m e do i w o r d p r o c e s s o r p r o g r a m , W P 6 4s e t s n e h i g h s t a n d a r d f o t h s o f t w a r ei n d u s t r y t m e e t . $ 6 9 . 9 5

A ^ M A I L P R O 6 K n e g e n e r a t i o n o d a t ao r g a n i z e r a n l i s t m a n a g e r , M a i l P r o

6 i t h e a s i e s t o a l t l e a r n a n u s e .H a n d l e s u t 4 , 0 0 0 r e c o r d s o n o n d i s k ,p r i n t s m u l t i p l e l a b e l s a c r o s s , d o e s m i n o rt e x t e d i t i n g i e s e t t i n g u i n v o i c e s . B e s t o a l l , M a i l P r o 6 r e s i d e s e n t i r e l y w i t h i nm e m o r y s y o d o n ' t h a v e t c o n s t a n t l yj u g g l e d i s k s l i k e y o u m u s t w i t h o t h e r d a t ab a s e m a n a g e r s f o t h C o m m o d o r e 6 4

$ 6 9 . 9 5

P R O - L I N E■ ■ ■ ■ I I I I S O F T W A R E2 7 3 - 6 3 5 0

' 5 T H Q U E E N S W A Y E A S T , U N I T 8 M I S S I S S A U G A , O N T A R I O . C A N A D A , L 4 4 C

Page 3: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 3/88

V o l u m eI s s u e 0

C i r c u l a t i o n 6 2 , 0 0 0

T r a n s c r i p t i o n s E d i t o r i a lN e w s B R . . T h D i s k e t t e T r a n s a c t o rT h C o m p l e t e C o m m o d o r e

I n n e r S p a c e A n t h o l o g yM e m o r e x C a t a l o gH e l k o S y s t e m s F u r n i t u r eN e t w o r k C o m m u n i c a t i o n s S h o wE D E l e c t r o n i c s A n n o u n c e s A v a i l a b i l i t yo C o m p u S e r v e S o f t w a r e i C a n a d a .F r a n t e k S o f t w a r e d i s t r i b u t o r s

f o S c a r b o r o u g h S y s t e m s .C o m m o d o r e 6 E n h a n c e m e n t sC o m m o d o r e t D i s t r i b u t e N e H a n d i c

S o f t w a r e N e t w o r k i n g D e v i c e sN e R e c r e a t i o n a l S o f t w a r e f o t h + a n C 1 C O M A L : P r o g r a m F o T h F u t u r e - T o d a y !T P U G O f f e r s C O M A L P r i m e r a n d M a n u a lE n T e c h I n t r o d u c e s E n h a n c e d S t u d i o 6 4M e l c h e r S o f t w a r e A n n o u n c e s T w M u s i c

T u t o r P r o g r a m sT w P r e s i d e n t i a l E l e c t i o n P r o g r a m sR E C O R D B O O K : D a t a S t o r a g e a n R e t r i e v a lH o T M a k e G o o d I n v e s t m e n t sI n v e s t m e n t a n S t a t i s t i c a l S o f t w a r e P a c k a g eM I C R O S H A R E 6 n e t w o r k i n g s y s t e mO p e r a n t I n t e r f a c eE l e c t r o n i c C o m p o n e n t s C o m p u t e r P a t c h C o r dO m n i t r o n i x A n n o u n c e s R S 2 3 2 I n t e r f a c e

f o t h V I C - 2 0 , C 6 4 , a n d S X 6 4 P o r t a b l e .R S - 2 3 2 1 C h a n n e l A n a l o g I n p u t M o d u l e

B i t s a n P i e c e s 1 B u i l t - i n d e b u g g i n g a i E a s y D i s k D i r e c t o r y P a t t e r n m a t c h i n gP o i s o n L i n e N u m b e rC l o s i n g " F o r g o t t e n " F i l e sS A V E - i n g R a n g e o M e m o r y F r o m B A S I CW A I T S E C O N D !C h e c k i n g f o S H I F T , C T R L , a n d C o m m o d o r e k e y sC h a n g i n g S c r e e n C h a r a c t e r C o l o u r sD e a t h b G a r b a g eD r o w n i n g i G a r b a g e !S i n g l e D i s k C o p y P r o g r a mB A S I C 4 . 0 S t r i n g B u I n t e r c e p t i n g C 6 4 S y s t e m E r r o r M e s s a g e sC 6 R E S T O R E k e c h e c k i n g

Q u e s t i o n a b l e P r o m p tF a s t B A S I C H I - R E S P o i n t P l o tF a s t H I - R E S S c r e e n C l e a rD e c i m a l t H e c o n v e r s i o n T a b l eL a r g e C h a r a c t e r s o V I o 6

L e t t e r s 1 D o c t o r D e s t r u c t o : R e s e t P r o t e c t o rC o i n S i d e O n C o i n S i d e T w o :

T r a n s b l o o p e r s 1

T h C o m m o d o r e D O S : T w B o o k R e v i e w s 2 M a c h i n e L a n g u a g e F o T h C o m m o d o r e 6 2 C o m m o d o r e 1 + M e m o r y M a p s 2 T h M A N A G E R C o l u m n 2 S u b r o u t i n e E l i m i n a t o r s 2 I n t r o d u c i n g T r a n s B A S I C 3 H a r d w a r e C o r n e r 3 C o m m o d o r e 6 K e y b o a r d K e r n e l R o u t i n e s 3 F i x i n g C o m m o d o r e K e y b o a r d s 4 L i f e W i t h T h 1 5 4 1 4 L e a r n i n g T h L a n g u a g e o D O 4 I n s i d e T h C o m m o d o r e 6 5 A l A b o u t P r i n t e r s 5 E v o l u t i o n O T h C P 6 E P R O M C a r t r i d g e F o T h V I 2 6 C o m p u t e r S l i d e P r o j e c t o r C o n t r o l 6 V I 2 A u d i o / V i d e o C a b l e A d a p t e r 7 L I N K E D L I S T S P a r t 7 C o m p u t i n g D e s k 7 R e t h i n k i n g D A T A f i c a t i o n 7

T h T r a n s a c t o r V o l u m e 5 I s s u e 0

Page 4: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 4/88

T h T o i h / N u w s J

p r i n t "

M a n a g i n g E d i t o rK a r l J . H . H i l d o nE d i t o rR i c h a r d E v e r sT e c h n i c a l E d i t o rC h r i s Z a m a r aA r t D i r e c t o rJ o h n M o s t a c c iA d m i n i s t r a t i o n S u b s c r i p t i o n sL a n a H u m p h r i e sC o n t r i b u t i n g W r i t e r sH a r o l d A n d e r s o nD o B e l lD a n i e l B i n g a m o nJ i B u t t e r f i e l dG a r y C o b bE l i z a b e t h D e a lD o m e n i c D e F r a n c e s c oG D e n i sB r i a n D o b b sB o D r a k eT e E v e r sM i k e F o r a n iJ e f f G o e b e lD a v e G z i kT h o m a s H e n r yD a v i d A H o o kP h i l H o n s i n g e rR i c k H i e sS c o t t J o h n s o nG a r r y K i z i a kS c o t t M a c l e a nG l e n P e a r c eM i c h a e l Q u i g l e yH o w a r d R o t e n b e r gL o u i s F S a n d e rG e o r g e S h i r i n i a nK M u r r a y S m i t hD a r r e n J S p r u y tA u b r e y S t a n l e yN i c k S u l l i v a nC o l i n T h o m p s o nM i k e T o d dJ a m e s W h i t e w o o dP r o d u c t i o nA t t i c T y p e s e t t i n g L t d .P r i n t i n gP r i n t e d i C a n a d a b M a c L e a n H u n t e r P r i n t i n g

T h T r a n s a c t o r i p u b l i s h e d b i - m o n t h l y b T r a n s a c t o r P u b l i s h i n g I n c . , 5 0 S t e e l e s A v e n u e , M i l t o n ,O n t a r i o , L 9 3 P 7 . C a n a d i a n S e c o n d C l a s s m a i l r e g i s t r a t i o n n u m b e r 6 3 4 2 . U S P S 7 2 5 - 0 5 0 , S e c o n dC l a s s p o s t a g e p a i d a B u f f a l o N Y f o U . S . s u b s c r i b e r s . U . S . P o s t m a s t e r s : s e n d a d d r e s s c h a n g e s t T h T r a n s a c t o r , 2 7 L i n w o o d A v e n u e , B u f f a l o , N Y 1 4 2 0 9 , 7 1 6 - 8 8 4 - 0 6 3 0 . I S S N * 0 8 2 7 - 2 5 3 0 .T h T r a n s a c t o r i i n w a c o n n e c t e d w i t h C o m m o d o r e B u s i n e s s M a c h i n e s L t d . o C o m m o d o r eI n c o r p o r a t e d . C o m m o d o r e a n C o m m o d o r e p r o d u c t n a m e s ( P E T . C B M , V I C , 6 4 ) a r e r e g i s t e r e dt r a d e m a r k s o C o m m o d o r e I n c .

S u b s c r i p t i o n s :C a n a d a $ 1 5 C d n . U . S . A . $ 1 U S A l o t h e r $ 2 1 U S .

A i M a i l ( O v e r s e a s o n l y ) $ 4 U S ( $ 4 . 1 5 p o s t a g e / i s s u e )

S e n d a l s u b s c r i p t i o n s t o T h T r a n s a c t o r , S u b s c r i p t i o n s D e p a r t m e n t , 5 0 S t e e l e s A v e n u e ,M i l t o n , O n l a r i o . C a n a d a . L 9 T 3 P 7 , 4 1 6 8 7 6 4 7 4 1 . F r o m T o r o n t o c a l l 8 2 1 6 6 2 . N o t e : S u b s c r i p t i o n sa r h a n d l e d a t h i s a d d r e s s O N L Y . S u b s c r i p t i o n s s e n t t o u B u f f a l o a d d r e s s ( a b o v e ) w i l l b f o r w a r d e d t M i l t o n H Q

B a c k I s s u e s : $ 4 . 5 0 e a c h . O r d e r a l b a c k i s s u e s f r o m M i l t o n H Q S O L D O U T : T h B e s t o T h T r a n s a c t o r V o l u m e s 2 a n V o l u m e 4 I s s u e s 0 0 S t i l l A v a i l a b l e : B e s t o T h T r a n s a c t o r V o l . 3 V o l . 4 0 1 , 0 2 , 0 3 , 0 6 , V o l . 5 0 1 , 0 2 . 0 3 , 0

P r o g r a m L i s t i n g s I T h T r a n s a c t o rA l p r o g r a m s l i s t e d i n T h T r a n s a c t o r w i l l a p p e a r a t h e y w o u l d o y o u r s c r e e n i U p p e r / L o w e r c a s em o d e . T o c l a r i f y t w p o t e n t i a l c h a r a c t e r m i x - u p s , z e r o e s w i l l a p p e a r a ' 0 a n t h l e t t e r " o w i l l o f c o u r s eb i l o w e r c a s e . S e c o n d l y , t h l o w e r c a s e ( T h a f l a t t o a o p p o s e d t t h n u m b e r w h i c h h a s a na n g l e d t o p .M a n y p r o g r a m s w i l l c o n t a i n r e v e r s e v i d e o c h a r a c t e r s t h a t r e p r e s e n t c u r s o r m o v e m e n t s , c o l o u r s , o f u n c t i o n k e y s . T h e s e w i l l a l s o b s h o w n e x a c t l y a s t h e y w o u l d a p p e a r o y o u r s c r e e n , b u t t h e y ' r e l i s t e dh e r e f o r e f e r e n c e . A l s o r e m e m b e r : C T R L - q w i t h i n q u o t e s i i d e n t i c a l t o C u r s o r D o w n , e a l O c c a s i o n a l l y p r o g r a m s w i l l c o n t a i n l i n e s t h a t s h o w c o n s e c u t i v e s p a c e s . O f t e n t h n u m b e r o s p a c e s y o i n s e r t w i l l n o b c r i t i c a l t c o r r e c t o p e r a t i o n o t h p r o g r a m . W h e n i i s t h r e q u i r e d n u m b e r o s p a c e sw i l l b s h o w n . F o r e x a m p l e :

f l u s h r i g h t " w o u l d b s h o w n a p r i n t " [ s p a c e 1 0 ] f l u s h r i g h t "

C u r s o r C h a r a c t e r s F o P E C B V I 6 D o w n

L e f tR V R V O f f -

[ L f t ]

I n s e r t - g D e l e t e -C l e a r S c r nH o m eS T O P

C o l o u r C h a r a c t e r s F o V I 6 B l a c kW h i t e -R e C y a n - [ C y n ]P u r p l e [ P u r ]G r e e nB l u eY e l l o w - [ Y e l ]

O r a n g eB r o w nL t R e G r e yG r e yL t G r e e nL t B l u eG r e y [ G r 3 ]

F u n c t i o n K e y s F o V I 6 F l F 2 F 3 F 4

F 5 F 6 F 7 F 8

C o m p u L i tP B o 3 5 P o r t C o q u i t l a m , B V 5 4 K 6 0 4 3 8 8 5 4U . S . A . D i s t r i b u t o r :

Q u a n t i t y O r d e r s :

M i c r o n D i s t r i b u t i n g4 0 Q u e e n S t r e e t W e s tT o r o n t o , O n t a r i o , M 5 2 A ( 4 1 6 ) 5 9 3 9 8 6 2D e a l e r I n q u i r i e s O N L Y :

8 0 0 2 6 8 9 0 5 2S u b s c r i p t i o n r e l a t e d i n q u i r i e sa r h a n d l e d O N L Y a M i l t o n H

d u l r i b u t u i gC a p i t a l D i s t r i b u t i n gC h a r l t o n B u i l d i n gD e r b y , C 0 6 4 1 8( 2 0 3 ) 7 3 5 3 3 8 1( o y o u r l o c a l w h o l e s a l e r )

M a s t e r M e d i a2 6 W y e c r o l t R o a dO a k v i l l e , O n t a r i oL 6 5 B ( 4 1 6 ) 8 4 2 1 5 5 5( o y o u r l o c a l w h o l e s a l e r )

E d i t o r i a l c o n t r i b u t i o n s a r e a l w a y s w e l c o m e . W r i t e r s a r e n c o u r a g e d t p r e p a r e m a t e r i a l a c c o r d i n g t t h e m e s a s h o w n i E d i t o r i a l S c h e d u l e ( s e e l i s t n e a r t h e n o f t h i s i s s u e ) . R e m u n e r a t i o n i $ 4 p e p r i n t e d p a g e . P r e f e r r e d m e d i a i 1 5 4 1 , 2 0 3 1 , 4 0 4 0 , 8 0 5 0 , o 8 2 5 0 d i s k e t t e s w i t h W o r d P r o .W o r d C r a f t , S u p e r s c r i p t , o r S E t e x t f i l e s . P r o g r a m l i s t i n g s o v e r 2 l i n e s s h o u l d b e p r o v i d e d o d i s ko t a p e . M a n u s c r i p t s s h o u l d b e t y p e w r i t t e n , d o u b l e s p a c e d , w i t h s p e c i a l c h a r a c t e r s o f o r m a t s c l e a r l ym a r k e d . P h o t o s o a u t h o r s o e q u i p m e n t , a n i l l u s t r a t i o n s w i l l b i n c l u d e d w i t h a r t i c l e s d e p e n d i n go q u a l i t y . D i s k e t t e s , t a p e s a n d / o r p h o t o s w i l l b r e t u r n e d o r e q u e s t .

A l m a t e r i a l a c c e p t e d b e c o m e s t h e p r o p e r t y o T h T r a n s a c t o r . A l m a t e r i a l i c o p y r i g h t b T r a n s a c t o r P u b l i c a t i o n s I n c . R e p r o d u c t i o n i a n f o r m w i t h o u t p e r m i s s i o n i i v i o l a t i o n o a p p l i c a b l e l a w s . P l e a s e r e - c o n f i r m a n y p e r m i s s i o n s g r a n t e d p r i o r t t h i s n o t i c e . S o l i c i t e d m a t e r i a l i a c c e p t e d o a a l r i g h t s b a s i s o n l y . W r i t e t t h e M i l t o n a d d r e s s f o w r i t e r s p a c k a g e .T h o p i n i o n s e x p r e s s e d i c o n t r i b u t e d a r t i c l e s a r e n o t n e c e s s a r i l y t h o s e o T h T r a n s a c t o r . A l t h o u g ha c c u r a c y i m a j o r o b j e c t i v e , T h T r a n s a c t o r c a n n o t a s s u m e l i a b i l i t y f o e r r o r s i a r t i c l e s o p r o g r a m s . P r o g r a m s l i s t e d i n T h T r a n s a c t o r a r e p u b l i c d o m a i n ; f r e e t o c o p y , n o t s e l l .

T h T r a n s a c t o r V o l u m e 5 I s s u e 0

Page 5: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 5/88

W e ' r e S o M i s u n d e r s t o o d !c o u p l e o i s s u e s b a c k w p u b l i s h e d " m o c k a d t y p e c a r t o o n

d e s c r i b i n g t h " C o m e d i a n 2 6 4 " . S i n c e t h e n w e ' v e h e a r d r e p o r t sr a n g i n g f r o m t i c k l e d t m i l d s h o c k . W e l l , w a T h T r a n s a c t o rw o u l d l i k e t o s e t t h r e c o r d s t r a i g h t . B e f o r e a n y o n e e l s e i e v e n t h l e a s t b i i n f l u e n c e d b w h a t w a m e r e l y i n t e n d e d t b l i t t l e ' D o nR i c k l e s ' s t y l e h u m o r , h e r e ' s h o w w e s e e t h e p i c t u r e t o t h i s p o i n t i t h l i f e o t h n e w C o m m o d o r e + 4

T s t a r t , i t ' s o n l y n a t u r a l t h a t C o m m o d o r e w i l l d u t h n e w e s tm a c h i n e t h e i r " l a t e s t a n g r e a t e s t " . T h e y h a v e t d t h a t . I t ' sc a l l e d , " s t a y i n g i b u s i n e s s " . B u n o i s e e m s t h a t m a n y C o m m od o r e 6 4 o w n e r s a r s h o w i n g w h a t y o u m i g h t c a l l " t e c h n o l o g yt e r r i t o r i a l " b e h a v i o u r p a t t e r n s . T h 6 h a f e a t u r e s n o f o u n d i t h + 4 . S o t m a i n t a i n a t e c h n o l o g i c a l l y s u p e r i o r f e e l i n g t o w a r d st h e i r i n v e s t m e n t , s o m e 6 o w n e r s w i l l n a t u r a l l y s e e a n e m c h i n e s w e a k n e s s e s o v e r i t s t r e n g t h s . B e s i d e s , t h " n e w k i o t h b l o c k " i b o u n d t t a k e a l i t t l e r i b b i n g , b u t h a t s t a g e i p r e t t y w e l lo v e r .

T h 6 a n t h + h a v e m a n y s i m i l a r i t i e s . B u t h a d v a n c e df e a t u r e s u n i q u e t e a c h m a c h i n e w i l l h a v e t h m o s t i n f l u e n c e o v e ra d e c i s i o n b e t w e e n t h e t w o . T h a t i s i m o n e y i n o b j e c t . T h + w i l l c o s t m o r e t h a n t h 6 w h i c h i m o r e t h a n t h e C 1 6 , t h e 1 6 v e r s i o n o t h + i C 6 c a s i n g .

T h 6 w i l l r e m a i n t h e s u p e r i o r e n t e r t a i n m e n t m a c h i n e . T h a n i m a t e d g r a p h i c s c a p a b i l i t i e s w i l l e n s u r e t h a t . T h + h a S O U N D c o m m a n d , b u m u s i c a p p l i c a t i o n s o a n s o p h i s t i c a t e dn a t u r e w i l l s t i l l b s u p e r i o r w i t h t h S I c h i p . A n d C o m m o d o r e i n o a b o u t t g i v e t h e i r s t a r p l a y e r i t w a l k i n g p a p e r s .

T h + w i n s i t h " p r o d u c t i v i t y " d e p a r t m e n t , t h m a i n p r o m ot i o n a l b a s e f o t h m a c h i n e . H o w e v e r , i t h a t w a y o u r m a i n r e a s o nf o o w n i n g 6 4 r e m e m b e r , g o o d i n v e s t m e n t i o n t h a t d o e s t h j o i w a i n t e n d e d t o T h e r e w i l l a l w a y s b a n o t h e r n e c o m p u t e r ,b u y o c a n ' t w a i t f o r e v e r . I y o k n o w y o n e e d o n e , i t ' sq u e s t i o n o h o l o n g y o c a g w i t h o u t . Y o m u s t d e t e r m i n e h o v a l u a b l e c o m p u t e r w i l l b f o t h e t a s k a h a n d , t h e n s u b t r a c t t h a tv a l u e o v e r t h p e r i o d o t i m e y o u s p e n d w a i t i n g . M a n y C o m m od o r e 6 4 o w n e r s u s i n g " p r o d u c t i v i t y " s o f t w a r e w i l l p r o b a b l y a g r e et h a t w a i t i n g w o u l d h a v e b e e n a m i s t a k e . I f a c t , i t ' s g o o dp o s s i b i l i t y t h a t t h o s e m a c h i n e s h a v e n o t o n l y p a i d f o t h e m s e l v e s ,b u a l s o b r a n d n e + s y s t e m .

T h 1 h a b e e n d u b b e d " T h e L e a r n i n g M a c h i n e " a n d w i l l n d o u b t b e a s e r i o u s c o n t e n d e r i t h b a t t l e f o t h e e d u c a t i o n a lm a r k e t . S c h o o l b u d g e t s s h o u l d h a v e l i t t l e t r o u b l e w i t h 9 9 b u c k sU . S .

V I 2 p r i c e s a r p r e t t y w e l l r o c k - b o t t o m w i t h r e p o r t s a s l o a $ 4 i F l o r i d a . A p p a r e n t l y C o m m o d o r e s t i l l h a i n v e n t o r y , b u t t h eV I 2 s t a m p h a p r o b a b l y s e e n t h p r o d u c t i o n l i n e f o t h l a s tt i m e .

T h a t ' s o u a c c o u n t o t h s i t u a t i o n . N o t h m a c h i n e i t s e l f .

Q u i t e s i m p l y , t h C o m m o d o r e 1 a n g e n e r a t i o n o c o m p u t e r sa r n o t h i n g l e s s t h a n f a b u l o u s ! I f a c t , f r o m t h a s p e c t o p r o g r a m - K a r l 3 . H . H i l d o n , M a n a g i n g E d i t o r

m a b i l i t y , i t ' s t h b e s t C o m m o d o r e m a c h i n e y e t . A n d , a u s u a l ,d o l l a r f o d o l l a r t h e o t h e r m a n u f a c t u r e r s d o n ' t e v e n c o m e c l o s e .

S u r e i d o e s n ' t h a v e S I c h i p , b u t h S O U N D c o m m a n d p r o v i d e se n o u g h a u d i o f o t h a v e r a g e p r o g r a m . I d o e s n ' t h a v e s p r i t e s , b u y o d o n ' t u s s p r i t e s t d i s p l a y b u s i n e s s r e p o r t s a n a n a l y t i c a ld a t a .

N e f e a t u r e s l i k e l u m i n a n c e c o n t r o l a n f l a s h i n g a t t r i b u t e s a r i n c l u d e d ; t h e M L n o h a A s s e m b l e , D i s a s s e m b l e , t h e i n v a l ua b l e H u n t c o m m a n d , a n m o r e ; D e c i m a l a n H e c o n v e r t e rp r o g r a m s a r n l o n g e r n e c e s s a r y ; t h e E d i t o r i t h e b e s t a n y w h e r ew i t h f e a t u r e s l i k e R e n u m b e r , D e l e t e , H e l p , T r a c e , F i n d , a n C h a n g e ; t h n e B A S I C h a a l t h e s t r u c t u r e d c o m m a n d s y o u ' l ln e e d ; a n w i t h 6 0 o R A a v a i l a b l e f o B A S I C m e a n s t h e r e w i l lb n e x c u s e f o s o f t w a r e t h a t i a n y t h i n g l e s s t h a n e x q u i s i t e !

E v e n t h n e m i c r o p r o c e s s o r t e c h n o l o g y o t h 7 5 0 1 m a k e s i t h l e a d e r i s o p h i s t i c a t e d a r c h i t e c t u r e a d v a n c e m e n t s . M u l t i p l e m e o r " l a y e r s " ( s e e t h M e m o r y M a p i n t h i s i s s u e ) a l l o w f o r p i l e s o fR O t h a t e f f e c t i v e l y r e q u i r e s n a d d r e s s s p a c e c o n c e p t t h a t ' sn o o n l y c l e v e r , b u t r u l y i n t e l l i g e n t !

T h + m i g h t b e t h l a t e s t , b u t h a t d o e s n ' t m a k e t h 6 o b s o l e t e .F o t h e a p p l i c a t i o n m i n d e d , e i t h e r m a c h i n e w i l l b t h r i g h t c h o i c ed e p e n d i n g o t h n e e d s o t h e b u y e r , w h i c h i h o c o m p u t e rp u r c h a s e s h o u l d b m a d e . F o t h e h o b b y i s t , p e r s o n a l p r e f e r e n c ew i l l p r o b a b l y b t h d e c i d i n g f a c t o r . T h i n t r o d u c t i o n o t h + f i l l s a g a p ; w e ' l l h a v e t h c h o i c e o a e n t e r t a i n m e n t m a c h i n e w i t hb u s i n e s s p o t e n t i a l , o a a p p l i c a t i o n s m a c h i n e w i t h e n t e r t a i n m e n tp o t e n t i a l . I s h o r t , w e n o w h a v e t h c h o i c e o p a y i n g o n l y f o t h f e a t u r e s w n e e d m o s t f o t h t a s k a h a n d ( w h i c h , b t h w a y , i o n r e a s o n s o m e o t h e o t h e r m a c h i n e s a r e s o e x p e n s i v e . )

T h e r e ' s o n o t h e r t r a i t t h a t b e c o m e s m o r e a n d m o r e a p p a r e n t w i t he a c h n e m a c h i n e f r o m C o m m o d o r e . V e r t i c a l I n t e g r a t i o n . W h i l eo t h e r m a n u f a c t u r e r s a r d e s i g n i n g c o m p u t e r s a r o u n d t h I C ' s ,C o m m o d o r e i d e v e l o p i n g n e I C ' s t o s u i t t h e i r c o m p u t e r s . I s e e m s r i g h t n o t h e r e ' s n l i m i t t h o f a c h i p t e c h n o l o g y c a a d v a n c e . A t h I g a i n s m o r e p o w e r , t h e r e w i l l b l e s s a n l e s ss u p p o r t i n g h a r d w a r e r e q u i r e d o t h s a m e P C b o a r d w h i c h c a no n l y r e s u l t i n b e t t e r , c h e a p e r , a n m o r e r e l i a b l e e q u i p m e n t .C o m m o d o r e i w e l l a w a r e o f t h e i r a t t r i b u t e s a n w i t h o u t d o u b tt h e y ' l l t a k e f u l l a d v a n t a g e o t h e m i t h e y e a r s a h e a d .

D e l i v e r y o t h n e m a c h i n e s h a j u s t b e g u n s i s h o u l d n ' t b l o n g b e f o r e y o s e m o r e a n m o r e m a t e r i a l b e c o m i n g a v a i l a b l e ,a n T h T r a n s a c t o r w i l l b n e x c e p t i o n . A c t u a l l y , w c a h a r d l yw a i t t g e s t a r t e d ! N o w , i w c o u l d o n l y g e o n e . . .

T h e r e ' s n o t h i n g a c o n s t a n t a c h a n g e , r e m a i n ,

T h T r a n s a c t o r V o l u m e 5 I s s u e 0

Page 6: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 6/88

N e w s B R

T r a n s a c t o r N e w sT h D i s k e t t e T r a n s a c t o r

S t a r t i n g w i t h t h i s i s s u e , t h p r o g r a m s p u b l i s h e d i e a c h T r a n s a c t o rw i l l b a v a i l a b l e o d i s k ! R e c e n t p r i c e r e d u c t i o n s o f l o p p y d i s k sa n t h a d v e n t o q u a l i t y h i g h - s p e e d d i s k d u p l i c a t i n g o u t f i t s h a v em a d e p o s s i b l e a s e r v i c e t h a t w a o n c e u n f e a s i b l e , i m p r a c t i c a l , a n t o e x p e n s i v e .

E a c h d i s k r e l e a s e w i l l c o n t a i n a s t a n d a r d s e t o f u t i l i t y p r o g r a m sf o l l o w e d b t h p r o g r a m s i t h c o r r e s p o n d i n g i s s u e , p l u s a n p r o g r a m s t h a t m a b u s e f u l o r r e l e v a n t t t h t h e m e o t h a t i s s u e ,o p e r h a p s s o m e l i g h t e n t e r t a i n m e n t . T h d i s k e t t e s a l s o m a k e i p o s s i b l e f o u t p r e s e n t o t h e r p o t e n t i a l l y i n v a l u a b l e p r o g r a m st h a t m i g h t n e v e r h a v e b e e n o b t a i n e d b e c a u s e t h e y w e r e t o l o n gt e n t e r b h a n d .

N c o p y l o c k p r o t e c t i o n w i l l b a d d e d t t h d i s k e t t e s a n f a u l t yc o p i e s w i l l b r e p l a c e d f r e e o f c h a r g e .

A u t h o r s t a k e n o t e - d e p e n d i n g o n t h s u c c e s s o f t h i s s e r v i c e ,r o y a l t y w i l l b p a i d e a c h t i m e y o u r p r o g r a m i r e s p o n s i b l e f o t h o r d e r .

T h P r i c e ? J u s t $ 9 . 9 5 C a n a d i a n f o y o u r f i r s t d i s k ! W i t h e v e r y d i s ks h i p p e d , a p e r s o n a l i z e d " m o n e y o f f " c o u p o n w i l l b e i n c l u d e d g o o df o $ O F t h p u r c h a s e o a n D i s k e t t e T r a n s a c t o r t h a t ' s j u s t$ 7 . 9 5 C D o r $ 5 . 9 5 U . S ! R e t u r n t h c o u p o n a n w e ' l l s e n d y o t h d i s k f o a n i s s u e y o c h o o s e ( V o 5 I s s u e 5 a n t h s a m ec o u p o n f o a n o t h e r $ d i s c o u n t ( u n t i l i g e t s w o r n o u o c o u r s e ) . I y o d e c i d e y o d o n ' t w a n t t h d i s k e t t e f o c e r t a i n i s s u e , k e e p t h c o u p o n u n t i l t h n e x t i s s u e . T h i s w a y o h a v e t h c h o i c e o o r d e r i n g t h e m i s s u e - b y - i s s u e , o n l y a s u b s c r i p t i o n p r i c e s .

T h f i r s t D i s k e t t e T r a n s a c t o r w i l l c o i n c i d e w i t h V o l u m e 5 I s s u e 0 5 ,( t h i s i s s u e ) a n w i l l b a v a i l a b l e b D e c e m b e r 1 5 . A l l f u t u r ed i s k e t t e s w i l l b r e a d y t h s a m e d a t h m a g a z i n e i r e l e a s e d ( s e eE d i t o r i a l S c h e d u l e ) . T o r d e r , s e n d $ 9 . 9 5 C d ( O n t a r i o r e s i d e n t sp l e a s e a d 1 s a l e s t a x ) o $ 7 . 5 0 U . S . o y o u r V i s a / M a s t e r C a r dn u m b e r ( i n c l u d e E x p i r y D a t e ) t o

T h D i s k e t t e T r a n s a c t o r5 0 S t e e l e s A v e n u eM i l t o n , O n t a r i oL 9 3 P

D i s k e t t e s a r e 4 0 4 0 / 1 5 4 1 o c o m p a t i b l e ( i e . M S D ) f o r m a t . W i t he n o u g h r e s p o n s e w e ' l l o f f e r 8 0 5 0 c o m p a t i b l e d i s k s t o o .

W a l s o p l a n t p a c k a m a n y p r o g r a m s a w c a f r o m p a s tT r a n s a c t o r s o n t o s e t o f o m o r e d i s k e t t e s . B u u n t i l w e k n o wh o w m a n y d i s k s w i l l b f i l l e d u p , a p r i c e c a n n o t b e d e t e r m i n e d .S e N e w s B R n e x t i s s u e f o d e t a i l s .

T h C o m p l e t e C o m m o d o r eI n n e r S p a c e A n t h o l o g y

T h a t ' s t h e n a m e w e ' v e s e t t l e d o f o t h m u c h a w a i t e d s e c o n de d i t i o n o T r a n s a c t o r R e f e r e n c e I s s u e . I n q u i r i e s f o t h b o o k h a v eb e e n c o m i n g i f r o m a r o u n d t h e w o r l d , w i t h s o m e r e p o r t s o p e o p l e l e a v i n g f u l l d e p o s i t s w i t h r e t a i l e r s .

A t h i s p o i n t , t h " T r a n s c y c l o p e d i a " ( a i t ' s a f f e c t i o n a t e l y k n o w n ) i w e l l o v e r 1 0 0 p a g e s o s t r i c t l y r e f e r e n c e m a t e r i a l . W h o l e s u b j e c t s o i n f o r m a t i o n h a v e b e e n s u m m a r i z e d a n p r e s e n t e d i t i d y ,c o m p a c t f o r m a t t h a t ' s b e e n d e s i g n e d w i t h t h c o m p u t e r e n t h u s i a s ti m i n d . S e v e r a l p a g e s c o n t a i n a m u c h a 2 0 , 0 0 0 c h a r a c t e r s e a c h !

S e c t i o n s i n c l u d e M u s i c , C o l o r a n G r a p h i c s , M a t h C o n v e r s i o nF o r m u l a e , H i g h L e v e l a n M a c h i n e L a n g u a g e s u m m a r i e s , H a r dw a r e a n d E l e c t r o n i c s , U s e r G r o u p s , C o m m u n i c a t i o n s , M e m o r yM a p s f o a l m a c h i n e s i n c l u d i n g t h e S e r i e s , + 4 / 1 6 , C O A L a n t h e 8 0 5 0 , 4 0 4 0 , a n 1 5 4 1 d i s k d r i v e s , C o n t r o l C o m m a n d s u m m a ri e f o a l t h m o s t p o p u l a r s o f t w a r e , p l u s a m o u n t a i n o g e n e r a lt y p e i n f o t h a t u s u a l l y c a n ' t b f o u n d a l i o n p l a c e . W i t h a n yl u c k , w e m a y a l s o g e t p e r m i s s i o n t r e p r i n t V I 2 a n C o m m od o r e 6 s c h e m a t i c s .

T h p r i c e s h o u l d b a v a i l a b l e b t h t i m e y o r e a d t h i s o D e c e m b e r 1 ' 8 4 , w h i c h e v e r c o m e s f i r s t . T h a t ' s a b o u t t h s a m ed a t e w e x p e c t t h a v e t h f i r s t c o p y o f t h p r e s s .

G e n e r a l N e w sM e m o r e x C a t a l o g

M e m o r e x C a n a d a , c o m p l e t e s u p p l i e r t t h c o m p u t e r a n w o r dp r o c e s s i n g i n d u s t r y s p e c i a l i z i n g i p e r i p h e r a l s a n a c c e s s o r i e s , i p l e a s e d t a n n o u n c e i m m e d i a t e a v a i l a b i l i t y o f t h e i r n e C o m p u t e rM e d i a a n C o m m u n i c a t i o n s c a t a l o g u e .

T h T r a n s a c t o r V o l u m e 5 I s s u e 0

Page 7: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 7/88

I r e s p o n s e t a i n c r e a s i n g d e m a n d f r o m t h e i r c u s t o m e r b a s e ,M e m o r e x h a p r o d u c e d 2 p a g e c a t a l o g u e o u t l i n i n g t h e c o p l e t e r a n g e o p r o d u c t s a v a i l a b l e f r o m M e m o r e x . T h e s e i n c l u d ec o m p u t e r t a p e , d i s c p a c k s , f l e x i b l e d i s c s , s c r e e n s , c o n t r o l l e r s , a n p r i n t e r s , a s w e l l a s a l a r g e s e l e c t i o n o s t o r a g e a n e r g o n o m i ca c c e s s o r i e s f o b o t h c o m p u t e r a n d w o r d p r o c e s s i n g e n v i r o n m e n t s .

P r o d u c t s m a y n o w b o r d e r e d v i t o l l f r e e p h o n e l i n e s a c r o s sC a n a d a a 1 - 8 0 0 - 2 6 8 - 9 8 8 6 .

H e l k o S y s t e m s F u r n i t u r e

H e l k o i p r o u d t a n n o u n c e t h d e s i g n a n d d e v e l o p m e n t o i t ' sn e w e s t e r g o n o m i c w o r k s t a t i o n - t h M i c r o D e s k .

T h M i c r o D e s k p r o v i d e s t h o p e r a t o r w i t h c o m p l e t e t e r m i n a ls u p p o r t s y s t e m a n a d e q u a t e w o r k i n g s u r f a c e . T h k e y b o a r d i f u l l y a d j u s t a b l e i t e r m s o h e i g h t , t i l t , d e p t h a n s w i v e l . A l v a r i a t i o n s t t h k e y b o a r d l o c a t i o n a r e a s i l y a c c o m p l i s h e d f r o ms e a t e d p o s i t i o n .

p u l l o u s h e l f p r o v i d e s t h o p e r a t o r w i t h a d d i t i o n a l w o r k s p a c e . I s l i d e s b a c k u n d e r t h u n i t w h e n i i n o r e q u i r e d . u t i l i t y s h e l fu n d e r n e a t h t h u n i t a n p r o v i d e s e a s i l y a c c e s s i b l e s t o r a g e f o d i s k e t t e s , o p e r a t o r m a n u a l s , p a p e r e t c .

T h s u r f a c e s a r e c o n s t r u c t e d w i t h ' m e l a m i n e ' - f i n i s h e d , t h r e el a y e r , t w d e n s i t y , 4 5 1 b . P S r e s i s t a n t p a r t i c l e b o a r d . A l s u r f a c e sa r w e a r , s c r a t c h a n i m p a c t r e s i s t a n t . F e e t a r e 1 6 g a u g e s t e e lp a i n t e d w i t h b r o w n t w c o m p o n e n t a p o x y f o d u r a b i l i t y a n s m o o t h f i n i s h . A d j u s t a b l e g l i d e s p e r m i t f i n e l e v e l l i n g t c o m p e ns a t e f o u n e v e n f l o o r s a n m i n i m i z e v i b r a t i o n .

C o l o r s a v a i l a b l e a r l i g h t o a k , w a l n u t a n p u t t y . F o f u r t h e ri n f o r m a t i o n , p l e a s e c o n t a c t :

G i l l i a n O x l e y , P u b l i c R e l a t i o n s D i r e c t o rH e l k o S y s t e m s F u r n i t u r e I n c .P B o 7 1 C o r n w a l l , O n t a r i oK 6 H 5 T 5 6 1 3 9 3 8 - 0 4 9 4 .

E v e n t sN e t w o r k C o m m u n i c a t i o n s S h o w

T h C o m m u n i c a t i o n N e t w o r k s C o n f e r e n c e E x p o s i t i o n i b e i n gh e l d J a n u a r y 2 8 - 3 1 , 1 9 8 5 a t h W a s h i n g t o n C o n v e n t i o n C t r . ,W a s h i n g t o n , D C . E x p o s p a c e r a t e w i l l b $ 1 9 . 5 0 / s q . f t

T h t r a d e s h o w w i l l b f e a t u r i n g v o i c e a n d a t a t e l e c o m m u n i c at i o n s , e l e c t r o n i c m a i l , d a t a p r o c e s s i n g , d a t a c o m m u n i c a t i o n s a n n e t w o r k i n g w i t h p e r s o n a l c o m p u t e r . F o f u r t h e r i n f o r m a t i o n ,c o n t a c t :

L o u i s e M y e r o w , R e g i s t r a t i o n M a n a g e rC W / C o n f e r e n c e M a n a g e m e n t G r o u p3 7 C o c h i t u a t e R o a d , B o 8 8 F r a m i n g h a m , M 0 1 7 0 16 1 8 7 9 - 0 7 0 0 o 8 0 2 2 5 - 4 6 9 8

S o f t w a r e N e w sE D E l e c t r o n i c s A n n o u n c e s A v a i l a b i l i t y o C o m p u S e r v eS o f t w a r e i C a n a d a .

E D E l e c t r o n i c s i p l e a s e d t a n n o u n c e t h a t i i n o e x c l u s i v ed i s t r i b u t o r i C a n a d a f o t h p r o d u c t s o C o m p u S e r v e I n f o r m a t i o nS e r v i c e s , o C o l u m b u s O h i o .

C o m p u S e r v e i a e a s y - t o - u s e v i d e o t e x s e r v i c e d e s i g n e d f o p e r s o n a l c o m p u t e r u s e r s a n m a n a g e d b t h c o m m u n i c a t i o n sp r o f e s s i o n a l s w h p r o v i d e b u s i n e s s i n f o r m a t i o n t o v e r o n f o u r t ho t h F O R T U N E 5 0 c o m p a n i e s .

S u b s c r i b e r s t t h C o n s u m e r I n f o r m a t i o n S e r v i c e r e c e i v e a w e a l t ho u s e f u l , p r o f i t a b l e a n i n t e r e s t i n g i n f o r m a t i o n l i k e n a t i o n a l n e w sw i r e s , e l e c t r o n i c b a n k i n g , a n s h o p a h o m e s e r v i c e s , a n s o p h i st i c a t e d f i n a n c i a l d a t a . T h e r e i a l s o c o m m u n i c a t i o n s n e t w o r k f o e l e c t r o n i c m a i l , b u l l e t i n b o a r d f o r s e l l i n g , s w a p p i n g , a n p e s o n a l n o t i c e s , a n m u l t i - c h a n n e l C s i m u l a t o r .

S u b s c r i b e r s t t h E x e c u t i v e I n f o r m a t i o n S e r v i c e r e c e i v e s e r i o u s ,u p - t o - t h e m i n u t e b u s i n e s s i n f o r m a t i o n i n c l u d i n g h i g h - l i g h t i n gi n v e s t m e n t i n f o r m a t i o n , c o m m u n i c a t i o n s , n e w s a n d t r a v e l . T h E x e c u t i v e I n f o r m a t i o n S e r v i c e a l s o p r o v i d e s a c c e s s t t h C o s u m e r I n f o r m a t i o n S e r v i c e . I p r o v i d e s I n f o P l e x e l e c t r o n i c m a i ls y s t e m , T i c k e r R e t r i e v a l f o e a s y a c c e s s o a l i n f o r m a t i o n a v a i l a b l eo a n c o m p a n y s p e c i f i e d , t r u e 2 m i n u t e d e l a y e d s t o c k q u o t at i o n s , M i c r o Q u o t e I I d e t a i l e d d e m o g r a p h i c d a t a , E x e c u t i v e N e w sS e r v i c e , p l u s m o r e s e r v i c e s t b a n n o u n c e d .

C o m p u S e r v e V i d t e x S o f t w a r e p r o v i d e s t e r m i n a l e m u l a t i o n f o p o p u l a r p e r s o n a l c o m p u t e r s i n c l u d i n g A p p l e a n d C o m m o d o r e .C o m p u S e r v e w i t h V i d t e x o f f e r s o p t i o n s l i k e c o l o u r g r a p h i c s , a u t om a t i c l o g o n , f u l l p r i n t e r s u p p o r t , R A b u f f e r , u s e r - d e f i n e d f u n ct i o n k e y s , c u r s o r p o s i t i o n i n g a n m o r e .

S u b s c r i b e r s t e i t h e r t h C o n s u m e r I n f o r m a t i o n S e r v i c e o r t h eE x e c u t i v e I n f o r m a t i o n S e r v i c e r e c e i v e a s u b s c r i p t i o n t O n l i n eT o d a y , C o m p u S e r v e ' s m o n t h l y m a g a z i n e o v i d e o t e x t a n i n f o rm a t i o n s y s t e m s .

E D E l e c t r o n i c D i s t r i b u t o r s i m a k i n g C o m p u S e r v e p r o d u c t s a v a i la b l e t h r o u g h n a t i o n - w i d e n e t w o r k o c o m p u t e r s t o r e s . P o t e n t i a l

T h T r a n s a c t o r V o l u m e 5 I s s u e 0

Page 8: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 8/88

d e a l e r s , d i s t r i b u t o r s a n d e n d u s e r s a r e i n v i t e d t c o n t a c t I a nM a n s o n , S a l e s M a n a g e r , E D E l e c t r o n i c s f o m o r e i n f o r m a t i o n .

E l e c t r o n i c D i s t r i b u t o r s I n c .3 9 5 0 C h e s s w o o d D r i v eD o w n s v i e w , O n t a r i oM 3 J 2 W 6 4 1 6 3 9 4 0 4

F r a n t e k S o f t w a r e d i s t r i b u t o r s f o S c a r b o r o u g h S y s t e m s .

F r a n t e k S o f t w a r e D i s t r i b u t o r s , I n c . ; 1 6 8 5 R u s s e l l R o a d ; O t t a w a ;O n t a r i o , h a b e e n n a m e d d i s t r i b u t o r o h o m e s o f t w a r e i t h e d u c a t i o n a l a n p r o d u c t i v i t y a r e a s b y S c a r b o r o u g h S y s t e m s , I n c . ,T a r r y t o w n , N . Y .

F r a n t e k S o f t w a r e w i l l d i s t r i b u t e S c a r b o r o u g h ' s e n t i r e p r o d u c t l i n e ,i n c l u d i n g M A S T E R T Y P E , t h e b e s t - s e l l i n g e d u c a t i o n a l s o f t w a r ep r o g r a m o a l t i m e ; P H B E T A F I L E R , l i s t m a n a g e m e n t p r o g r a mf o c h i l d r e n ; R U F O T H M O N E Y , b u s i n e s s g a m e w i t h as p a c e - a g e t h e m e ; Y O U R P E R S O N A L N E W O R T H , h o m e f i n a nc i a l m a n a g e m e n t p r o g r a m ; S O N G W R I T E R a n P A T T E R N M A K E R .

P l e a s e c o n t a c t :S a n f o r d B a i nS c a r b o r o u g h S y s t e m s , I n c .9 1 3 3 2 - 4 5 4 5

C o m m o d o r e N e w sC o m m o d o r e 6 E n h a n c e m e n t s

L a t e r e p o r t s h a v e i t h a t a C 1 2 8 i l i n e d u i t h C o m m o d o r eq u e u e . T h e C 1 2 8 i s a l l e d g e d l y , C o m m o d o r e 6 4 w i t h 1 2 8 K o R A w i t h t h e o p t i o n o a n 8 0 c o l u m n b l a c k a n w h i t e d i s p l a y .T h a t ' s e v e r y t h i n g f o n o t h o u g h w a t c h N e w s B R f o d e t a i l s o p r i c e , a v a i l a b i l i t y , p l u s a n o t h e r f e a t u r e s t h a t h a v e n ' t b e e n m e t i o n e d y e t .

C o m m o d o r e t D i s t r i b u t e N e H a n d i cS o f t w a r e N e t w o r k i n g D e v i c e s

C o m m o d o r e B u s i n e s s M a c h i n e s L i m i t e d , h a a n n o u n c e d d i s t r ib u t i o n a g r e e m e n t w i t h H a n d i c S o f t w a r e o P e n n s u k e n , N . J .w h e r e b y C o m m o d o r e w i l l b e x c l u s i v e d i s t r i b u t o r f o H a n d i cp r o d u c t s i C a n a d a .

S e v e r a l n e H a n d i c c a r t r i d g e s o f t w a r e p a c k a g e s a r n o a v a i l a b l ef o t h C o m m o d o r e 6 4

C a l c R e s u l t i t h r e e - d i m e n s i o n a l s p r e a d s h e e t t h a t c a t r a n s l a t en u m b e r s i n t o c h a r t s a t h p r e s s o a b u t t o n , a n W o r d R e s u l t i f u l l - f e a t u r e d w o r d p r o c e s s o r t h a t i n t e g r a t e s w i t h C a l c R e s u l t .

F o r t h 6 i p o w e r f u l o p e r a t i n g s y s t e m w i t h p r o g r a m m i n gl a n g u a g e t h a t i s u i t a b l e f o n e a r l y e v e r y i m a g i n a b l e a p p l i c a t i o n i b u s i n e s s a w e l l a i p r o c e s s c o n t r o l e n v i r o n m e n t s . S t a t 6 s i m p l i f i e s w o r k w i t h s t a t i s t i c s a n g r a p h i c d i s p l a y s . I a d d s 1 c o m m a n d s t t h B A S I C l a n g u a g e , s u c h a h o r i z o n t a l o v e r t i c a lb a c h a r t s , p l o t t i n g w i t h 3 8 7 1 p o i n t s , s c r e e n d u m p a n s t a t i s t i c a lc o m m a n d s f o c a l c u l a t i o n s o m e a n v a l u e , s t a n d a r d d e v i a t i o n ,v a r i a n c e a n m o r e .

G r a f 6 t u r n s s o l u t i o n s o e q u a t i o n s i n t o g r a p h i c a l a n a l y s i s . U s e r sc a d e f i n e f u n c t i o n s a n p l o t t h g r a p h i h i g h r e s o l u t i o n w i t h a X - a x i s r a n g e , a n t h e r e i s p e c i a l r o u t i n e f o c o m p u t i n g t h i n t e g r a l o a f u n c t i o n w i t h i n r a n g e s p e c i f i e d b t h u s e r .

T o o l 6 i p o w e r f u l p r o g r a m m i n g a n d d e b u g g i n g a i w h i c hi n c l u d e s n u m e r o u s n e c o m m a n d s , m a k i n g i p o s s i b l e t w r i t eb i g g e r a n m o r e a d v a n c e d p r o g r a m s u s i n g m u c h l e s s c o d e . T o o l6 h a a d v a n c e d i n p u t r o u t i n e s a n e x c e l l e n t p o s s i b i l i t i e s t oh a n d l e n u m b e r s a n t m a k e g r a p h i c s s u c h a b a r - a n p i e -c h a r t s .

T h C B M - 6 4 R e l a y C a r t r i d g e w i l l a l l o w C - 6 4 o w n e r s t c o n t r o lb u r g l a r a l a r m s , g a r a g e d o o r s , d o o r l o c k s , e l e c t r i c r a d i a t o r s , l a m p s ,t r a n s m i t t e r s , r e m o t e c o n t r o l s , v a l v e s , p u m p s , t e l e p h o n e s , a c c u m ul a t o r s , i r r i g a t i o n s y s t e m s , e l e c t r i c t o o l s , s t o p w a t c h e s , v e n t i l a t o r s ,a i c o n d i t i o n e r s , h u m i d i f i e r s , m i n i a t u r e r a i l r o a d s a n m a n y o t h e rd e v i c e s w i t h t h e i r C o m m o d o r e 6 4 s .

B r i d g e 6 4 i a b r i d g e g a m e w i t h n u m e r o u s l e v e l s , f r o m n o v i c e t a d v a n c e d . B r i d g e 6 o f f e r s h e l p i n g p a r t n e r o r s k i l l e d o p p o n e n tw i t h t h o u s a n d s o d i f f e r e n t b i d s a n e x c e l l e n t g r a p h i c s .

C o m m o d o r e i a l s o n o d i s t r i b u t i n g l o w - c o s t n e t w o r k i n g d e v i c e sf o i t C - 6 4 , V I C - 2 0 a n P E T / C B M m o d e l s .

V I C - S W I T C H a l l o w s u t e i g h t C o m m o d o r e 6 4 o V I C - 2 0 s t s e q u e n t i a l l y s h a r e o n d i s k d r i v e o r p r i n t e r . V I C - S W I T C H w a d e v e l o p e d e s p e c i a l l y f o e d u c a t i o n a l u s b u h a p r o v e n s u c c e s s f u li e v e r y a p p l i c a t i o n w h e r e m o r e t h a n o n e V I C - 2 0 O C 6 n e e d sa c c e s s t t h s a m e d i s k o r t h e s a m e p r i n t e r .

P E T - S W I T C H a l l o w s u t 1 C o m m o d o r e P E T 4 0 0 0 a n d / o r C B 8 0 0 0 s e r i e s m i c r o s t b c o n n e c t e d t t h s a m e d i s k d r i v e a n p r i n t e r . I n P E T - S W I T C H s y s t e m , t h e r e i d i s t r i b u t e d d a t a p o w e r ,w h e r e d a t a f r o m t h c e n t r a l d i s k d r i v e , w o r k s w i t h i a n t h e ns a v e s t h r e s u l t i n g d a t a b a c k t t h d i s k .

P E T - S W I T C H i v e r y u s e f u l i s c h o o l s , o f f i c e s , s e r v i c e b u r e a u sa n o t h e r a p p l i c a t i o n s w h e r e s e v e r a l p e o p l e n e e d c o n t i n u o u sa c c e s s t p a r t i c u l a r d a t a . W i t h P E T - S W I T C H t h i s i a c h i e v e d ,w h i l e s y s t e m c o s t s c a n b e c u t c o n s i d e r a b l y .

F o f u r t h e r i n f o r m a t i o n :R o b e r t L ' E s p e r a n c eN a t i o n a l S o f t w a r e M a n a g e rC o m m o d o r e B u s i n e s s M a c h i n e s L i m i t e d7 2 6 1 V i c t o r i a P a r k A v e n u eM a r k h a m , O n t a r i o .L 3 R 2 M 7 4 1 6 4 7 5 - 5 1 1 1

N e R e c r e a t i o n a l S o f t w a r e f o t h + a n C 1

J A C K A T T A C K i c h a r m i n g v i d e o s t r a t e g y g a m e . M a k e J a c kj u m p o t h m o n s t e r s b e f o r e t h e y j u m p o n h i m , o d r o p b l o c k s o t h e i r h e a d s . R a c e a g a i n s t t i m e f o t h p l a t f o r m a n r o u n d b o n u s e s .6 d i f f e r e n t s c r e e n s f o l o n g - l a s t i n g f u n ! N o m i n a t e d a B e s t G a m eo 1 9 8 4 b E l e c t r o n i c G a m e s M a g a z i n e . P L U S / 4 , C C a r t r i d g e .

P I R A T E A D V E N T U R E i a c h a l l e n g i n g t e x t a d v e n t u r e . F i n d y o u rw a f r o m L o n d o n a p a r t m e n t t P i r a t e I s l a n d , t h e n t a k e t h e p i r a t es h i p t T r e a s u r e I s l a n d . B s u r e t o l i s t e n t o t h e p a r r o t o n s m a r tb i r d ! P L U S / 4 , C C a r t r i d g e .

T h T r a n s a c t o r V o l u m e 5 I s s u e 0

Page 9: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 9/88

A T O M I C M I S S I O N i d e v i o u s t e x t a d v e n t u r e . Y o a r l o c k e di n s i d e a n u c l e a r r e a c t o r w h i c h h a b e e n p r o g r a m m e d b m a s c i e n t i s t t o e x p l o d e . Y o u r m i s s i o n i t f o o l t h s e c u r i t y s y s t e m a n d e a c t i v a t e t h e b o m b ! P L U S / 4 , C l C a r t r i d g e .

S T R A N G E O D Y S S E Y i a s c i e n c e f i c t i o n t e x t a d v e n t u r e . D i s c o v e rt h s e c r e t t t h m a c h i n e s i s p a c e s h i p , a n f i n d t h t r e a s u r e sh i d d e n o t h d i f f e r e n t w o r l d s ! P L U S / 4 , C C a r t r i d g e .

S C R I P T / P L U S i a a d v a n c e d , f u l l - f e a t u r e d , p r o f e s s i o n a l w o r dp r o c e s s o r c o m p l e t e w i t h o n - l i n e h e l p s c r e e n s . I t ' s f e a t u r e s i n c l u d ew o r d w r a p , f u l l s c r e e n e d i t i n g , g l o b a l a n l o c a l s e a r c h a n r e p l a c e ,a u t o m a t i c c e n t e r i n g , j u s t i f i c a t i o n a n r i g h t a l i g n m e n t , a n d e c i m a la l i g n m e n t . T h e r e a r a u t o m a t i c m a i l m e r g e w i t h s e l e c t i v e s e a r c hc r i t e r i a , a n f i l e l i n k i n g f o e a s y d o c u m e n t h a n d l i n g . O n o t h m o r e a d v a n c e d f e a t u r e s i t h c a p a b i l i t y f o r o a n c o l u m na r i t h m e t i c a n c o l u m n m o v e , t s i m u l a t e s p r e a d s h e e t o r c a l c u l at o w i t h i n y o u r d o c u m e n t . S C R I P T / P L U S a l s o c o n t a i n s a i n f o r m at i v e s t a t u s l i n e t h e l p m a k e y o u r w o r d p r o c e s s o r e a s y t u s e .P L U S / 4 , C l C a r t r i d g e .

F I N A N C I A L A D V I S O R i f i n a n c i a l p r o g r a m d e s i g n e d f o t h h i g hs c h o o l / c o l l e g e f i n a n c e s t u d e n t f o t h e l o a n o f f i c e r a t h b a n k .F I N A N C I A L A D V I S O R c a l c u l a t e s t h h i g h c o s t a n b e n e f i t s o f i v ec o m m o n f i n a n c i a l s t r a t e g i e s : P e r i o d i c D e p o s i t A c c o u n t s , P e r i o d i cW i t h d r a w a l A c c o u n t s , I n s t a l l m e n t L o a n s , S t o c k s a n B o n d s . E a c hf i n a n c i a l s t r a t e g y i b r o k e n d o w n i n t o p i e c e s s o y o c a c h a n g ee v e r y f a c e t o f t h e l o a n o r i n v e s t m e n t c a l c u l a t i o n . B o t h c o m p o u n di n a n t r a n s a c t i o n p e r i o d s c a n b e c h a n g e d q u i c k l y a n e a s i l y . I a d d i t i o n , s p e c i a l c a l c u l a t o r m o d e l e t s y o i n t e r r u p t p r o b l e m t p e r f o r m c a l c u l a t i o n s , w i t h o u t d i s t u r b i n g y o u r c u r r e n t w o r k . T h e r ea r 1 0 " m e m o r i e s " i w h i c h i n t e r m e d i a t e r e s u l t s m a b s a v e d .A l c a l c u l a t i o n s m a b p r i n t e d . P L U S / 4 C a r t r i d g e .

L O G O i t h c o m p u t e r l a n g u a g e f o e v e r y o n e . I t ' s s i m p l e e n o u g hf o p r e s c h o o l e r s a n s o p h i s t i c a t e d e n o u g h t c h a l l e n g e c o l l e g es t u d e n t s . S p e c i a l f e a t u r e s o L o g o i n c l u d e s T u r t l e G r a p h i c s w h i c ha l l o w s t h e u s e r t d r a w p i c t u r e s , S p l i t s c r e e n w h i c h a l l o w s t h e u s e rt w a t c h t h e i r p i c t u r e f o r m a t h e y a r e d e v e l o p i n g t h e i r p r o g r a m ,F u l l s c r e e n w h i c h a l l o w s t h u s e r t s e o n l y t h e i r p i c t u r e , a n E d i tf o e a s y p r o g r a m c o r r e c t i o n s . T h p r o g r a m m e r c a u s e i t h e rs i m p l e L o g o c o m m a n d s o m o r e c o m p l e x p r o c e d u r e t c r e a t ep r o g r a m s . L o g o a l s o u s e s t h h i g h a n l o r e s o l u t i o n g r a p h i c s , t h 1 2 c o l o r s , a n m u s i c c a p a b i l i t i e s o t h C o m m o d o r e P L U S / 4c o m p u t e r . T h s t e p b s t e p m a n u a l m a k e s l e a r n i n g L o g o e a s y .P L U S / 4 C a r t r i d g e a n u t i l i t y d i s k .

P L U S / 4 T U T O R I A L a n d C 1 6 T U T O R I A L i a v a i l a b l e a a i n t r od u c t i o n t h t h m a c h i n e s . I f r i e n d l y f o r m a t , i t e a c h e s t h ek e y b o a r d a n l e t s t h e u s e r p r a c t i c e u s i n g t h e v a r i o u s k e y s . T h t u t o r i a l h a s t e p b s t e p a p p r o a c h : v a r i o u s s e c t i o n s c o v e r c u r s o rc o n t r o l k e y s , a l p h a b e t i c k e y s , g r a p h i c k e y s , c o l o r s a n r e v e r s ek e y s , c o n t r o l k e y s s u c h a e s c a p e a n f u n c t i o n k e y s , e t c . T h c a p a b i l i t i e s s u c h a g r a p h i c s , c o l o r , s o u n d , f l a s h i n g a n w i n d o wa r u s e d t m a k e t h t u t o r i n t e r e s t i n g a n e d u c a t i o n a l l y e f f e c t i v e .P L U S / 4 , C l C a r t r i d g e .

C O M A L : P r o g r a m F o T h F u t u r e T o d a y !

Y o u r c o m p u t e r i o n l y a g o o d a s t h e p r o g r a m s i r u n s . U n l e a s h t h p o w e r b u i l t i n t o y o u r C o m m o d o r e 6 4 T a k e c o n t r o l w i t h C O M A L ,o n o t h f a s t e s t g r o w i n g p r o g r a m m i n g l a n g u a g e s i t h w o r l d .

C O M A L i e x p e r t l y d e s i g n e d a n s h i n e s a f t e r f u l l 1 0 y e a r s o r e f i n e m e n t . W i t h C O M A L y o g e o n l y t h b e s t . T h b e s t o fP A S C A L ; s t r u c t u r e s . T h b e s t o L O G O ; t u r t l e g r a p h i c s . T h b e s t o M O D U L A 2 m o d u l e s . T h b e s t o A D A ; p a c k a g e s . A n e v e n w i t ha l t h p o w e r a n f l e x i b i l i t y , i r e t a i n s t h b e s t p a r t o B A S I C ; e a s eo u s e . B u b e s t o a l l , i t ' s f a s t a n a f f o r d a b l e .

W h i l e p r o f e s s i o n a l p r o g r a m m e r s m a r v e l o v e r t h C O M A L 2 . C a r t r i d g e , m o s t C o m m o d o r e 6 u s e r s c a b e n e f i t f r o m C O M A L0 . 1 4 w h i c h a l r e a d y i p a r t o m o s t C o m m o d o r e U s e r G r o u p D i s kl i b r a r i e s . C O M A L i h e r e t s t a y a e v i d e n c e d b y t h m u l t i t u d e s o p r o g r a m s a n d b o o k s a v a i l a b l e . T h e r e a l r e a d y a r o v e r 1 5 d i s k s f u l lo r e a d y t r u C O M A L p r o g r a m s a n d i f f e r e n t C O M A L b o o k s .B C h r i s t m a s t h e r e s h o u l d b a n o t h e r 1 0 d i s k s o p r o g r a m s a n m o r e b o o k s . T h e r e e v e n i n e w s l e t t e r , C O M A L T O D A Y , d e v o t e ds o l e l y t C O M A L , a l r e a d y 5 6 p a g e s i i t f o u r t h i s s u e .

H o w e v e r , t h b e s t n e w s o a l i t h a t t h C O M A L 2 . c a r t r i d g e i a l r e a d y i n t o m a s s p r o d u c t i o n b C o m m o d o r e i E u r o p e a n t h a tt h C O M A L U s e r s G r o u p w i l l b d i s t r i b u t i n g i i t h U n i t e d S t a t e s .T h i s c a r t r i d g e i t h s a m e s i z e a s C o m m o d o r e 8 K g a m e c a r t r i d g e ,y e t i n s i d e i c o m p l e t e 6 4 k C O M A L s y s t e m i R O M . T h e r e i e v e na e m p t y s o c k e t f o a o p t i o n a l 8 K 1 6 K , o 3 2 E P R O M . T h C O M A L c a r t r i d g e c o n t a i n s e v e r y t h i n g f r o m t h e d i s k l o a d e dC O M A L 0 . 1 4 p l u s m u c h m o r e . I a d d i t i o n a l t a l t h e f u n o C O M A L , t h c a r t r i d g e p r o v i d e s p r o f e s s i o n a l l a n g u a g e , w i t hT R A C E , E R R O R H A N D L E R S , E X T E R N A L P R O C E D U R E S , B A T C HC O M M A N D F I L E S , a n d i f f e r e n t s c r e e n d u m p s a l b u i l t i n N w o n d e r C o m m o d o r e c a n ' t k e e p u w i t h t h d e m a n d f o t h C O M A L 2 . C a r t r i d g e i E u r o p e .

S n o t h c h o i c e i n o w h e t h e r t u s C O M A L o n o t , b u w h i c hv e r s i o n ? G e s t a r t e d w i t h d i s k l o a d e d C O M A L 0 . 1 4 w i t h t h $ 1 9 . 9 5E n h a n c e d C O M A L P a k , i n c l u d i n g 2 d i s k s a n r e f e r e n c e c a r d , o t h $ 2 9 . 9 5 C O M A L S t a r t e r K i w h i c h a d d s b o o k a n d t h i r d d i s ki n s i d e a n i c e c a s e . B u i o n l y t h b e s t i g o o d e n o u g h f o y o u , t h e ny o w i l l w a n t t h $ 9 9 . 9 5 C O M A L 2 . C a r t r i d g e p a c k a g e , i n c l u d i n g

b o o k s , d i s k s , a n t h c a r t r i d g e i c u s t o m m o l d e d c a s e . I y o c a n ' t m a k e u y o u r m i n d , s e n d S e l f A d d r e s s e d S t a m p e d E n v el o p e f o F R E E C O M A L I N F O P A K .

V I S A a n d M a s t e r C a r d o r d e r s c a c a l l t o l l - f r e e 1 - 8 0 0 3 5 6 - 5 3 2 4e x t e n s i o n 1 3 0 7 . E v e r y t h i n g i a v a i l a b l e f r o m t h o f f i c i a l s o u r c e :

C O M A L U s e r s G r o u p , U . S . A . , L i m i t e d5 5 0 1 G r o v e l a n d T e r r a c eM a d i s o n , W 5 3 7 1 6 6 0 2 2 2 - 4 4 3 2

T P U G O f f e r s C O M A L P r i m e r a n M a n u a l

T P U G ( t h e w o r l d ' s l a r g e s t C o m m o d o r e u s e r s g r o u p ) i p l e a s e d t a n n o u n c e t h e p u b l i c a t i o n o n e C O M A L p r o g r a m m i n g m a n u a l ,w r i t t e n b y o n e o t h e l a n g u a g e ' s c r e a t o r s , B o r g e C h r i s t e n s e n .

C O M A L i h i g h - l e v e l l a n g u a g e w i t h a l t h e l e m e n t s t h a t m a k eB A S I C s i m p l e f o t h b e g i n n e r b u w i t h a d d i t i o n a l f e a t u r e s t h a tm a k e i e a s y t w r i t e w e l l - s t r u c t u r e d p r o g r a m s .

T h b o o k c o n t a i n s o v e r f i f t y p a g e s o t e x t a n e x a m p l e s . I i i d e a l l y s u i t e d a s l a n g u a g e t u t o r i a l a w e l l a d e s k - t o p r e f e r e n c em a n u a l f o p r o g r a m m e r s . T h c o s t i 3 . 9 5 . F o r i n f o r m a t i o n o

T h T r a n s a c t o r V o l u m e 5 I s s u e 0

Page 10: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 10/88

t h i s a n m o r e T P U G s o f t w a r e , w r i t e t o

T P U G I n c .1 9 1 2 A A v e n u e R o a d ,S u i t e # T o r o n t o , O n t a r i o . M 5 4 A

E n T e c h I n t r o d u c e s E n h a n c e d S t u d i o 6

S i n c e i t i n t r o d u c t i o n i M a y , 1 9 8 3 , E n T e c h S o f t w a r e ' s S t u d i o 6 h a r e c e i v e d c r i t i c a l a c c l a i m a n b l o s s o m i n g s a l e s . N o w , E n T e c hh a s g i v e n i t m o s t p o p u l a r p r o g r a m f o t h C o m m o d o r e 6 m a j o rr e d e s i g n i n g w h i c h w i l l m a k e i e v e n e a s i e r a n m o r e f l e x i b l e t u s e .

S t u d i o 6 c r e a t e s m u s i c a i i p l a y e d o t h C o m m o d o r e 6 k e y b o a r d , a n i i t h o n l y p r o g r a m t h a t a l l o w s e a c h n o t e t h a v e

d i f f e r e n t w a v e f o r m s o u n d . I c a c r e a t e s o n g s u t e i g h t m i n u t e sl o n g w h i c h c a b e s a v e d t d i s k o a d d e d t a n o t h e r p r o g r a m .S t u d i o 6 n o f e a t u r e s n o t e s i h i g h r e s o l u t i o n g r a p h i c s a n t r u e rm u s i c a l n o t a t i o n , i n c l u d i n g t i e d n o t e s , s h a r p s a n f l a t s . C o n t r o lk e f u n c t i o n s m a k e i e a s i e r t c h a n g e v o i c e s a n c l e f s , p l a y b a c km u s i c a n a d j u s t s o u n d s a n f i l t e r s . T h n e v e r s i o n a l s o h a t w e l v e s a m p l e s o n g s i n c l u d i n g " B i l l i e J e a n " a n " S w e e t D r e a m s " .

W i t h i t m a n y i m p r o v e m e n t s , S t u d i o 6 i s t i l l c o m p a t i b l e w i t hA d M u s ' I n , w h i c h a d d s m u s i c t a n o t h e r p r o g r a m . T h n e S t u d i o 6 w i l l a l s o p l a y m u s i c c r e a t e d w i t h t h e o l d e r v e r s i o n , a n m u s i c c r e a t e d w i t h e i t h e r v e r s i o n w i l l b a c c e p t e d f o E n T e c h ' sF i r s t A n n u a l C o m p u t e r S o n g W r i t i n g C o n t e s t .

S t u d i o 6 4 ' s m a j o r r e v i s i o n s w e r e m a d e b R a S o u l a r , m u s i c i a na n r e c o r d p r o d u c e r a w e l l a E n T e c h ' s c h a i r m a n . " T h i s v e r s i o nw a d e s i g n e d b t h e p u b l i c r a t h e r t h a n p r o g r a m m e r s , " S o u l a r s a i d ." W e ' v e t a k e n i n t o c o n s i d e r a t i o n e v e r y p o s s i b l e s u g g e s t i o n t c r e a t e t h e u l t i m a t e m u s i c s y n t h e s i z e r . "

T h n e S t u d i o 6 w i l l r e t a i l a t t h s a m e p r i c e a s t h e o r i g i n a l ,$ 3 9 . 9 5 . W h i l e t h n e v e r s i o n i a v a i l a b l e o n l y o d i s k , t h o r i g i n a l v e r s i o n i s t i l l a v a i l a b l e o c a s s e t t e . C u r r e n t S t u d i o 6 o w n e r s c a u p g r a d e t t h n e v e r s i o n b s e n d i n g $ 1 a n t h e i ro l d d i s k t o

A d $ 3 . 0 0 t t o t a l o r d e r f o p o s t a g e a n h a n d l i n g . M E L C H E RS O F T W A R E w e l c o m e i n q u i r i e s a b o u t t h e s e p r o g r a m s . C o n t a c t :

M e l v i n B i l l i kM E L C H E R S O F T W A R EP B o 2 1 M i d l a n d , M 4 8 6 4 0 5 1 7 6 3 1 - 7 6 0 7 .

M i c r o E d O f f e r s T w P r e s i d e n t i a l E l e c t i o n P r o g r a m s

M i c r o E d I n c o r p o r a t e d , p u b l i s h e r s o m o r e t h a n o n e t h o u s a n de d u c a t i o n a l p r o g r a m s , i c u r r e n t l y m a k i n g s p e c i a l m a r k e t i n ge f f o r t o b e h a l f o t w p r e s i d e n t i a l e l e c t i o n p r o g r a m s f o t h C o m m o d o r e 6 4 H A I T H R I N G a n T H A M E R I C A N P R E S ID E N C Y .

H a i t h R i n g i t w o - p l a y e r ( o t w o - t e a m ) e x e r c i s e d e s i g n e d t a c q u a i n t s t u d e n t s w i t h s o m e o t h p o l i t i c a l c o n s i d e r a t i o n s i v o l v e d i r u n n i n g p r e s i d e n t i a l c a n d i d a t e o n f o t h R e p u b l ic a n s , t h e o t h e r f o t h D e m o c r a t s . T h r o u g h o u t t h e x e r c i s e , e a c hc a n d i d a t e w o r k s t h e t h e f a c t o r s o m e d i a e x p o s u r e , p e r s o n a lc a m p a i g n i n g , d o m e s t i c i s s u e s , a n i n t e r n a t i o n a l i s s u e s i o r d e r t m a k e d e c i s i o n s t h a t w i l l r e s u l t i a s u c c e s s f u l c a m p a i g n . S u g g e s t e dr e t a i l p r i c e f o t h p r o g r a m i $ 9 . 9 5 .

T h A m e r i c a n P r e s i d e n c y i s e t o f f o u r p r o g r a m s d e s i g n e d t p r e s e n t g e n e r a l i n f o r m a t i o n a b o u t , a n h i s t o r i c a l r e v i e w o f t h o f f i c e a n t h o s e w h h a v e h e l d i t I n c l u d e d i t r e a t m e n t o T H O F F I C E , T H D U T I E S , T H P R E S I D E N T 8 1 7 8 8 - 1 8 8 8 ) , a n T H P R E S I D E N T S 8 1 8 9 2 - 1 9 8 0 ) . o n e - o t w o - p l a y e r ( o t e a m ) g a m ei a t t a c h e d t e a c h o t h e i n s t r u c t i o n a l l e s s o n s . T h s u g g e s t e d r e t a i lp r i c e f o t h 4 - p r o g r a m s e i # 3 4 . 9 5 .

P e r s o n s d e s i r i n g f u r t h e r i n f o r m a t i o n m a c a l l G e o r g e E s b e n s e n a t o l l f r e e 1 - 8 0 0 - M i c r o E d .

M i c r o E d , I n c .P B o x 4 4 4 0 0 5E d e n P r a i r i e , M i n n e s o t a5 5 3 4 4 6 1 2 9 4 4 8 7 5 0

E n T e c h S o f t w a r eP B o 1 8 S u V a l l e y , C 9 1 3 5 3 8 1 7 6 8 - 6 6 4 6 .

M e l c h e r S o f t w a r e A n n o u n c e s T w M u s i c T u t o r P r o g r a m s

T h P I A N O T U T O R a n t h V I O L I N T U T O R b o t h e n h a n c e n o t er e a d i n g a b i l i t y a n s o u n d i d e n t i f i c a t i o n . T h c o m p u t e r d e p i c t sn o t e p l a c e m e n t o t h s c a l e ( t r e b l e a n b a s s c l e f f o t h p i a n o ) ,s o u n d s t h n o t e , a n a s k s f o t h n o t e i d e n t i f i c a t i o n . T h s t u d e n t ' ss c o r e i c o m p u t e d f o s p e e d a n a c c u r a c y . C o l o r f u l g r a p h i c s a n s t i m u l a t i n g s o u n d m a k e t h e s e p r o g r a m s d y n a m i c t o o l s f o t o d a y ' sa m b i t i o u s m u s i c s t u d e n t .

T h c o s t o t h a b o v e p r o g r a m s i $ 2 9 . 9 5 f o R E C I P E S S U P R E M Ea n $ 1 9 . 9 5 f o e i t h e r t h P I A N O T U T O R o r t h e V I O L I N T U T O R . I p u r c h a s e d t o g e t h e r , b o t h m u s i c p r o g r a m s a r a v a i l a b l e f o $ 3 4 . 9 5 .

R E C O R D B O O K : D a t a S t o r a g e a n R e t r i e v a lS y s t e m f o A L L C o m m o d o r e c o m p u t e r s

M a n y c o m p u t e r o w n e r s a s " W h a t c a m c o m p u t e r d f o m e R e c o r d B o o k p r o v i d e s a a n s w e r .

R e c o r d B o o k a l l o w s y o t s t o r e a n c a t e g o r i z e d i n f o r m a t i o n o d i s k . I i i d e a l f o k e e p i n g p h o n e n u m b e r s , m a i l i n g l i s t s , h o m ei n v e n t o r y , a n e v e n s o m e b u s i n e s s r e c o r d s ( l i k e o u t s t a n d i n gd e b t s , s u p p l i e r l i s t s , i n v e n t o r y ) . O n c e i n f o r m a t i o n i p u i n t o f i l e ,i c a n b e s e a r c h e d t h r o u g h , c h a n g e d , a d d e d t o d e l e t e d , o r s o r t e d .A l l o f t h e s e f u n c t i o n s a r a t h t o u c h o f e k e y s . R e c o r d B o o ka l s o s u p p o r t s p r i n t i n g o a l o s e l e c t e d p a r t s o f i l e t a n p r o p e r l y i n t e r f a c e d p r i n t e r .

R e c o r d B o o k r e q u i r e s o n l y 1 6 R A M , 4 ( o 8 0 c o l u m n s a n d , o c o u r s e , a d i s k d r i v e . V I C - 2 0 c a f i l l t h i s b i l l , i f i t i e x p a n d e d w i t h

I R A a n 4 0 - c o l u m n a d a p t e r .

T h T r a n s a c t o r V o l u m e 5 I s s u e 0

Page 11: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 11/88

R e c o r d B o o k c o m e s w i t h a d e t a i l e d m a n u a l w h i c h d e s c r i b e s a l R e c o r d B o o k f u n c t i o n s a n e v e n t a k e s y o o ' l i v e g u i d e d t o u r 't h r o u g h s o m e o t h m o s t - u s e d f e a t u r e s . R e c o r d B o o k i c o p l e t e l y m e n u - d r i v e n , w h i c h m e a n s t h a t t h n o v i c e u s e r c a n n o t g e l o s t o f o r g e t a c o m m a n d , b u d e m a n d i n g u s e r s w i l l f i n d i t m a n yf u n c t i o n s a d v a n c e d a n c o n v e n i e n t . I y o h a v e d a t a , r e c o r d B o o kw i l l h a n d l e i t

R e c o r d B o o k c o s t s $ 2 5 . 0 0 , b u i d o e s w h a t f a m o r e e x p e n s i v ed a t a b a s e s d o

T h a u t h o r r u n s a b u l l e t i n b o a r d ( a c c e s s i b l e o n l y b y 3 0 0 b a u dm o d e m ) a 4 1 6 2 3 9 - 5 9 9 3 . H c a b r e a c h e d t h e r e a s w e l l a a t h a b o v e a d d r e s s .

M a d i l l a n d W e l s h C o m p u t i n g7 S t r a t h H u m b e r C o u r tI s l i n g t o n . O n t a r i o M 9 4 C

H o T M a k e G o o d I n v e s t m e n t s

C o m p u t e r a i d e d i n s t r u c t i o n f o t h C o m m o d o r e 6 4 g e a r e d t t e a c h y o t h f u n d a m e n t a l s o s t o c k m a r k e t a n r e a l e s t a t ei n v e s t m e n t a n a l y s i s , i t h f i r s t c o u r s e i s e r i e s o c o u r s e s o i n v e s t m e n t a n f i n a n c i a l a n a l y s i s d e v e l o p e d b y e x p e r i e n c e d p r f e s s i o n a l s f r o m t h e t o p b u s i n e s s s c h o o l s .

T h c o u r s e s a r d e s i g n e d t c o v e r t h s a m e m a t e r i a l a i c o v e r e di t h b e s t b u s i n e s s s c h o o l s w i t h s o m e p r a c t i c a l s t r e e t t e c h n i q u e s .T h i n v e s t m e n t t e c h n i q u e s i t h i n i t i a l c o u r s e w e r e s e l e c t e d f o t h e i r e a s e o u s a n u n d e r s t a n d i n g . P r o g r a m s a n d e x a m p l e su s i n g t h o s e p r o g r a m s a r p r o v i d e d a l e a r n i n g a i d s a n f o s u b s eq u e n t i n v e s t m e n t a n a l y s i s .

C o u r s e I H O T M A K E G O O D I N V E S T M E N T S " c o m e s c o p l e t e w i t h 1 0 p a g e t e x t a n p r o g r a m s o n d i s k f o $ 5 4 . 9 5 . T h i sc o u r s e a n a d d i t i o n a l c o u r s e s m a b t a x d e d u c t i b l e . ( C o m m o d o r e6 i r e g i s t e r e d t r a d e m a r k o C o m m o d o r e E l e c t r o n i c s L t d . ) S e n d$ 5 4 . 9 5 c h e c k o m o n e y o r d e r t o

C o u r s eT h W i z a r d sP B o 7 1 1 8T h W o o d l a n d s , T 7 7 3 8 7

I n v e s t m e n t a n S t a t i s t i c a l S o f t w a r e P a c k a g e

C o m m o d o r e U s e r s c a n o g a i n a c c e s s t t h e l e a d i n g i n v e s t m e n ta n s t a t i s t i c a l s o f t w a r e u s e d b I B a n o t h e r c o m p u t e r s .

P r o g r a m m e d P r e s s a n n o u n c e s t h a t i t I n v e s t m e n t a n S t a t i s t i c a lS o f t w a r e P a c k a g e , c o n t a i n i n g 5 0 p r o g r a m s f o r S t a t i s t i c a l F o r e c a s ti n g , S t o c k s , B o n d s , O p t i o n s , F u t u r e s a n F o r e i g n E x c h a n g e , i " r e a d y - t o - r u n " o t h C - 6 4 .

T h 2 2 p a g e C o m p u t e r - A s s i s t e d I n v e s t m e n t H a n d b o o k b D r A l b e r t B o o k b i n d e r l i s t s , e x p l a i n s a n g i v e s s a m p l e R U i l l u s t r at i o n s f o a l l f i f t y B A S I C p r o g r a m s f o p r o f i t a b l e p l a n n i n g a n f o r e c a s t i n g .

T h i s s o f t w a r e s u p p o r t s C o m m o d o r e , A p p l e , R a d i o S h a c k , a n I B p e r s o n a l c o m p u t e r s , a w e l l a o t h e r m a c h i n e s u s i n g M S - D O S .

C o m m o d o r e 6 r e q u i r e s o n l y o n d i s k d r i v e . T h p r i c e i $ 1 0 0 f o t h " r e a d y - t o - r u n " I n v e s t m e n t a n S t a t i s t i c a l S o f t w a r e a n o n l y$ 1 9 . 9 5 f o t h H a n d b o o k t h a t l i s t s a l l 5 0 p r o g r a m s . V I S A a n dM a s t e r C a r d s a r e a c c e p t e d .

P r o g r a m m e d P r e s s2 3 0 1 B a y l i s A v e . ,E l m o n t , N 1 1 0 0 3 5 1 6 7 7 5 - 0 9 3 3

H a r d w a r e N e w sM I C R O S H A R E 6 4 n e t w o r k i n g s y s t e m

T h M i c r o s h a r e 6 i n e t w o r k i n g s y s t e m t h a t a l l o w s u t C 6 4 st b e c o n n e c t e d t c o m m o n I E E E o s e r i a l b u s . T h s y s t e m c a nb c o n f i g u r e d f o c o m p u t e r s a n a I E E E b u s , o r c o m p u t e r sw i t h b o t h I E E E a n d s e r i a l . U s e r s a r g i v e n a c c e s s t t h b u o " f i r s t c o m e , f i r s t s e r v e d " q u e u i n g b a s i s , t h n e x t u s e r b e i n gs e l e c t e d w h e n t h b u s r e m a i n s i d l e f o c h o s e n p e r i o d o t i m e .1 4 p r i n t b u f f e r i b u i l t i n t o f r e e u t h n e t w o r k w h e n u s e rs e n d s o u t p u t t t h p r i n t e r . u n i q u e c a p a b i l i t y o t h M i c r o s h a r e6 i i t ' s " g r o u p l o a d " f e a t u r e ( a . k . a . " m e g a l o a d " ) , w h i c h a l l o w sa n o a l o t h c o m p u t e r s i t h n e t w o r k t s i m u l t a n e o u s l yL O A D t h s a m e p r o g r a m f r o m d i s k . S o m e o t h e r f e a t u r e s i n c l u d e :I n d i v i d u a l d i s k e r r o r s t a t u s r e p o r t s f o e a c h u s e r , i n d i v i d u a l l yc o n t r o l l a b l e c h a n n e l s w i t c h i n g d e l a y , b u i l t i n d i a g n o s t i c r o u t i n e s ,a n s t u r d y a l l - s t e e l c o n s t r u c t i o n .

T h p r i c e f o t h e b a s i c u n i t ( c o m p u t e r - c o n n e c t i o n c a b l e s i n c l u d e d )i $ 9 9 5 . 0 0 ( C a n a d i a n F S T ) . A v a i l a b l e f r o m :

C o m s p e c C o m m u n i c a t i o n s I n c .1 5 3 B r i d g e l a n d A v e . , U n i tT o r o n t o , O n t a r i oM 6 A 2 Y 6 4 1 7 8 7 - 0 6 1 7

O p e r a n t I n t e r f a c e

P s y c h r o n i x h a r e l e a s e d t h M o d e l 3 I n t e r f a c e f o P s y c h o l o g i s t sw h w a n t t r e c o r d u t 3 s e p a r a t e s w i t c h c l o s u r e s , a n t u r n o l a m p s a n a f e e d e r i s i n g l e 2 B V D C o p e r a n t c h a m b e r .

T h i s i n t e r f a c e u s e s t h e p a r a l l e l p o r t o t h V I C - 2 0 , C - 6 4 , o P E T /C B c o m p u t e r . B e c a u s e i i p r o g r a m m a b l e e n t i r e l y i B A S I C( m a c h i n e l a n g u a g e p r o g r a m m i n g i n o n e c e s s a r y ) s t u d e n t s c a b q u i c k l y t a u g h t t u s t h i s i n t e r f a c e . D a t a c a b r e c o r d e d i r e a lt i m e u s i n g t h c o m p u t e r ' s i n t e r n a l c l o c k .

T h M o d e l 3 I n t e r f a c e h a b e e n i u s f o o v e r y e a r i r e s e a r c h l a b o r a t o r y w i t h r e m a r k a b l e s u c c e s s . A l c h i p s a r s o c ke t e d f o e a s y r e p l a c e m e n t . R e t a i l p r i c e o t h i n t e r f a c e i $ 1 3 0 . 0 0

P s y c h r o n i xB o 4 2 L o g a n , U 8 4 3 2 1

T h T r a n s a c t o r V o l u m e 5 I s s u e 0

Page 12: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 12/88

E l e c t r o n i c C o m p o n e n t s A n n o u n c e sN e C o m p u t e r P a t c h C o r d ( C P C - 1 0 0 0 )

J u s t d e v e l o p e d a n p a t e n t e d , n e p r o d u c t a l l o w s t h e o w n e r o C o m m o d o r e 6 o V I C - 2 0 p e r s o n a l c o m p u t e r , t u s a o r d i n a r yc a s s e t t e r e c o r d e r w i t h t h e i r c o m p u t e r . T h C o m p u t e r P a t c h C o r d( C P C - 1 0 0 0 ) i c o m p a t i b l e w i t h e v e r y t h i n g f r o m t h E m e r s o n 4 9 4 0G h e t t o B l a s t e r t t h S o n y W a l k m a n 1 1

T h a d v a n t a g e o t h C P C - 1 0 0 0 i t h a t i c o s t s a f r a c t i o n o w h a tC o m m o d o r e D a t a s e t t e w o u l d c o s t . T h a v e r a g e p r i c e o t h C o m o d o r e D a t a s e t t e i $ 7 9 . 9 5 , t h e p r i c e o t h C o m p u t e r P a t c h C o r di o n l y $ 2 9 . 9 5 . F o f u r t h e r i n f o r m a t i o n p l e a s e c o n t a c t :

B r i a n G . W i l c o x , V i c e P r e s i d e n tE l e c t r o n i c C o m p o n e n t sP . O . B o x 1 7 E l m a , N . Y . 1 4 0 5 9

O m n i t r o n i x A n n o u n c e s R S 2 3 2 I n t e r f a c e f o t h V I C - 2 0 , C 6 4 , a n S X 6 4 P o r t a b l e .

T h R S 2 3 2 I n t e r f a c e h a b e e n s p e c i a l l y d e s i g n e d t a l l o w e a s y u s o a n t y p e o R S 2 3 2 e q u i p m e n t , i n c l u d i n g s e r i a l p r i n t e r s a n m o d e m s . T h e D e l u x e R S 2 3 2 I n t e r f a c e p l u g s i n t o t h U S E R I / p o r t o t h c o m p u t e r . I n c l u d e d a s p a r t o t h u n i t i a t h r e e f o o tc a b l e t e r m i n a t i n g i m a l e o f e m a l e D B 2 5 c o n n e c t o r . T h D e l u x eR S 2 3 2 I n t e r f a c e c a a l s o b s u p p l i e d w i t h a P B o a r d m o u n t i n gF e m a l e D B 2 5 , a l l o w i n g i t c o m p l e t e l y s u b s t i t u t e f o t h 1 0 1 1 A T h r e e s w i t c h e s i t h e c a s e c o v e r a l l o w y o t o s e t t h u n i t f o D T E /D C E , i n v e r t p i n s 2 a n 5 a n s e l e c t t h B U S Y l i n e p o l a r i t y .

T h R S 2 3 2 I n t e r f a c e s u p p o r t s v i r t u a l l y a l R S 2 3 2 s i g n a l s i n c l u d i n gR i n g D e t e c t . I c a o p e r a t e a u t 2 4 0 0 b a u d . S u p p l i e d i t h m a n u a l i T y p e - I n B A S I C t e r m i n a l p r o g r a m a n d v e r y c o m p l e t et u t o r i a l o u s i n g t h R S 2 3 2 p o r t .

R S - 2 3 2 1 C h a n n e l A n a l o g I n p u t M o d u l e

C o n n e c t i c u t m i c r o c o m p u t e r a n n o u n c e s n e 1 c h a n n e l a n a l o gi n p u t m o d u l e w h i c h i s e l f c o n t a i n e d R S - 2 3 2 b u s c o m p a t i b l ed e v i c e . T h U S S t e r D 1 6 R w o r k s w i t h a n c o m p u t e r t h a t h a a R S - 2 3 2 i n t e r f a c e ( e i t h e r b u i l t - i n o a d d e d o n ) i n c l u d i n g c o m p u t e r sm a n u f a c t u r e d b A P P L E , I B M , C o m m o d o r e , O s b o r n e , H e w l e t t -P a c k a r d , a n T e k t r o n i x . T h D 1 6 R i t h e l e v e n t h p r o d u c t i t h B U S S t e r s e r i e s o I / m o d u l e s .

T h B U S S t e r D 1 6 R A n a l o g I n p u t M o d u l e a c c e p t s c o m m a n d s f r o ma n h o s t c o m p u t e r t h r o u g h i t R S - 2 3 2 , t r e a d d a t a o r a c t i v a t e t h t i m e r a n b u f f e r . T h d a t a i c o n v e r t e d t b i t s ( 0 . 2 5 % f a n d t h c o n v e r s i o n t i m e i l e s s t h a n 1 0 m i c r o s e c o n d s . T h b u i l t - i n t i m e ro p e r a t e s f r o m . 0 s e c o n d s t 4 h o u r s . T h b u i l t - i n b u f f e r a l l o w sd a t a a c q u i s i t i o n w h i l e t h h o s t c o m p u t e r i b u s y w i t h o t h e r t a s k s .

B U S S t e r m o d u l e e c o n o m i c a l l y i n c r e a s e s c o m p u t e r ' s i n t e r f a ci n c a p a b i l i t y w h i l e r e d u c i n g i t w o r k l o a d .

T h B U S S t e r D 1 6 R A n a l o g I n p u t M o d u l e i e a s i l y p r o g r a m m e dt h r o u g h B A S I C c o m m a n d s f r o m t h c o n t r o l l i n g c o m p u t e r .

T h B U S S t e r D 6 s e l l s f o r $ 4 9 5 . 0 0 i s t a n d a r d v e r s i o n , i n c l u d i n gc a s e a n d p o w e r s u p p l y , a n i a v a i l a b l e f r o m s t o c k .

S h i r l e y F l e t c h e rC o n n e c t i c u t m i c r o c o m p u t e r3 D e M a D r i v eB r o o k f i e l d , C 0 6 8 0 4 2 0 3 7 7 5 4 5 9 5

T h u n i t h a a u n c o n d i t i o n a l y e a r g u a r a n t e e , a n 3 0 d a yr e t u r n i n o s a t i s f i e d . S u g g e s t e d r e t a i l i $ 3 9 . 9 5 . I i a v a i l a b l e f r o my o u r l o c a l d e a l e r s o c a l l O m i n t r o n i x . P l e a s e a d $ 1 . 6 0 s h i p p i n g .

O m n i t r o n i x I n c o r p o r a t e dP B o 4 M e r c e r I s l a n d , W 9 8 0 4 0 2 0 6 2 3 6 2 9 8 3

T h T r a n s a c t o r 1 V o l u m e 5 I s > 0

Page 13: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 13/88

B i t s P i e c e s

B e f o r e w j u m p i n t o t h i s i s s u e ' s b l i t z o r a n d o m t h o u g h t s , i t h e r ed i f f e r e n c e b e t w e e n b i a n a p i e c e ? W e l l , h o a b o u t t h i s : b i t s a r l i t t l e f a c t s , c u r i o s i t i e s , o l i n e p r o g r a m s , P O K E s , o S Y S e s ; i o t h e r w o r d s , q u i c k i e s . P i e c e s a r p r e s e n t a t i o n s o l o n g e r p r o g r a m sa n c o n t a i n p a r a g r a p h o m o r e o t e x t ; s o r t o f l i k e m i n i - a r t i c l e s .A c t u a l l y , p i e c e s a r e o f t e n j u s t a r t i c l e s t h a t w c o u l d n ' t f i n d a h o m ef o a n y w h e r e e l s e i t h m a g a z i n e . S i y o s o m e t i m e s f i n dy o u r s e l f s k i p p i n g o v e r B i t s P i e c e s t g e t t h " m e a t " o t h i s s u e , t u r n b a c k l a t e r f o r d e s s e r t !

T h B i t s B l i t zB u i l t - i n d e b u g g i n g a i

H e r e ' s a i d i o s y n c r a s y t h a t c a b p u t g o o d u s e . O B A S I C 4 . m a c h i n e ( 4 0 / 8 0 3 2 ) , p e r f o r m i n g S Y 5 3 0 2 7 f r o m w i t h i n p r g r a m p r i n t s t h m e s s a g e " i " f o l l o w e d b t h l i n e n u m b e r i w h i c h t h S Y i l o c a t e d . T h p r o g r a m t h e n c o n t i n u e s n o r m a le x e c u t i o n . T h i s i a e a s y w a t t r a c e r e c a l c i t r a n t p r o g r a m : j u s ti n s e r t t h i s S Y a v a r i o u s p o i n t s i t h e c o d e , a n t h m e s s a g e s w i l ls h o w w h a t p a r t s o t h p r o g r a m a r b e i n g e x e c u t e d . I w a y , i t ' sm o r e h a n d y t h a n a r e g u l a r T R A C E f u n c t i o n , s i n c e i o n l y t r a c e s t h p a r t s o t h p r o g r a m y o u ' r e c o n c e r n e d w i t h . c o u p l e o n o t e sa b o u t i t N c a r r i a g e r e t u r n i p r i n t e d a f t e r t h m e s s a g e , a n i y o e x e c u t e i f r o m d i r e c t m o d e , s t r a n g e l i n e n u m b e r i p r i n t e d o u ( w e l l , w h a t d y o e x p e c t ? ) . I f i t w a s n ' t s u c h w e l l - k e p t s e c r e t , i w o u l d l o o k a t h o u g h t h s u b r o u t i n e w a p u r p o s e l y d e s i g n e d a d e b u g g i n g a i d .

E a s y D i s k D i r e c t o r y P a t t e r n m a t c h i n g

I y o u w a n t t l o a d a s e l e c t i v e d i r e c t o r y f r o m 1 5 4 1 s i n g l e d i s kd r i v e , o f r o m d r i v e o a d u a l u n i t , y o n e e d n ' t u s t h c o m p l e t es y n t a x :

T h e c o m m a n d ,L O A D " $ 0 : p a t t e r n " , 8

L O A D " $ p a t t e r n " , 8

. w i l l d t h s a m e t h i n g . F o e x a m p l e , t s e d i r e c t o r y o a l p r o g r a m s o d r i v e s t a r t i n g w i t h P " j u s t e n t e r :

L O A D " $ P * " , 8

T h i s l e a d s t a n e a s y w a t l o a d j u s t t h d i s k h e a d e r a n n u m b e ro b l o c k s f r e e :

P " < C < C

P o i s o n L i n e N u m b e r

S o m e t i m e s c o m p u t e r c a g e a n n o y e d f o t h e s m a l l e s t r e a s o n s .E n t e r t h e f o l l o w i n g n u m b e r o y o u r c o m p u t e r ( i w o r k s w i t h4 0 3 2 / 8 0 3 2 a n d 6 4 ) :

3 5 0 8 0 0

T h e r e ' s a c t u a l l y w h o l e r a n g e o n u m b e r s i t h s a m e n e i g h b o rh o o d t h a t p r o d u c e t h s a m e e f f e c t . T r e n t e r i n g i m o r e t h a n o n c e .W h d o e s i h a p p e n ? W h k n o w s , m a y b e i t ' s j u s t a n u n l u c k yn u m b e r .

C l o s i n g " F o r g o t t e n " F i l e s

E d i t i n g w i t h C o m m o d o r e m a c h i n e s i w o n d e r f u l c o m p a r e d t o t h e r s , b u i c a n b e a n n o y i n g w h e n a l v a r i a b l e s a r e l o s t w h e n e v e r

l i n e n u m b e r i e n t e r e d , w i t h o w i t h o u t t e x t . B e s i d e s c l e a r i n gv a r i a b l e s , t h o u g h , t h m a c h i n e f o r g e t s a b o u t a l o p e n f i l e s . S u p o s e y o O P E N a s e q u e n t i a l f i l e t d i s k a n w r i t e t i t Y o M U S Tc l o s e t h f i l e a f t e r w a r d s , b u i y o d i a n l i n e e d i t i n g , d e l i b e r a t e l yo n o t , t h s y s t e m w i l l t h i n k t h e r e a r e n o p e n f i l e s , a n w o n ' t l e y o c l o s e i t N o w , y o u k n o w p e r f e c t l y w e l l t h a t t h f i l e i s i n d e e do p e n , s i n c e t h e l i g h t o t h e d i s k d r i v e i o n

I s u c h s i t u a t i o n , h e r e a r t w w a y s t c l o s e t h f i l e :1 T h d i s k d r i v e w i l l a u t o m a t i c a l l y c l o s e a l f i l e s w h e n t h c o m m a n d c h a n n e l i c l o s e d . T u s t h i s f e a t u r e , j u s t e n t e r :

O P E N 1 , 8 , 1 5 : C L O S E 1 .

A L o p e n f i l e s w i l l t h e n b c l o s e d , c o u r t e s y o t h e d i s k d r i v e .

2 Y o c a c h a n g e t h n u m b e r o f i l e s o p e n i t h o p e r a t i n gs y s t e m . T h i s m e t h o d a l l o w s y o t c l o s e t h e f i r s t f i l e o p e n e d , o r t h ef i r s t f i l e s o p e n e d , r a t h e r t h a n a l o p e n f i l e s l i k e m e t h o d 1 T h c h a n g e i d o n e w i t h s i n g l e P O K E :

P O K E 1 5 2 , 1 o V I C / 6 4o P O K E 1 7 4 , 1 o P E

Y o c a t h e n C L O S E t h f i l e a s u s u a l . I y o w i s h t r e - a c t i v a t em o r e t h a n o n o l f i l e , c h a n g e t h v a l u e o t h P O K E a c c o r d i n g l y .

S A V E - i n g R a n g e o M e m o r y F r o m B A S I C

O 4 0 3 2 o 8 0 3 2 , y o c a n a l w a y s s a v e r a n g e o m e m o r y f r o mt h m o n i t o r , f o e x a m p l e :

T h T r a n s a c t o r 1 V o l u m e 5 I s s u e 0

Page 14: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 14/88

" O : f i l e n a m e " , 0 8 , 8 0 0 0 , 8 4 0 0

. w o u l d s a v e s c r e e n m e m o r y o u t d i s k . W i t h t h C 6 4 , s u c hf e a t u r e w o u l d b e v e n m o r e d e s i r a b l e , s t h a t t h p i c t u r e c u r r e n t l yi t h h i g h r e s o l u t i o n s c r e e n c o u l d b e S A V E d . T h 6 d o e s n ' t h a v ea b u i l t - i n m o n i t o r l i k e t h 4 . P E T s d o , b u t y o c a S A V E r a n g eo m e m o r y b e n t e r i n g s i n g l e l i n e f r o m d i r e c t m o d e ! H e r e i i s

s y s 5 7 8 1 2 " f i l e n a m e ' , 8 : p o k e 1 9 3 , s l o : p o k e 1 9 4 , s h i: p o k e 1 7 4 , e l o : p o k e 1 7 5 , e h i : s y s 6 2 9 5 4

T h v a r i a b l e s S L a n d S H I a r e t h e l o a n h i g h o r d e r o t h s t a r ta d d r e s s , r e s p e c t i v e l y , a n v a r i a b l e s E L a n E H a r e t h e l o w a n dh i g h e n a d d r e s s . ( S L O s t a r t A N 2 5 5 , S H s t a r t / 2 5 6 ,E L e n A N 2 5 5 , E H e n d / 2 5 6 )

F o r e x a m p l e , t s a v e t h h i g h r e s o l u t i o n s c r e e n f r o m 8 1 9 2 ( $ 2 0 0 0 )t 1 6 1 9 2 ( $ 3 F 4 0 ) u s i n g t h e f i l e n a m e " s c r e e n " o d r i v e z e r o , t h l i n e w o u l d l o o k l i k e t h i s :

s y s 5 7 8 1 2 " 0 : s c r e e n " , 8 : p o k e 1 9 3 , 0 : p o k e 1 9 4 , 3 2: p o k e 1 7 4 , 6 4 : p o k e 1 7 5 , 6 3 : s y s 6 2 9 5 4

T h f i l e c a n t h e n b e L O A D e d a s u s u a l , w i t h :

L O A D " f i l e n a m e " , 8 , 1 .

C a s s e t t e c a b e u s e d i n s t e a d o d i s k i y o c h a n g e t h " , 8 " t " , 1 "w h e n s a v i n g a n l o a d i n g . R e m e m b e r , i y o u ' r e l o a d i n g t h f i l eb a c k i f r o m w i t h i n p r o g r a m , y o u h a v e t m a k e s u r e i o n l y g e t sl o a d e d o t h f i r s t R U N . F o e x a m p l e , t h f i r s t l i n e o t h p r o g r a mc o u l d b e

1 i 0 t h e n : l o a d " f i l e n a m e " , 8 , 1

W A I T S E C O N D !

T h i s n e x t B I i f r o m J e f f G o e b e l , w h w r i t e s :

J e f f G o e b e l

" I y o a r e v e r u s i n g c a s s e t t e f i l e s o 6 4 i i g o o d i d e a t f i r s tm a k e s u r e t h P L A Y b u t t o n h a b e e n s h u t o f f . a l w a y s i n c l u d el i n e :

P R E S S S T O P O C A S S E T T E P L E A S E

. . a n d a W A I T 1 , 1 6 a t h b e g i n n i n g o a n o m c a s s e t t e l o a d e dp r o g r a m s . T h i s w i l l S T O P t h c o m p u t e r u n t i l t h S T O P b u t t o n o t h e t a p e p l a y e r i p r e s s e d . T h a t w a y , w h e n l a t e r t r y t o r e a d f r o mf i l e , t h P R E S S P L A Y p r o m p t w i l l a g a i n b d i s p l a y e d , a n t h e u s e rh a t h o p t i o n t c h a n g e t a p e s o r w h a t e v e r , b e f o r e p r e s s i n g P L A Y .A c t u a l l y , c a s p i f f u t h s t a n d a r d P R E S S P L A Y p r o m p t t b a l m o s t a n y t h i n g w a n t b u s i n g m o w r o u t i n e . I i n c l u d eP R I N T s t a t e m e n t l i k e ;

P R E S S P L A Y O T A P E C A S S E T T E U N I T "

. . f o l l o w e d b W A I T 1 , 1 6 , 1 6 , t h c o m p u t e r w i l l s t o p a n w a i t t i l lt h e p l a y i p r e s s e d . t h e n h a v e t i m e t

P R I N T " T H A N K Y O U "o " S E A R C H I N G F O R D A T A "

. . b e f o r e o p e n t h f i l e . S i n c e t h e p l a y k e i a l r e a d y d e p r e s s e d ,

t h c o m p u t e r ' s o w p r o m p t w i l l n o t a p p e a r , a n t h e d a t a w i l l l o a da n o r m a l .

" A c t u a l l y , t h W A I T s a r e u n i v e r s a l ; W A I T 1 , 1 6 w i l l s t o p u n t i l A L k e y s a r u o t h e t a p e u n i t a n W A I T 1 , 1 6 , 1 6 w i l l s t o p a n w a i tu n t i l A N k e i p r e s s e d o t h u n i t . I d o e s n ' t h a v e t b t h P L A Yk e s p e c i f i c a l l y . "

C h e c k i n g f o S H I F T , C T R L , a n d C o m m o d o r e k e y s

P E E K ( 6 5 3 ) w i l l y i e l d t h s t a t e o t h e s e t h r e e k e y s ; b i f o S H I F T ,f o t h " C o m m o d o r e K e y " , f o C T R L . S t u d y t h e f o l l o w i n g e x a mp l e .

1 r e m * c o n t r o l k e d e m o2 p r i n t c h r $ ( 8 ) : r e m * l o c k c a s e3 0 4 f o t s t e p5 c p e e k ( 6 5 3 )6 i c t h e n p r i n t " n o n e - " 7 i c a n t h e n p r i n t t a b ( 1 ) " S H I F T " ;8 i c a n t h e n p r i n t t a b ( 8 ) " C o m m o d o r e " ;9 i f c a n t h e n p r i n t t a b ( 2 0 ) " C T R L " ;1 0 p r i n t1 1 n e x t

A y o c a s e e , t h s t a t e o f a n o a l k e y s m a b e x a m i n e d w i t hs i n g l e P O K E , a n a A N t s e w h i c h k e y ( s ) , i a n y , a r e b e i n gh e l d d o w n . ( H o l d i n g d o w n t h C T R L k e a l s o s l o w s t h s p e e d o s c r o l l i n g ) .

C h a n g i n g S c r e e n C h a r a c t e r C o l o u r s

q u i c k w a t c h a n g e t h c o l o u r o A L c h a r a c t e r s o t h C 6 s c r e e n :

1 1 5 3 2 8 1 : r e m * i c o l o u r , i b o r d e r c o l o r r e 2 p e e k ( b ) : p o k e b , c : p o k e 6 4 8 , 1 6 0

: p r i n t c h r $ ( 1 4 7 ) : p o k e 6 4 8 , 4 : p o k e b , s

T h a b o v e w o r k s o 6 4 s w i t h R O v e r s i o n V 2 , w h i c h s e t s c o l o u rm e m o r y t b a c k g r o u n d c o l o u r w h e n t h s c r e e n i c l e a r e d . I y o h a v e o t h e r R O v e r s i o n s ( t h a t s e c o l o u r m e m o r y t c h a r a c t e rc o l o u r ) , u s t h i s l i n e 2 0

2 p o k e 6 4 6 , c : p o k e 6 4 8 , 1 6 0 : p r i n t c h r $ ( 1 4 7 ) : p o k e 6 4 8 , 4

T h f i r s t v e r s i o n w o n ' t c h a n g e t h e c u r r e n t c h a r a c t e r c o l o u r , i t ' l lj u s t c h a n g e t h e c o l o u r o a l c h a r a c t e r s o t h e s c r e e n .

I w o r k s b t e l l i n g t h o p e r a t i n g s y s t e m t h a t t h s c r e e n i w a u i R O M , s t h a t c l e a r i n g t h e s c r e e n s e r v e s o n l y t o s e t c o l o u r m e m o r y .T h s c r e e n p a g e p o i n t e r i t h e n s e u t i t n o r m a l d e f a u l t v a l u e ,( s c r e e n a $ 0 4 0 0 ) .

P i e c e sD e a t h b y G a r b a g e

D e l a y s c a u s e d b g a r b a g e c o l l e c t i o n ( d i s c a r d i n g o u n w a n t e ds t r i n g s b t h s y s t e m ) a r o f t e n m i n o r a n n o y a n c e , b u s o m e t i m e su n c o l l e c t e d g a r b a g e c a n b t h c a u s e o u n e x p e c t e d c r a s h e s !S u p p o s e w w a n t e d t w r i t e a p r o g r a m t s t o r e d a t a f r o m

T h T r a n s a c t o r 1 V o l u m e 5 I s s u e 0

Page 15: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 15/88

s e q u e n t i a l f i l e i n t o m e m o r y , e i t h e r t b e x a m i n e d t h e r e b p r o g r a m , o t b w r i t t e n t n e f i l e . T h f o l l o w i n g h a r m l e s s -l o o k i n g p r o g r a m s h o u l d d t h t r i c k , r i g h t ?

1 r e m * r e a d b y t e s i n t o m e m o r y f r o m s e f i l e2 0 o p e n 8 , 8 , 1 , " O : l o t s o f d a t a . s . r "3 b 4 0 9 6 : r e m * s t a r t o f m e m o r y f o s t o r a g e4 0 r e m * c o u n t e r5 r e m — l o o p6 g e t # 8 , a $ : p o k e b c , a s c ( a $ c h r $ ( O ) )7 0 c + 8 i s a n b m < 2 4 5 7 6 g o t o 5 09 r e m — e n d l o o p1 0 c l o s e1 1 e n

B y t e s a r r e a d f r o m t h e s e q u e n t i a l f i l e a n P O K E d i n t o s u c c e s s i v em e m o r y l o c a t i o n s . T h p r o g r a m e n d s w h e n e n d - o f - f i l e o c c u r s , o rm e m o r y l o c a t i o n 2 4 5 7 6 ( $ 6 0 0 0 i h e x a d e c i m a l ) i r e a c h e d . W h e nr u o 4 0 3 2 o 8 0 3 2 , t h a b o v e p r o g r a m s e e m s t w o r k f i n eu n l e s s t h e f i l e i s m o r e t h a n a b o u t 5 0 0 0 b y t e s l o n g . O l o n g f i l e ,t h m a c h i n e w i l l s u d d e n l y b r e a k i n t o t h m a c h i n e l a n g u a g em o n i t o r , o r s i m p l y h a l t . I n s p e c t i o n o t h e d a t a a f t e r t h c r a s hr e v e a l s t h a t i h a b e e n t o t a l l y c o r r u p t e d . W h a t h a p p e n e d ?

I m a b e o b v i o u s t s o m e o y o w h f u l l y u n d e r s t a n d t h n a t u r eo f s t r i n g s i C o m m o d o r e B A S I C , b u i m a b a s u r p r i s e t t h u n i n i t i a t e d . I o c c u r s b e c a u s e t h d a t a b e i n g P O K E d i n t o m e m o r ys t e p s o s t r i n g s t o r a g e s p a c e . O n w o u l d t h i n k t h a t t h 8 o m e m o r y b e t w e e n $ 6 0 0 0 a n d $ 8 0 0 0 w o u l d b m o r e t h a n e n o u g h t s t o r e t h e s t r i n g s ; t h e r e ' s j u s t A $ r i g h t ? W e l l , t h e s t r i n g s t o r a g es p a c e g r o w s e a c h t i m e n e A i r e a d , b e c a u s e n e s t r i n g i c r e a t e d i m e m o r y . E a c h t i m e n e s t r i n g i c r e a t e d , t h e b o t t o m -o f - s t r i n g s p o i n t e r d e c r e a s e s ( t h i s p o i n t e r i a 4 8 - 4 9 i B A S I C 4 ,5 1 - 5 2 i V I C / 6 4 ) . T h g a r b a g e l e f t o v e r f r o m p r e v i o u s s t r i n g sw o n ' t b c o l l e c t e d u n t i l t h i s p o i n t e r d e c r e a s e s u n t i l i e q u a l s t h t o o a r r a y s p o i n t e r i o t h e r w o r d s , w h e n t h e r e ' s n m o r e f r e em e m o r y . U n f o r t u n a t e l y , w w a n t t u s t h m e m o r y b e t w e e n t h t o o B A S I C a n v a r i a b l e s , a n t h b o t t o m o f s t r i n g s .

W h a t w r e a l l y w a n t i t h c a s e o t h a b o v e p r o g r a m i g a r b a g ec o l l e c t i o n a f t e r e v e r y n e b y t e i r e a d i n T h a t w i l l k e e p R A f r e ea n s a f e , s i n c e t h e s t r i n g s w i l l n e v e r g r o w m o r e t h a n f e b y t e s( o n e b y t e w i l l b r e q u i r e d t s t o r e A $ a n a n o t h e r t s t o r e t h r e s u l t o f A $ C H R $ ( 0 ) ) . T h b e s t w a t f o r c e a g a r b a g e c o l l e c t i b i n v o k i n g t h F R f u n c t i o n . I t h a b o v e p r o g r a m , w c o u l di n s e r t t h s t a t e m e n t :

7 5 F R E ( 0 )

T h i s d o e s n ' t s l o w d o w n t h p r o g r a m n o t i c e a b l y , s i n c e t h e r e a r o n l y t w b y t e s o g a r b a g e t d i s c a r d e a c h t i m e . I f a c t , i a n p r o g r a m w h i c h r e a d s i m a n y b y t e s o d a t a f r o m d i s k , o r e d e f i n e ss t r i n g v a r i a b l e s o f t e n w i t h G E T s o s t r i n g e x p r e s s i o n s , i t ' s g o o di d e a t u s t h F R f u n c t i o n i e v e r y i t e r a t i o n o f t h l o o p . I t h s t r i n g s a r a l l o w e d t p i l e u u n t i l g a r b a g e c o l l e c t i a u t o m a t ic a l l y i n v o k e d , t h e r e c o u l d b e l o n g w a i t i s t o r e , e s p e c i a l l y i B A S I C 2 . m a c h i n e s . p r o g r a m u s e r m a t h i n k t h m a c h i n e h a c r a s h e d d u r i n g l o n g g a r b a g e c o l l e c t , a n b e c o m e q u i t e h o s t i l e a sh t u r n s o f t h p o w e r a f t e r w a i t i n g t e m i n u t e s .

S b c a r e f u l w h e n P O K E i n g i n t o " f r e e " m e m o r y , a n u s t h F R f u n c t i o n l i b e r a l l y i s t r i n g - i n t e n s i v e p r o g r a m s . A m o r e d r a s t i c

m e a s u r e , C L w i l l a l s o d t h t r i c k , b u o c o u r s e i m u s t b u s e dw i t h c a r e w i t h i n p r o g r a m s . T h e r e ' s a n o t h e r l e s s o n h e r e : e v e n i p r o g r a m w o r k s f i n e w h e n t e s t e d w i t h r e l a t i v e l y s m a l l a m o u n t s o d a t a , i m a d i w h e n w o r k e d h a r d e r o f o l o n g e r p e r i o d s o t i m e .B c o i n c i d e n c e , i I ' t e s t i n g a c o m m e r c i a l p r o g r a m a n d i c r a s h e so n m e , t h f i r s t w o r d t h a t u s u a l l y s p r i n g s t m i n d , i " G A R B A G E " .

D r o w n i n g i G a r b a g e ! E l i z a b e t h D e a l

L i w r i t e s , " W a l k n o w a b o u t t h e e l e g a n t s c r e e n d a z z l e r s . T h o t h e r e n o t h c o m p u t i n g s t i c k i s : "

1 0 r e d r o w n i n g i c 6 g a r b a g e !1 1 r e b e l i z a b e t h d e a l1 2 0 :1 3 r e m * s e t o o b a s i c t $ 4 0 0 01 4 p o k e 5 5 , 0 : p o k e 5 6 , 6 4 : c l r : v i 5 3 2 4 81 5 0 :1 6 r e m * h i r e s s c r e e n a $ 2 0 0 01 7 p o k e v 1 7 , p e e k ( v i + 1 7 ) o r 3 21 8 p o k e v 2 2 , p e e k ( v i 2 2 ) o r 1 61 9 p o k e v 2 4 , p e e k ( v i 2 4 ) o r 82 0 0 :2 1 r e m * d e f i n e s t r i n g 2 0 t i m e s2 2 t 5 6 3 2 4 : f o t 2 0 2 3 v c h r $ ( p e e k ( t a ) ) v $ n e x t2 4 g e i $ : i f i " t h e n c l r : g o t o 2 2 02 5 0 :2 6 r e m * e x i t a n r e s t o r e s c r e e n2 7 v 5 3 2 4 82 8 p o k e v 1 7 , p e e k ( v i + 1 7 ) a n d 2 2 32 9 0 p o k e v 2 2 , p e e k ( v i 2 2 ) a n d 2 3 93 0 p o k e v 2 4 , p e e k ( v i 2 4 ) a n d 2 4 7

E d i t o r ' s n o t e :T h w i l d p a t t e r n s d i s p l a y e d o t h s c r e e n a r e a s r e s u l t o " g a r b a g e " - t h s t r i n g V i r e p e a t e d l y r e d e f i n e d , f i l l i n g m e m o r y ,w h i c h h a p p e n s t b v i d e o R A M . F a o u t . T . E d .

S i n g l e D i s k C o p y P r o g r a m R i c k H i e s , M i l t o n O n t a r i o

T h e p r o g r a m t h a t f o l l o w s a l l o w s y o t m a k e c o p i e s o p r o g r a m s ,o S E f i l e s o 2 0 3 1 / 1 5 4 0 / 1 5 4 1 d i s k d r i v e s . F i l e s c a n b e o a n k i n d : B A S I C , m a c h i n e l a n g u a g e , o s e q u e n t i a l . T h o n l y l i m i t i t h e l e n g t h o t h f i l e t b c o p i e d , w h i c h d e p e n d s o h o w m u c hm e m o r y y o u r m a c h i n e h a s . A i s t a n d s , i w i l l w o r k o u p g r a d ea n 4 . B A S I C ; i y o h a v e V I C 2 0 o C o m m o d o r e 6 4 c h a n g et h e s e l i n e s :

1 1 p o k e 8 2 8 , p e e k ( 5 5 ) : p o k e 8 2 9 , p e e k ( 5 6 ) : d 1 2 p o k e 5 5 , p e e k ( 4 5 ) : p o k e 5 6 , p e e k ( 4 6 ) + 1 : c l 1 3 0 1 = p e e k ( 5 5 ) + 2 5 6 p e e k ( 4 6 ) :3 0 c l o s e i : p o k e 5 5 , p e e k ( 8 2 8 ) : p o k e 5 6 , p e e k ( 8 2 9 ) : c l r

T h p r o g r a m f o l l o w s :

1 0 0 r e m * s i n g l e d i s k c o p y : b r i c k i l l e s1 1 p o k e 8 2 8 , p e e k ( 5 2 ) : p o k e 8 2 9 , p e e k ( 5 3 )1 2 p o k e 5 2 , p e e k ( 4 2 ) : p o k e 5 3 , p e e k ( 4 3 ) + 1 c l 1 3 0 1 p e e k ( 5 2 ) 2 5 6 * p e e k ( 5 3 ) :1 4 i n p u t " f i l e n a m e " ; a $

1

Page 16: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 16/88

1 5 i n p u t " P r o S e ( P / S ) " ; t 1 6 0 o p e n 1 , 8 , 8 , a $ + " , + t $ : i f d s g o t o 3 0 01 7 p r i n t " o k . . 1 8 r e m * r e a d t h f i l e i n 1 9 g e t # 1 , b $ : p o k e s , a s c ( b $ c h r $ ( . ) ) : s

: i s g o t o 1 9 02 0 i d g o t o 3 0 0 : r e m * d i s k e r r o r ( b a s i c 4 2 1 c l o s e i : p r i n t " 0 | i n s e r t c o p y d i s k i n t o d r i v e # 0 2 2 p r i n t " t h e n p r e s s < s p a c e > "2 3 g e b $ i b $ " g o t o 2 3 2 4 g e b $ i b $ < > " g o t o 2 4 2 5 0 o p e n 1 , 8 , 8 , a $ " , + 1 , w " : i d g o t o 3 0 2 6 p r i n t " o k .2 7 0 r e m * w r i t e t h f i l e o u 2 8 f o t t o 8 - 1 : p r i n t # 1 , c h r $ ( p e e k ( i ) ) ; : n e x t2 9 i f d t h e n c l o s e i : p r i n t " f l d o n e ! "3 0 p r i n t d s $ : c l o s e 1 p o k e 5 2 , p e e k ( 8 2 8 ) : p o k e 5 3 , p e e k ( 8 2 9 )

E d i t o r ' s n o t e :N o t i c e t h ' I F 5 7 " = . ' a n ' C H R $ ( . ) ' i n l i n e 1 9 0 ? T h i s i p e r f e c t l ya c c e p t a b l e f o t h v a l u e z e r o . F a s t e r t o o .

A l s o n o t e t h w a t h a t R i c k p r o t e c t e d m e m o r y b e f o r e s t o r i n g t h eb y t e s f r o m t h e d i s k f i l e . H f i r s t s a v e s t h e c u r r e n t t o p o f m e m o r y ,t h e n s e t s i t 2 5 b y t e s a b o v e t h t o o t h B A S I C p r o g r a m ; t h a t ' sp l e n t y o f s p a c e f o v a r i a b l e s i t h i s c a s e . A f t e r t h e p r o g r a m f i n i s h e s ,i r e s t o r e s t h e t o p o m e m o r y p o i n t e r t o t h e i r o r i g i n a l s t a t e . T h i s i g o o d t e c h n i q u e , a n i a v o i d s t h p o s s i b i l i t y o " d e a t h b g a r b a g e " ,a s e x p l a i n e d i t h p i e c e o t h s a m e n a m e . T h e o n l y t h i n g t w a t c h o u f o t h o u g h , i i y o u w a n t t u s t h a b o v e r o u t i n e a s u b r o u t i n e i l a r g e r p r o g r a m : T h v a r i a b l e s a n a r r a y s i t h a tc a s e m a n e e d m o r e t h a n t h 2 5 b y t e s p r o v i d e d a b o v e t h p r o g r a m . T a l l o c a t e m o r e v a r i a b l e s p a c e , j u s t c h a n g e t h " 1 " i nl i n e 1 2 t g i v e m o r e t h a n o n 2 5 b y t e b l o c k . - T E

B A S I C 4 . 0 S t r i n g B u

H e r e ' s a b u g , r e p o r t e d b C o m m o d o r e :

" T h e b u g i f a i l u r e t o d e t e c t ' O u t o M e m o r y ' e r r o r . T h i s c a c a u s e c o r r u p t i o n o s t r i n g d a t a o r p r o g r a m s i s p a c e i r u n n i n gs h o r t .

" T h e b u g o n l y o c c u r s i B A S 1 C 4 a n w h e n t h e r e a r e l e s s t h a n 7 6 b y t e s ( o t i m e s t h e l o n g e s t s t r i n g ) f r e e a f t e r a l v a r i a b l e s a n a r r a y s h a v e b e e n a s s i g n e d t p r o g r a m .

" A e x a m p l e o t h b u g o n 3 2 P E T :

1 0 D I M A ( 6 3 3 0 )2 B U G S B U G S + W " . " : P R I N T B U G S : G O T O 2 0

" T h e a b o v e p r o g r a m w i l l c o n c a t e n a t e s t r i n g o a l t e r n a t i n g c h a ra c t e r s ' W . W . W . W . W . T h e ' O u t o m e m o r y ' t e r m i n a t i n g i c o r r e c tb u t h s t r i n g i c o r r u p t e d a f t e r o n l y f e p a s s e s .

S o l u t i o n .

" T h e e a s i e s t s o l u t i o n i t t r a p t h ' O u t o m e m o r y 1 e r r o r f r o mB A S I C .

I F R E ( 0 ) < 7 6 8 T H E N P R I N T " O U O M E M O R Y E R R O R " : S T O P .

A n o t h e r s o l u t i o n i p r e v e n t a t i v e m e d i c i n e : D o n ' t c o n c a t e n a t em o r e t h a n t w s t r i n g s a t h s a m e t i m e . D o i n g t h c o n c a t e n a t i o ni t w s t e p s , i e

B U G S B U G S W " B U G S B U G S " .

. w i l l c i r c u m v e n t t h p r o b l e m .

I n t e r c e p t i n g C 6 S y s t e m E r r o r M e s s a g e s - E l i z a b e t h D e a l

B c h a n g i n g t h e " E r r o r m e s s a g e l i n k " a $ 0 3 0 0 - $ 0 3 0 1 t p o i n t t y o u r o w r o u t i n e , y o c a c h a n g e t h b e h a v i o u r o t h o p e r a t i n gs y s t e m w h e n i p r i n t s m e s s a g e s , i n c l u d i n g " R E A D Y . " . Y o u r c o d es h o u l d j u m p t t h n o r m a l e r r o r h a n d l i n g r o u t i n e a f t e r i t ' s f i n i s h e d( n o r m a l l y $ E 3 8 B ) . T h t y p e o e r r o r i i n d i c a t e d b t h r e g i s t e r ;t h v a l u e $ 8 ( 1 2 8 d e c i m a l ) i n d i c a t e s n e r r o r , a n c a u s e s" R E A D Y . " t b p r i n t e d .

W i t h t h a t b r i e f e x p l a n a t i o n , I ' l l p r e s e n t a f e u s e f u l a p p l i c a t i o n st h a t w e r e s e n t i b E l i z a b e t h D e a l f r o m M a l v e r n , P A

( 1 I y o u ' r e t i r e d o f s e e i n g 7 S Y N T A X E R R O R y o c a g e r i o t h i n s u l t s : u s i n g S U P E R M O N ( o a s i m i l a r m a c h i n e l a n g u a g e m o n it o r ) , c h a n g e t h e v e c t o r a $ 0 3 0 0 - 0 3 0 1 t p o i n t t y o u r c o d e :

Y O U R C O D E L D # $ 8 0 ; c o d e f o n e r r o rJ M ( S A V E D V E C ) ; b a c k t o p e r a t i n g s y s t e m

S A V E D V E C . ; h e r e g o e s w h a t e v e r w a p r e v io u s l y a $ 0 3 0 0 / 0 3 0 1 ( n o r m a l l y$ 8 b , $ e 3 )

T h i s w i l l s u p p r e s s a l e r r o r m e s s a g e s , b u s t i l l p r i n t R E A D Y .

( 2 s l i g h t l y m o r e u s e f u l t h i n g m i g h t b t p r i n t a l m e s s a g e s a t h t o o t h s c r e e n ( s e c o n d l i n e , a c t u a l l y ) t p r e v e n t s c r o l l i n g :

Y O U R C O D E T X B M O U L D A # $ 1 3J S $ F F D 2

; h o l d s e r r o r; n o e r r o r; a s c i i c o d e f o h o m e '; p r i n t i

O U J M ( S A V E D V E C ) r e m a i n d e r o e r r o r h a n d l i n gS A V E D V E C . . . a s a b o v e

( 3 S e l e c t i v e h a n d l i n g o e r r o r s c a n b e u s e f u l . I g r a p h i c s i t u a t i o n si i p a r t i c u l a r l y a n n o y i n g t g e 7 F I L E N O T F O U N D E R R O R ( * 4 )a w e l l a f l a s h i n g d i s k l i g h t . T h l i g h t i e n o u g h , l e t ' s g e r i d o ft h e r r o r m e s s a g e :

Y O U R C O D E C P * ; c o d e f o ? f i l e . . e r r o rB N O U ; c o n t i n u e i o t h e r e r r o rL D # $ 8 0 ; f a k e n e r r o r

O U J M ( S A V E D V E C )S A V E D V E C . . . a s a b o v e

( 4 y o u c a n s u p p r e s s p r i n t i n g " R E A D Y . " t a v o i d m e s s i n g u t h s c r e e n . W w o n ' t n e e d t s a v e t h e x i s t i n g v e c t o r h e r e .

Y O U R C O D E T X

O U

B M O U ; n e r r o rJ M $ A 4 3 A ; n o r m a l e r r o r w i t h " R E A D Y . 1J M $ A 4 7 B ; s k i p p r i n t i n g R E A D Y . "

T h e T r o n s o c t o r

Page 17: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 17/88

c o m b i n a t i o n o p o i n t s 3 a n c o u l d b e u s e f u l , a n t h l a t t e rp o i n t c o u l d b e m o d i f i e d s t h a t " R E A D Y . " i o n l y s u p p r e s s e d i c e r t a i n c i r c u m s t a n c e s .

T h e r e i o n d r a w b a c k t s u p p r e s s i n g " R E A D Y . " : a n y a c t i o n t h a td o e s n ' t s e n d f i n a l l i n e f e e d , s u c h a L I S T , w i l l f i n i s h w i t h t h c u r s o r o n l i n e t o o h i g h . S m a l l p r i c e t p a y !

( 5 T h i s i j u s t s c r a t c h o t h s u r f a c e . T h C 6 i p r o g r a m m e r ' sd e l i g h t , b u i c a b n i g h t m a r e i t h h o u s e k e e p i n g i s n ' t g o o d .I n t e r c e p t i n g t h e e r r o r r o u t i n e t c l e a n u p h o u s e ( s w i t c h o u t o h i g h - r e s o l u t i o n m o d e , b r i n g b a c k B A S I C , r e s t o r e n o r m a l p o i n t e r s ,k i l l t h s p r i t e s a n s o o n ) p e r m i t s n i g h t m a r e - a v o i d a n c e . O t h e ru s e s a r p o s s i b l e , t h o u g h h a v e n ' t t r i e d t h e m f o i n s t a n c e , h o w o u l d y o u l i k e t o P O K E ( a d d r e s s ) , - 4 0 I t ' s p a i n t f i g u r e o u t t h et w o ' s c o m p l e m e n t v a l u e o - 4 t f e e d t s o m e m a c h i n e l a n g u a g ep r o g r a m ; u s i n g t h e e r r o r v e c t o r m i g h t h e l p i t h a t o n e .

N o t e t o L i z : Y o u r h u n c h w a r i g h t w d l i k e t h i s s o r t o t h i n g .

C 6 R E S T O R E k e c h e c k i n gI l a s t i s s u e ' s B i t s P i e c e s , t h e r e w a l i t t l e i n t e r r u p t - d r i v e nm a c h i n e l a n g u a g e p r o g r a m w h i c h p e r f o r m e d s u b r o u t i n e w h e ne v e r g i v e n k e w a p r e s s e d . W e l l , i y o w a n t t u s t h R E S T O R E k e o t h 6 4 , t h e r e ' s a e a s i e r w a y , a n i t ' s b e t t e r : y o d o n ' t h a v e t c h a n g e t h I R v e c t o r , s i w i l l w o r k e v e n w i t h I R Q -d r i v e n p r o g r a m s .

T h R E S T O R E k e i u n l i k e a n o t h e r k e o t h k e y b o a r d . T h e r ei n m e m o r y l o c a t i o n w h i c h c a b r e a d t i n d i c a t e w h e t h e r o n o R E S T O R E i d e p r e s s e d . R a t h e r , t h e R E S T O R E k e i c o n e c t e d d i r e c t l y t h a r d w a r e c i r c u i t r y w h i c h g e n e r a t e s a N M w h e n e v e r t h k e i s t r u c k s h a r p l y ( s l o w , g e n t l e p u s h w o n ' t d t h t r i c k ) .

A N M I , o N o n - M a s k a b l e I n t e r r u p t , i l o l i k e a I R ( I n t e r r u p tR e Q u e s t ) , e x c e p t t h a t i c a n ' t b d i s a b l e d b s o f t w a r e . W h e n a N M o c c u r s , t h e 6 j u m p s t t h l o c a t i o n p o i n t e d t b t h v e c t o r a $ 0 3 1 8 a n d $ 0 3 1 9 ( 7 9 2 a n 7 9 d e c i m a l ) t h i s v e c t o r n o r m a l l yp o i n t s t $ F E 4 7 . O t h 6 4 N M I s a r u s e d f o t w p u r p o s e s : T h R E S T O R E k e ( t w a r m - s t a r t i t h R U N S T O P k e i a l s o h e l dd o w n ) , a n f o t h R S - 2 3 2 s o f t w a r e ( a N M i g e n e r a t e d w h e nc h a r a c t e r i r e c e i v e d o t h R S - 2 3 2 p o r t ) . T h R S - 2 3 2 r o u t i n e sd o n ' t a f f e c t d e t e c t i o n o t h R E S T O R E k e y , t h o u g h . B c h a n g i n gt h e v e c t o r a $ 0 3 1 8 / 9 , w c a p o i n t t o u o w r o u t i n e . I t h i sr o u t i n e t r a n s f e r s c o n t r o l t t h e u s u a l N M r o u t i n e a $ F E 4 7 a f t e r i t ' sf i n i s h e d , t h e n t h i n t e r r u p t w i l l f i n i s h n o r m a l l y a n e x e c u t i o n w i l lc o n t i n u e f r o m t h e p o i n t w h e r e t h i n t e r r u p t o c c u r r e d .

D e t e c t i n g t h k e i i n c r e d i b l y s i m p l e . F i r s t t h N M v e c t o r m u s tb c h a n g e d t p o i n t a o u r o u t i n e . S u p p o s e t h e r o u t i n e l i v e s i n t h c a s s e t t e b u f f e r , a $ 0 3 3 C . T h v e c t o r c o u l d b s e u p f r o m B A S I Cl i k e t h i s :

P O K E 7 9 2 , 6 0 : r e m * s e n m l o b y t e t $ 3 P O K E 7 9 3 , 3 r e m * . . h i g h b y t e t $ 0

T h c o d e a $ 0 3 3 C w o u l d p e r f o r m s o m e a c t i o n , s a y , s e u c e r t a i nb o r d e r a n b a c k g r o u n d c o l o u r s , t h e n J M t $ F E 4 7 :

0 3 3 C : A 9 0 L D A * 0 ; b l a c k0 3 3 E : 8 D 2 1 D O S T A $ D 0 2 1 ; b a c k g r o u n d0 3 4 1 : A 9 0 B L D A # 1 1 ; d a r k g r e y0 3 4 3 : 8 D 2 0 D O S T $ D 0 2 0 ; b o r d e r0 3 4 6 : 4 4 F J M $ F E 4 7 ; n o r m a l n m e n t r y

T h a t ' s a l t h e r e i t i t N o w , w h e n e v e r t h R E S T O R E k e i s t r u c k ,t h c o l o u r s w i l l b s e u p T h n o r m a l o p e r a t i o n o R E S T O R E i n o h i n d e r e d , s i n c e t h e n o r m a l N M I - h a n d l e r r o u t i n e a $ F E 4 7 w i l lp e r f o r m w a r m s t a r t i t h R U N S T O P k e i d e p r e s s e d .

Q u e s t i o n a b l e P r o m p t

O k w a l k n o w t h a t B A S I C ' S I N P U T s t a t e m e n t d o e s u f a v o u r sa n d i s p l a y s a q u e s t i o n m a r k a s p r o m p t , f r e e o f c h a r g e . W e l l ,s o m e t i m e s t h e q u e s t i o n m a r k i t o t a l l y o u o p l a c e , s i n c e t h ep r o m p t m e s s a g e i s n ' t q u e s t i o n a a l l , l i k e : P L E A S E E N T E R Y O U RN A M E ? - l o o k s b i s i l l y , d o e s n ' t i t T k i l l t h q u e s t i o n m a r k o na n m a c h i n e , w i t h o u t u s i n g P O K E s o a n y t h i n g m a c h i n e - s p e c i f i c ,o p e n f i l e t t h k e y b o a r d ( d e v i c e n u m b e r 0 a f o l l o w s :

1 0 o p e n 1 , 0 : r e m * o p e n f i l e t k e y b o a r d1 1 p r i n t " P l e a s e e n t e r y o u r n a m e : " ; i n p u t # 1 , n a m e $1 2 c l o s e

B e s i d e s k i l l i n g t h q u e s t i o n m a r k , u s i n g I N P U T i n t h i s w a d o e sn o s e n d c a r r i a g e r e t u r n a f t e r e n t r y , s t h a t m e s s a g e c o u l d b ep r i n t e d o t h s a m e l i n e a s t h e p r o m p t . F u r t h e r m o r e , y o c a r e j e c t n u l l e n t r y e l e g a n t l y b a d d i n g t h l i n e :

1 1 i a $ " t h e n 1 1

T h i s m a k e s t h p r o m p t s e e m t i g n o r e a c a r r i a g e r e t u r n w i t h o u tt e x t .

W h i l e o t h s u b j e c t o o p e n i n g k e y b o a r d f i l e s , i s h o u l d b e n o t e dt h a t t h r e a l a d v a n t a g e l i e s i f u l l - s c r e e n e d i t i n g c a p a b i l i t y . I s t e a d o e n t e r i n g a s t r i n g i r e s p o n s e t t h p r o m p t , y o u c a ns i m p l y m o v e t h c u r s o r t a n s c r e e n l i n e a n p r e s s R E T U R N ,r e a d i n g t h c o n t e n t s o t h a t l i n e i n t o t h I N P U T v a r i a b l e . g o o da p p l i c a t i o n w o u l d b e u s e r - e n t r y o m u l t i p l e f i e l d s , s u c h a n a m e ,a d d r e s s , e t c . T h u s e r c o u l d c u r s o r a r o u n d t h i h e a r t ' s c o n t e n t ,e d i t i n g t h f i e l d s t h i s s a t i s f a c t i o n b e f o r e p r e s s i n g R E T U R N o v e rc o r r e c t f i e l d s . T h p r o g r a m w o u l d r e a d t h f i e l d s o n a t i m e , a n c o u l d e x i t t h I N P U T l o o p w h e n s p e c i a l e n s t r i n g i r e c e i v e d , f o e x a m p l e , " E X I T " .

F a s t B A S I C H I - R E S P o i n t P l o t

H e r e ' s a s h o r t B A S I C s u b r o u t i n e w h i c h w i l l p l o t a p o i n t o b i m a p p e d s c r e e n . T h v a r i a b l e ' B m u s t b s e t t o p o i n t t t h b e g i n n i n g o b i m a p p e d s c r e e n m e m o r y ( n o r m a l l y 8 1 9 2 ) , a n t h a r r a y ' E ( ' m u s t b i n i t i a l i z e d w i t h :

F O T 7 : E ( I ) 2 t ( 7 - l ) : N E X T

1 0 0 0 r e m * p l o t p o i n t *1 0 1 0 1 ( y a n d 2 4 8 ) * 4 0 ( y a n d 7 ) ( x a n d 5 0 4 )1 0 2 0 p o k e l , p e e k ( l ) o r e ( x a n d 7 )1 0 3 0 r e t u r n

T h T r a n s a c t o r 1 V o l u m e 5 I s s u e 0

Page 18: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 18/88

F a s t H I - R E S S c r e e n C l e a r

C l e a r i n g t h b i m a p p e d s c r e e n w i t h P O K E s f r o m B A S I C c a b m a d d e n i n g l y s l o w . H e r e ' s a m a c h i n e l a n g u a g e p r o g r a m t z e r o8 1 9 2 b y t e s a n y w h e r e i m e m o r y . 1 ' t s 1 6 b y t e s l o n g a n f u l l yr e l o c a t a b l e . T h f o l l o w i n g B A S I C p r o g r a m p u t s t h e m a c h i n e l a g u a g e i n t o m e m o r y a n e x e c u t e s i t c l e a r i n g t h e b i m a p p e d s c r e e na 8 1 9 2 ( $ 2 0 0 0 i h e x a d e c i m a l ) .

1 r e m * c l e a r h i - r e s s c r e e n2 d a t a 1 6 2 , 3 2 , 1 6 0 , 0 , 1 5 2 , 1 4 5 , 2 5 1 , 2 0 0 ,

2 0 8 , 2 5 1 , 2 3 0 , 2 5 2 , 2 0 2 , 2 0 8 , 2 4 6 , 9 3 0 r e m * l o a d m p r o g i n t o m e m o r y3 f o r i 0 t o 1 5 : r e a d a : p o k e 8 2 8 i , a : n e x t3 5 4 p o k e 2 5 1 , 0 : p o k e 2 5 2 , 3 2 : r e m * s t a r t a d d r e s s5 s y s 8 2 8 : r e m * e x e c u t e c l e a r r o u t i n e

D e c i m a l t H e c o n v e r s i o n T a b l e B r i a n D o b b s

B e f o r e y o b r e a t h d e c - t o - h e x - p r o g r a m s - h a v e - b e e n - d o n e - t o -d e a t h s i g h , p l e a s e n o t e : t h i s o n p r o d u c e s n e a t l o o k i n g t a b l e o n p r i n t e r , f o r f u t u r e r e f e r e n c e . E v e n i y o a l r e a d y h a v e s u c h t a b l e ,r u n n i n g t h i s p r o g r a m w i l l s a v e y o u a r u t y o u r n e a r e s t p h o t oc o p y m a c h i n e i y o u n e e d e x t r a c o p i e s . A t h p r o g r a m s t a n d s , i g o e s f r o m z e r o t 2 5 5 , b u t h e t o p l i m i t c a n b e c h a n g e d i n l i n e 1 3 0 .

1 0 r e d e c i m a l t h e c o n v e r s i o n t a b l e1 1 r e b b r i a n d o b b s - t i m m i n s , O n t a r i o1 2 0 :1 3 m a 2 5 5 : r e m * h i g h e s t v a l u e i t a b l e1 4 0 o p e n 4 , 4 , 1 : x 0 : = 1 : k $ =1 5 p r i n t # 4 , s p c ( 2 5 ) " d e c i m a l t h e c o n v e r s i o n t a b l e "1 6 0 :1 7 r e m — m a i n p r i n t i n g l o o p1 8 x : g o s u b 2 8 0 : r e m * c o n v e r t t h e 1 9 i x > t h e n k — 2 0 i x > 9 9 t h e n k - 2 1 0 p r i n t # 4 , t a b ( 5 ) ; x ; k $ ; h $ ;2 2 = x + 1 : y y + 1 : i f y t h e n : p r i n t # 42 3 i x m a x g o t o 1 8 02 4 p r i n t # 4 : c l o s e 4 : e n d2 5 r e m — e n l o o p2 6 0 :2 7 0 r e m * c o n v e r t d e t h e s u b r o u t i n e *2 8 h " : d / 4 0 9 6 : f o r i t o 4 : d % = d : h $ h

c h r $ ( 4 8 d % - ( d ° / o > 9 ) * 7 ) : d 1 6 * ( d - d % ) : n e x t2 9 r e t u r n

L a r g e C h a r a c t e r s o n V I C o r 6 4

T h R O c h a r a c t e r g e n e r a t o r i a c c e s s i b l e t B A S I C o n t h V I a n 6 4 B y P E E K i n g i n t o t h e c h a r a c t e r g e n e r a t o r R O M , y o c a d u p l i c a t e t h e s h a p e o a l 5 1 c h a r a c t e r s i m a g n i f i e d f o r m ( t i m e sl a r g e r ) . T h f o l l o w i n g p r o g r a m a s k s f o t h e d e s i r e d c h a r a c t e r s e t ,a n t h e c h a r a c t e r t b p r i n t e d . I u s e s t h s u b r o u t i n e s t a r t i n g a l i n e 3 3 t p r i n t l a r g e i m a g e o t h c h a r a c t e r , u s i n g a s t e r i s k s a sp i x e l s . T h a v a i l a b l e c h a r a c t e r s e t s a r e :

T h T r a n s a c t o r

C h a r S e D e s c r i p t i o nu p p e r c a s e / g r a p h i c su p p e r / l o w e r c a s e

2 r e v e r s e u p p e r / g r a p h i c sr e v e r s e u p p e r / l o w e r

F o t h V I v e r s i o n , c h a n g e l i n e 1 6 a i n d i c a t e d a n d e l e t e l i n e s3 5 0 , 3 7 0 , a n 4 4 t e n d . T h 6 v e r s i o n n e e d s e x t r a c o d e b e c a u s ei t c h a r a c t e r R O i h i d d e n u n d e r I / O , a n i m u s t b e x p r e s s l ys w i t c h e d i a n o u t . U n f o r t u n a t e l y , s w i t c h i n g o u t t h I / w i l lc r a s h t h m a c h i n e u n l e s s t h e i n t e r r u p t s a r d i s a b l e d , s t h a t m u s tb d o n e a s w e l l . S u b r o u t i n e s h a n d l e t h R O s w i t c h i n g .

1 0 r e m * * * * * * * * * * * * * * * * * * * * * *1 1 r e m * p r i n t l a r g e c h a r a c t e r s1 2 r e m * t r a n s a c t o r m a g a z i n e1 3 r e m * w r i t t e n s e p ' 8 4 - c z1 4 0 r e m * * * * * * * * * * * * * * * * * * * * * *1 5 0 :1 6 c r o m = 1 3 * 4 0 9 6 : r e 8 * 4 0 9 6 f o v i 1 7 f o 0 t o 7 : e ( i ) 2 t ( 7 - i ) : n e x t1 8 0 :1 9 p r i n t c h r $ ( 1 4 7 )2 0 f o l o o p t s t e p2 1 i n p u t " c h a r a c t e r s e ( 0 - 3 ) " ; s e t2 2 i n p u t " c h a r a c t e r " ; c 2 3 p r i n t c h r $ ( 1 4 7 ) c $2 4 0 : c p p e e k ( p e e k ( 6 4 8 ) * 2 5 6 ) * 82 4 r e s s c r e e n l o g i v e s c h a r2 5 0 : r o m = c r o m s e t * 1 0 2 4 c 2 6 p r i n t2 7 g o s u b 3 3 0 : r e m * p r i n t i m a g e2 8 p r i n t2 9 n e x t l o o p3 0 0 :3 1 0 :3 2 - s u b r o u t i n e s :3 3 r e m * t r a n s l a t e r o m i m a g e3 4 f o i = t 3 5 0 g o s u b 4 6 0 ' c h a r r o i 3 6 l i n e p e e k ( r o m i )3 7 g o s u b 5 4 ' i / i 3 8 f o t 3 9 d i s p : i l i n e a n e ( j ) t h e n d i s p4 0 r e m * s p a c e f o 0 ' * f o 4 1 p r i n t m i d $ ( " * " , d i s p , 1 ) ;4 2 n e x t j : p r i n t : n e x t4 3 r e t u r n4 5 0 :4 6 r e m * s w i t c h c h a r r o i 4 7 p o k e 5 6 3 3 4 , p e e k ( 5 6 3 3 4 ) a n d 2 5 4 8 r e m * t u r n i n t e r r u p t s o f 4 9 p o k e 1 , p e e k ( 1 ) a n d 2 5 5 0 r e m * e n a b l e c h a r a c t e r s e r o 5 1 r e t u r n5 3 0 :5 4 r e m * r e - e n a b l e i / 5 5 0 p o k e 1 , p e e k ( 1 ) o r 45 6 r e m * t u r n i n t e r r u p t s o 5 7 0 p o k e 5 6 3 3 4 , p e e k ( 5 6 3 3 4 ) o r5 8 0 r e m * s w i t c h i i / o *5 9 r e t u r n

1 V o l u m e 5 I s s u e 0

Page 19: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 19/88

L e t t e r sD o c t o r D e s t r u c t o : w a v e r y p l e a s e d w i t h t h d e p t h o c o v e r a g eo s o f t w a r e p r o t e c t i o n i y o u r m o s t r e c e n t T r a n s a c t o r o t h s u b j e c t . I ' l i k e t o s h a r e t h e f o l l o w i n g p h i l o s o p h y a n d m a c h i n el a n g u a g e r o u t i n e w i t h y o u . I y o w i s h y o m a p a s s t h i s a l o n gt h r o u g h t h p a g e s o y o u r m a g a z i n e .

Q u i t e n u m b e r o p r o t e c t i o n s c h e m e s y o m e n t i o n e d u s e d v e ct o r s t h a t a r e , w h e n n o u s e d i t h s p e c i f i c e x e c u t i o n , s e t t o p o i n t a s y s t e m r e s e t ( $ F C E 2 6 4 7 3 8 ) i t h C o m m o d o r e 6 4 w h i c h i t h c o m p u t e r o w n . S o m e t i m e a g o w r o t e a e d u c a t i o n a l p r o g r a mc o m p o s e d o p r o g r a m f i l e s o d i s k . T h p r o b l e m o p r o t e c t i n gc o d e w i t h r e s e t i t h a t B A S I C o m a c h i n e l a n g u a g e p r o g r a m i n o d e s t r o y e d . B A S I C p r o g r a m c a n b e r e c o v e r e d w i t h a " U N N E -W ' u t i l i t y a n m a c h i n e l a n g u a g e c a b e h u n t e d d o w n a n c o p i e d ,t h B A S I C p r o g r a m b e i n g t h s i m p l e s t . t h e r e f o r e w r o t e t h e n c l o s e d c o d e t c o v e r t h e t r a c k s o m p r o g r a m w i t h b i n a r y s n o wi t h e v e n t t h a t r e s e t i p e r f o r m e d o i t

h a v e o v e r 5 o s p r i t e s i t h p r o g r a m u n d e r t h B A S I C R O w h e r e t h V I 1 c h i p c a s e t h e m b u w a n t e d t d e s t r o y t h o s ei m a g e s a w e l l i m r e s e t p r o t e c t i o n . S w a n t e d t w i p e m e m o r yf r o m $ 0 8 0 0 t $ D 0 0 0 w i t h $ 0 b y t e s a n t h e n f o t h e e x t r am i l l i s e c o n d s i t a k e s c o p i e d t h I / a n K e r n a l R O M s t R A f r o m $ D 0 0 0 t $ F F F F . T h r e a s o n f o t h i s i b e c a u s e t h i n k i i p o s s i b l e f o f e r r e t p r o g r a m t b p l a c e d i t h e M . L . b u f f e r o u n d e r R O c h i p t h a n c a d s o m e t h i n g d e v i o u s . T h c o d ee n c l o s e d e m u l a t e s c a r t r i d g e a n i l o a d e d i a $ 8 0 0 0 t $ 8 0 5 8 s t h a t w h e n a r e s e t i c a l l e d t h e s t a r t - u p c o d e s a r c h e c k e d b R O r o u t i n e s a n t h e n c o n t r o l i t r a n s f e r r e d o v e r t m p r o g r a m . T h p r o g r a m m o v e s i t s e l f o u o t h w a i n t o t h c a s s e t t e b u f f e r t a v o i d b e i n g o v e r w r i t t e n a n t h e r e f o r e b o m b e d , a n d t h e n z e r o ' so u m e m o r y f r o m $ 0 8 0 0 t $ D 0 0 0 . I t h e n c o p i e s t h R O M s i n t ot h e i r u n d e r l y i n g R A f r o m $ D 0 0 0 t $ F F F F . I h a c o n t i n u e d t f i l l m e m o r y u t $ F F F F w i t h z e r o b y t e s t h e n t h s c r e e n w o u l d g b l a c k f o m o m e n t a n d i d n ' t w a n t t g i v e h a c k e r s a n c l u e s a a l s u s e d t h R O t R A m e t h o d . T h p r o g r a m t h e n c a l l s t h h a r d w a r e r e s e t s e q u e n c e .

T h i s i s a l l w e l l a n g o o d a f a a I ' v e t a k e n i t F o s p e c i f i ca p p l i c a t i o n s s u c h a m i n e t h o u g h t h c o d e m a h a v e t b l o c a t e de l s e w h e r e w i t h t h e m u l a t i o n p o r t i o n ( t h e f i r s t b y t e s ) p l a c e db e f o r e e x e c u t i o n . A l s o t h e r e i n s t o p p i n g s o m e o n e L O A D i n gp r o g r a m ( t h e f e r r e t r e f e r r e d t e a r l i e r ) t h a t s i t s i a u n d i s t u r b e da r e a w h i c h c o u l d w a i t a a p p r o p r i a t e t i m e a n t h e n u n - l o c k t h p r o g r a m . H o w e v e r , w i t h a s m a l l a m o u n t o i n g e n u i t y , t h i s c o d ec o u l d b L O A D e d b y a n a u t o - r u n b o o t t h e n b c a l l e d u p o n t w i p em e m o r y c l e a n b e f o r e l o a d i n g i t h e p r o t e c t i o n p r o g r a m a g a i n a n t h e n t h p r o g r a m t h a t r e q u i r e s p r o t e c t i o n . h o p e y o u u n d e r s t a n dm l o g i c o t h i s .

c h o s e t t r a n s f e r t h m e m o r y w i p e o u c o d e t t h c a s s e t t e b u f f e rb e c a u s e t h r e s e t t h a t i c a l l e d a s t h l a s t i n s t r u c t i o n r e n e w s t h b u f f e r w i t h z e r o b y t e s , s o t h e r e i l i t t l e i a n e v i d e n c e o w h a th a c k e r i u a g a i n s t w h e n h u s e s r e s e t b u t t o n t b r e a k i n t op r o g r a m . h o p e y o u e n j o y t h i s c o n c e p t a c e r t a i n l y d i w h i l ew r i t i n g t h i s c o d e .

C h r i s J o n e sC l e a r b r o o k , B . C .

l o o p

d r o p o u t

s n o b e g

s n o j o b

r o m r a m

. e n d

R e s e t P r o t e c t o r

$ 8 0 0 0. b y t $ 0 9 , $ 8 0 ,. b y t $ 6 0 , $ c 3 ,. b y t $ c d , $ 3 8 ,

e l I d s t I d s t I d s t I d s t I d

I d s t c p b e i n b n

j m

I d I d s t

I d

s t i n b n i n I d e m b n I d s t I d s t

I d s t i n b n i n I d b n j m

# $ 2 a$ f # $ 8 0$ f # $ 3 c$ f # $ 0 3$ f # $ 0 0

( $ f b ) , y( $ f d ) , y# $ 2 fd r o p o u t

l o o p

*

$ 0 3 3 c

# $ 0 0# $ 0 8$ f

# $ 0 0

( $ f b ) , y

s n o j o b$ f $ f # $ d 0s n o b e g# $ 0 0$ f # $ d 0$ f

( $ f b ) , y( $ f b ) , y

r o m r a m$ f $ f r o m r a m$ f c e 2

$ 3 ; l o w b y t e h i g h b y t e s t a r t$ c ; c o d e t h a t w i l l e m u l a t e$ 3 ; c a r t r i d g e r o m m o d u l e

; s e t l o a d f r o m a d d r e s s; h i / l o i z e r o p a g e

; f o r i n d i r e c t s e l o a d; t a d d r e s s i z e r o p a g e

; s e t c o u n t e r

; g e t b y t e; p u t a b y t e; l a s t o n e; i s o d r o p o u t

; l o o p b a c k

; t n e l o c a t i o n

; s e t z e r o p a g e f o ; b i n a r y s n o w j o

; a n d d i

; l o o p b a c k

; s e t c o m p a r e; t e n a d d r e s s; l o o p b a c k; s e t u f o r o ; t r a t r a n s f e r

; g e t b y t e; c o p y i

; l o o p b a c k; b u m p a d d r e s s; s e t c o m p a r e; l o o p b a c k; d s y s t e m r e s e t

T h T r a n s a c t o r 1 V o l u m e 5 I s s u e 0

Page 20: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 20/88

T h a n k s f o t h e n l i g h t e n i n g m i x t u r e o f t h o u g h t s a n c o d e . Y o u ' r er i g h t , a m o s t a l r e a d y k n o w , t h a t r e g u l a r s y s t e m r e s e t w i l l c l e a ra n p r e v i o u s a l t e r a t i o n s t o p e r a t i n g s y s t e m R A M , b u t l e a v e B A S I Co u s e r R A i n t a c t . W i t h y o u r c o d e i p l a c e , l i t t l e d o e s t h c r a f t yp i r a t e k n o w t h a t t r o u b l e s a r t s o o n a p p e a r o t h e h o r i z o n . J u s t i c a s e a f e w o y o d o n ' t n e e d t h a t m u c h p r o t e c t i o n , b e l o w w i l l b f o u n d b i o d e a d l y c o d e t h a t w i l l l e a v e i i t w a k e l i t t l e m o r et h a n b i n a r y r u b b l e . I t ' s s e l f m o d i f y i n g , s e v e r e n n o b u i p u r p o s e i t k i l l c o d e , n o w i a n p r i z e s . P l a c e i w h e r e e v e r y o f e e l i w i l l i n f l i c t t h m o s t d a m a g e , t h e n p o i n t f e v e c t o r s a t i t I t ' sc r u d e b u e f f e c t i v e .

= $ 0 8 2 8 ; o w h e r e v e r y o u p l e a s e

s e ; m a k e s u r e n o t h i n g w i l l i n t e r r u p t u I d #

d e a t hs t e n d . x ; w h a t e v e r i i t h a c c u m i o i n b n d e a t h ; d e s t r u c t o m o d e ! !i n d e a t h + ; i n c r e m e n t t h h i g h s t o r a g e b y t ej m d e a t h ; t h e n j u m p i n t o t h p i o n c e a g a i n

. e n d

C o i n S i d e O n e : Y o u r N o v e m b e r e d i t o r i a l , " P i r a c y : F a c t o L i f e ? " w a r e f r e s h i n g l y a c c u r a t e . E v e r y o t h e r m a g a z i n e h a v e s e e nc a t e r s t t h e a d v e r t i s e r s b t a k i n g a s t r o n g e d i t o r i a l s t a n d a g a i n s t" p i r a c y " s o - c a l l e d . Y o u r s i t h o n l y o b j e c t i v e o p i n i o n h a v e r e a di e i g h t y e a r s o c o m p u t i n g .

a t h a u t h o r o " T h e C o d e B o o k " , ( L o o m p a n i c s P r e s s , 1 9 7 9 ,1 9 8 3 ) . M p u b l i s h e r t a k e s t h e s a m e v i e w y o d o H s e l l s c o p i e s o m b o o k r e t a i l . H k e e p s t h p r i c e l o e n o u g h t d i s c o u r a g ep h o t o c o p y i n g ; h a l s o r e a l i s e s t h a t i P e r s o n w a n t s t g i v eP e r s o n p h o t o c o p y o t h b o o k , t h e r e i n o t h i n g h c a d a b o u ti t M o r e i m p o r t a n t l y , v e r y f e b u y e r s w o u l d b w i l l i n g t d t h i s .

T h m a r k e t p l a c e p u t s a l i m i t o s o f t w a r e p i r a c y . I d a y s g o n e b p i r a t e s h a r r i e d o c e a n t r a d e . P i r a c y w a p r o f i t a b l e b e c a u s e M e r c a nt i l i s t t a r i f f s a n d u t i e s a r t i f i c i a l l y r a i s e d t h e p r i c e o i m p o r t s .S m u g g l e r s c i r c u m v e n t e d t h e s e r e s t r a i n t s o t r a d e . T h ( n o m i n a l )f r e e t r a d e o t h e 1 7 0 0 ' s a n 1 8 0 0 ' s e l i m i n a t e d p i r a c y .

S o f t w a r e p i r a c y i p r o f i t a b l e b e c a u s e o " S o f t w a r e M e r c a n t i l i s m " .C o m p u t e r s c o p y d a t a a s p a r t o t h e i r i n t e g r a l f u n c t i o n . T h o s e w h a t t e m p t t o l i m i t t h r i g h t t a r t r y i n g t e v a d e t h f a c t s o f r e a l i t y .I f a c t , s o f t w a r e c o m p a n i e s e n c o u r a g e p i r a c y b p l a c i n g h i g h p r i c et a g s o m u n d a n e p r o g r a m s . I c o m m e r c i a l p a c k a g e c o s t s $ 4 0 0a n y o v a l u e y o u r t i m e a $ 1 p e h o u r , t h e n s p e n d i n g 4 0 h o u r so v e r c o m i n g p r o t e c t i o n s c h e m e s i p r o f i t a b l e . O t h o t h e r h a n d , i t h c o m m e r c i a l p a c k a g e s e l l s f o $ 1 5 0 , y o h a v e t g e t h j o d o n e i 1 h o u r s t b r e a k e v e n . H a v i n g s p e n t 1 ( o 4 0 h o u r s a w o r k , w h w i l l G I V E A W A Y c o p y o p i r a t e d p r o g r a m ?

M p u b l i s h e r f u r t h e r d i s c o u r a g e s c o p y r i g h t i n f r i n g e m e n t b b i n di n t h b o o k a n p u t t i n g a a t t r a c t i v e c o v e r o i t D o c u m e n t a t i o ni t h e s o f t w a r e e q u i v a l e n t o t h i s . h a v e t r i e d t o u s c o p i e s o p r o f e s s i o n a l s o f t w a r e ; w i t h o u t t h m a n u a l , i t ' s e a s i e r t w r i t eB A S I C r o u t i n e o m o w t d t h j o t h e n t d e c i p h e r t h s y n t a xo h i t - o r - m i s s .

S o f t w a r e p i r a c y w i l l b d e f e a t e d w h e n t h s o f t w a r e m a r k e t e n j o y sf r e e t r a d e c l i m a t e . V i s i C a l c i w o r t h a b o u t $ 3 0 ; L o t u s 1 - 2 - 3 i

w o r t h a b o u t $ 1 0 0 ; W o r d S t a r i $ 2 v a l u e . T h a t ' s t h b o t t o m l i n eo p i r a c y . M i c h a e l E M a r o t t a

L a n s i n g , M

T h a n k y o f o y o u r c o m m e n t s . A n w q u i t e a g r e e N s i n g l e f o r c ew i l l s t o p t h c o n s t a n t w h i r o t h p h o t o c o p y i n g m a c h i n e , n o t h d u p l i c a t i o n o r e c o r d a l b u m o n t o c a s s e t t e t a p e . T h s a m e h o l d st r u e f o r t h e c o m p u t e r p r o g r a m m e r t h a t h a s p e c i a l k n a c k f o b r e a k i n g p r o t e c t i o n c o d e . T h e h a r d l i n e a t t i t u d e s o s o m e c o m p a ni e r e g a r d i n g c o p y r i g h t i n f r i n g e m e n t , a n t h e v e r p r e s e n t t h r e a t o l e g a l a c t i o n , w i l l n o d e t e r m i n e t h t r u e p o w e r o c o p y r i g h t . I I t h p u b l i c t h a t w i l l .

C o i n S i d e T w o : r e c e i v e d m c o p y o V o l u m e 5 I s s u e 0 y e s t e r d a y a n r e a d t h e l e t t e r o p a g e 1 r e C o p y r i g h t R i g h t s .f o u n d m y s e l f f r u s t r a t e d a n d i s m a y e d t h a t T h T r a n s a c t o r c o u l dr e s p o n d t h i s w a t s u c h a n i m p o r t a n t i s s u e .

T h e d i t o r i a l r e s p o n s e m i s s e d t h e p o i n t c o m p l e t e l y . I w a s h y p oc r i t i c a l , w i t h o u t a n s e n s e o r e a s o n a b l e n e s s a n n o t w e l l r s e a r c h e d .

T h T r a n s a c t o r s u g g e s t s t h a t u n i v e r s a l ( s h o u l d b r e a d a " f r e e " )a c c e s s t s o f t w a r e s h o u l d b e x p e c t e d , y e d e v o t e d t h i s e n t i r e i s s u et c o n c e r n o v e r p i r a c y a n c o p y p r o t e c t i o n ; t h u s i m p l y i n g t h a tp r o g r a m s h a v e s o m e v a l u e t h a t s h o u l d b e p r o t e c t e d . I a d d i t i o n ,r e f e r t p a g e a n T h T r a n s a c t o r ' s c o p y r i g h t p o l i c y a n s u g g e s tt h a t y o u c o m p a r e i t t h a t o f C O M P U T E ! m a g a z i n e .

T h o r i g i n a l l e t t e r e n d s w i t h a n e x t r e m e s i t u a t i o n t h a t i t o t a l l yu n r e a s o n a b l e . I T h T r a n s a c t o r i t r e m a i n s y m p a t h e t i c t o t h i s" c a u s e " , t h e n w o u l d b v e r y i n t e r e s t e d i w h a t y o u r r e a l l i f er e a c t i o n w o u l d b t T P U G m a i n t a i n i n g o n s u b s c r i p t i o n f o T h T r a n s a c t o r a n s e n d i n g p h o t o c o p i e s t a b o u t 2 0 , 0 0 0 m e m b e r s , a l i t h n a m e o f u r t h e r i n g a c c e s s t e d u c a t i o n a l m a t e r i a l . P e r h a p sC O M P U T E ! w o u l d e n d u p r u n n i n g a a r t i c l e s i m i l a r t y o u r s o p a g e o f t h i s i s s u e w h i c h a n n o u n c e s t h d e m i s e o C O M A N D E R .

a d m i t t h a t t h a b o v e s i t u a t i o n w o u l d b e x t r e m e , b u i a r e a s o n a b l e a s a y i n g t h a t c a n ' t l e m f o u r y e a r o l d a u g h t e r u s et h e e d u c a t i o n a l p r o g r a m s t h a t a p p e a r i C O M P U T E i ' s v a r i o u sp u b l i c a t i o n s b e c a u s e i i i l l e g a l ( m s u b s c r i p t i o n , n o m d a u g ht e r s ) . O t h o t h e r h a n d , r e a s o n a b l e n e s s d o e s n o a l l o w m t p r o v i d e c o p i e s t a l m n e i g h b o r s .

I i n o u n r e a s o n a b l e t r e q u e s t t h a t t e a c h e r s c o n t a c t p u b l i s h e r sf o p e r m i s s i o n b e f o r e a t t e m p t i n g t u s t h e m a t e r i a l f o e d u c at i o n a l p u r p o s e s , e s p e c i a l l y f r o m s o u r c e s o u t s i d e o t h c o n v e nt i o n a l e d u c a t i o n a l m a t e r i a l s . a c e r t a i n t h a t r e q u e s t s o t h i sn a t u r e w o u l d g e n e r a t e p o s i t i v e r e s p o n s e s a q u i c k l y f r o m C O P U T E ! p u b l i c a t i o n s a f r o m t h e T r a n s a c t o r .

P i r a c y i n o t h i n g m o r e t h a n m a k i n g u n a u t h o r i z e d c o p i e s o m a t er i a l a n d i s t r i b u t i n g t h e m f o p e r s o n a l g a i n , m o n e t a r y o o t h e rw i s e . A s i d e f r o m p o s s i b l e s c a l e s o v o l u m e , w h a t i t h d i f f e r e n c eb e t w e e n t h A p p l e l a w s u i t s ( c o p y r i g h t i n f r i n g e m e n t ) a n d u n r es t r i c t e d c o p y i n g o p r o g r a m l i s t i n g s p u b l i s h e d u n d e r c o p y r i g h t i m a g a z i n e s . T h T r a n s a c t o r p u b l i s h e d a o p i n i o n , i n t h i s i s s u e ,w h i c h f l i e s i t h f a c e o u n r e s t r i c t e d c o p y i n g f o " e d u c a t i o n a l "p u r p o s e s .

T h T r a n s a c t o r 1 V o l u m e 5 I s s u e 0

Page 21: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 21/88

A l s o , a d i s a p p o i n t e d t h a t T h T r a n s a c t o r w o u l d m a k e s u c hc o m m e n t s a b o u t d i r e c t c o m p e t i t o r , e s p e c i a l l y u n p r o v o k e d a i i s a n n o f u l l y r e s e a r c h e d . T h a u t h o r o t h l e t t e r d i d n o t e x p l a i nt h c o n t e x t i w h i c h c o p y r i g h t b e c a m e a s u b j e c t f o e d i t o r i a lc o n s i d e r a t i o n a n c o m m e n t i C O M P U T E R S p u b l i c a t i o n s a n T h T r a n s a c t o r d o e s n o a p p e a r t h a v e r e s e a r c h e d i b e y o n d t h M a 1 9 8 4 i s s u e .

I g o e s b e y o n d t h u s o t h e p r i n t e d p r o g r a m s t t h w h o l e s a l ec o p y i n g o d i s k e t t e s a v a i l a b l e f r o m p r o g r a m e n t r y s u b s c r i p t i o no f f e r e d b C O M P U T E R S G a z e t t e . O p i n i o n s w e r e r e q u e s t e d a b o u tc l u b m a i n t a i n i n g o n d i s k e t t e s u b s c r i p t i o n a n t h e n p r o v i d i n gc o p i e s t a l c l u b m e m b e r s . T h e d i t o r s w e r e o p p o s e d t a p p l y i n gc o p y p r o t e c t i o n t e c h n i q u e s t t h e s e d i s k e t t e s , b u w e r e c o n c e r n e da b o u t p r o t e c t i o n o t h a u t h o r s ' r o y a l t y r i g h t s . T h e y u l t i m a t e l yd e c i d e d i f a v o u r o t h s u b s c r i b e r s , a l e a s t o a i n t e r i m b a s i s .A t t i t u d e s , a s e x p r e s s e d b t h a u t h o r o y o u r l e t t e r w a n t i n gp r o g r a m s ( a n d p o s s i b l y s e r v i c e s ) w i t h o u t c h a r g e , w i l l s u r e l y a i i c h a n g i n g C O M P U T E ! ' s f a i t h i n t h s e n s e o f a i r n e s s o t h e g e n e r a lp u b l i c . e x p e c t t h a t s o o n e r o l a t e r , s o m e c o p y p r o t e c t i o n i g o i n gt b i n t r o d u c e d b e c a u s e o s u c h m i s g u i d e d o p i n i o n s .

P e r s o n a l l y , a a g a i n s t c o p y p r o t e c t i o n o s o f t w a r e b e c a u s e i c o m p r o m i s e s t h p u r c h a s e r s a b i l i t y t o f r e e l y u s h i p r o p e r t y .H o w e v e r , a l s o b e l i e v e i t h r i g h t s o f t h a u t h o r s a n t h a t t h e ys h o u l d b p r o t e c t e d t t h e e x t e n t r e q u i r e d . I i t h e g e n e r a l p u b l i ct h a t w i l l d e t e r m i n e t h e x t e n t t w h i c h c o p y p r o t e c t i o n w i l l b r e q u i r e d . a i f a v o u r o e d u c a t i n g t h e u s e r s o s o f t w a r e , b u t o n l ya f a a i i f a i r t a l o t h e r p a r t i e s i n v o l v e d .

c u r r e n t l y s u b s c r i b e t e i g h t c o m p u t e r m a g a z i n e s i n c l u d i n g T h T r a n s a c t o r a n b o t h C O M P U T E ! p u b l i c a t i o n s c o v e r i n g C o m m od o r e p r o d u c t s . c a a t t e s t t o t h f a c t t h a t y o u r l e t t e r w r i t e r i g o i n gt l o s e o u a f a a s g a i n i n g k n o w l e d g e i c o n c e r n e d b e c a u s e f i n dv e r y l i t t l e d u p l i c a t i o n i t h e s e m a g a z i n e s w i t h r e s p e c t t t e c h n i c a lm a t t e r s . I i s h a m e t h a t i i g o i n g t r e s u l t f r o m s u c h n a r r o w -m i n d e d n e s s .

A s i d e f r o m t h i s s l i p i n e d i t o r i a l c o m m e n t a n a t t i t u d e , f i n d T h T r a n s a c t o r t b v e r y i n t e r e s t i n g a n i n f o r m a t i v e , a n e a g e r l ya n t i c i p a t e i t a r r i v a l w e l l i a d v a n c e . J a m e s V a n E d e n

R i v e r v i e w , N . B .

Y o u r c o m m e n t s h a v e b e e n m o s t i n f l u e n t i a l a n w e l l t a k e n . C o s t r u c t i v e c r i t i c i s m i a s v a l u a b l e t u s a s c o m p l i m e n t s a n w i n v i t ea n y o n e t s e n d i t h e i r b e e f s .

W i t h o u t t r y i n g t j u s t g e t t h e l a s t w o r d i n w w o u l d j u s t l i k e t op o i n t o u t t h a t s o f t w a r e p r o t e c t i o n i j u s t a n o t h e r a s p e c t o f c o m p u ti n g , h e n c e t h t h e m e o V o l u m e 5 I s s u e 0 3

A f a a C O M P U T E ! " s p o l i c i e s g o , p e r h a p s w d i " f l y o f t h h a n d l e " p r e m a t u r e l y . H o w e v e r , w f u l l y i n t e n d t c o n t i n u e s t a t i n gt h f a c t s a w s e t h e m a w e l l a r e a d e r s u b m i s s i o n s , n m a t t e rh o o p i n i o n a t e d . T h t e x t t h a t o r i g i n a l l y i n c i t e d t h i s c o n t r o v e r s yc o u l d h a v e b e e n m o r e c a r e f u l l y w o r d e d o t h l e t t e r f r o m M r J a m e s w o u l d n e v e r h a v e b e e n w r i t t e n .

L a s t l y , i o n l y n a t u r a l t c o p y u n p r o t e c t e d d i s k s . I t h a t ' s h o y o w a n t t s e l l t h s o f t w a r e t h e n t h o n l y l o g i c a l a p p r o a c h i t m a k et h e d i s k s c h e a p t h a t i b e c o m e s u n e c o n o m i c a l f o t h m a j o r i t y( e m p h a s i s o m a j o r i t y ) t e v e n l e a v e t h h o u s e t o b t a i n c o p y .

E v e n a c o u p l e o d o l l a r s c a m a k e t h d i f f e r e n c e a t h i s p o i n t . L i k eC O M P U T E a n A h o y , w t o w i l l b o f f e r i n g d i s k e t t e s e r v i c e . W f u l l y e x p e c t u n a u t h o r i z e d c o p i e s w i l l b m a d e . B u w a l s o e x p e c to u p r i c e w i l l s e l l e n o u g h o t h e m t m a k e i w o r t h o u r w h i l e .P r o t e c t e d d i s k e t t e s h a v e o n l y o n m o r e s a f e g u a r d y o u m u s t f i r s tf i n d s o m e o n e w i t h b r o k e n c o p y b e f o r e y o c a o b t a i n o n e . M o s td o n ' t h a v e s u c h c o n n e c t i o n s , b u a l o n g a s t h e p r i c e m i g h t b ec o n s i d e r e d h i g h e n o u g h t w a r r a n t s o m e s l e u t h i n g , u n r e s t r i c t e dc o p y i n g w i l l c o n t i n u e t b e p r o b l e m .

T r a n s b l o o p e r sV o l . 5 i s s u e" D y n a m i c E x p r e s s i o n E v a l u a t i o n "1 ) A l a s t - m i n u t e t y p e s e t t i n g g o o f - u p e n d e d u p m u t i l a t i n gt h t a b l e o n p a g e 2 8 b e y o n d r e c o g n i t i o n . T h t a b l e s h o u l dh a v e l o o k e d l i k e t h i s :

P R O M P T

m a x i m u m r a n g e ?a g i d a y s ?d i s t a n c e i k i l o m e t r e s ?s p e e d i m p h ?y e a r l y r e v e n u e ?m o n t h l y i n c o m e ?l e n g t h o h y p o t e n u s e ?

R E S P O N S E

2 * 7 12 8 * 3 6 51 2 0 * 1 . 69 0 * 0 . 6m t l y * 1 2y r l y / 1 2s q r ( a * a b * b )

2 I t h s a m e a r t i c l e , r e f e r e n c e w a m a d e t D a r r e nS p r u y t ' s a r t i c l e " i t h l a s t i s s u e " . T h i s a r t i c l e ( " G e t t i n gB A S I C t C o m m u n i c a t e w i t h Y o u r M a c h i n e C o d e " ) a c t u a l l ya p p e a r e d i t h p r e v i o u s i s s u e : V o l . 5 i s s u e ( " T h e T r a n s it i o n T o M a c h i n e L a n g u a g e " w a t h t h e m e ) .

3 B i t s P i e c e s : " S H I F T i n g y o u r W A I T "

m e t h o d w a g i v e n f o w a i t i n g u n t i l t h s h i f t k e w a p r e s s e d , b u t t h g i v e n a p p l i c a t i o n c a l l e d f o h a l t i n g i t h s h i f t k e w a p r e s s e d ( j u s t t h o p p o s i t e ) . T h c o r r e c t s t a t em e n t s a r e :

W A I T 6 5 4 , 1 , 1 ( C 6 4 )W A I T 1 5 2 , 1 , 1 ( 4 0 / 8 0 3 2 )

T h a b o v e w i l l c a u s e h a l t i p r o g r a m I t h s h i f t l o c k k e i e n g a g e d .

V o l . 5 i s s u e" P i c p r i n t "4 ) T h e a r t i c l e m a d e s e v e r a l m e n t i o n s o u s i n g t h e F l k e t s w i t c h b e t w e e n t e x t a n h i g h - r e s o l u t i o n v i d e o m o d e s . T h k e t u s i a c t u a l l y t h F k e y , a s t a t e d i t h s o u r c e c o d eo t h p r o g r a m .

5 A l s o i t h P i c p r i n t p r o g r a m , t h p r i n t e r c o d e s u s e d f o d u a l - d e n s i t y g r a p h i c s a r 2 a n 1 2 ( E S C y ) T h e s e c o d e se n a b l e d u a l - d e n s i t y g r a p h i c s a d o u b l e s p e e d o n t h S t a rG e m i n i - 1 O p r i n t e r . T h m o r e c o m m o n c o d e s f o r e g u l a rd u a l - d e n s i t y g r a p h i c s a r 2 a n 7 ( E S C L )

T h T r a n s a c t o r 1 V o l u

Page 22: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 22/88

T h C o m m o d o r e D O S : R e v i e w O f T w B o o k sb D a v i d A H o o k

B a r r i e , O n t a r i oT i t l eA u t h o r sE d i t o r sP u b l i s h e r

C o s tA u d i e n c e

T h A n a t o m y o t h 1 5 4 1 D i s k D r i v eL o t h a r E n g l i s c h N o r b e r t S z c z e p a n o w k s iG r e g D y k e m a a n A r n i e L e eA b a c u s S o f t w a r eP B o 7 2 1 1G r a n d R a p i d s , M 4 9 5 1 01 9 8 4 , 3 2 p a g e s$ 1 9 . 9 5 ( U . S . )a d v a n c e d , m a c h i n e l a n g u a g e

T i t l eA u t h o r sP u b l i s h e r

C o s tA u d i e n c e

B o t h t h e s e b o o k s a r r e c e n t p u b l i c a t i o n s , a n d e a l w i t h t h i n t e r n a l d i s k o p e r a t i n g s y s t e m ( D O S ) o t h C o m m o d o r e 1 5 4 1 d i s kd r i v e . T h s u b j e c t i t h s a m e , b u t t h e c o n t e n t d i f f e r s s u b s t a n t i a l l y ,s i s e e m s a p p r o p r i a t e t h a t t h e y b e r e v i e w e d t o g e t h e r .

T h A n a t o m y b o o k a p p e a r s t h a v e b e e n o G e r m a n o r i g i n a n i a l s o c o p y r i g h t e d b D a t a B e c k e r G m b H i D u s s e l d o r f . L i k e t h e a r l i e r A n a t o m y o t h C o m m o d o r e 6 4 i h a b e e n t r a n s l a t e d a n p u b l i s h e d b A b a c u s . T h b o o k h a n o b e e n t y p e s e t , b u h a b e e np r e p a r e d o l e t t e r - q u a l i t y p r i n t e r . O i t t o t a l c o n t e n t , 1 5 1 p a g e sp r e s e n t d i s a s s e m b l y o t h 1 6 R O i n s i d e t h e d r i v e . T h i si n c l u d e s t h e 9 0 1 2 2 9 - 0 3 R O M , t h " o r i g i n a l " d i s k R O M . T h d i s a s s e m b l y i n i c e l y l a i d o u t , w i t h a s t e r i s k s a n s p a c e s s e t t i n g o f t h b l o c k s o c o d e . T h b o o k c o v e r i n d i c a t e s t h a t t h l i s t i n g i " f u l l y c o m m e n t e d " , a n t h i s i t r u e o 8 0 o t h d i s a s s e m b l y .l a r g e b l o c k o c o d e i d e v o i d o c o m m e n t s . T h e c o m m e n t s a r h e l p f u l , b u d n o r e a l l y f u l l y e x p l a i n t h e a c t i v i t y .

T h I n s i d e b o o k a p p e a r s t b e a n o u t g r o w t h o e a r l i e r w o r k o t h C o m m o d o r e d u a l d r i v e s . u n d e r s t a n d t h a t o n o t h e a u t h o r s ,D i c k I m m e r s , d i h i P h . D . t h e s i s o t h s u b j e c t . L i k e t h o t h e r ,l a r g e p r o p o r t i o n o t h b o o k d e a l s w i t h t h 1 6 o R O M . H e r e w h a v e 2 0 p a g e s d e s c r i b i n g t h R O M . H o w e v e r , w a r e n o t g i v e nt h a c t u a l c o d e , b u t i n s t e a d a r e t o l d w h a t p u r p o s e e a c h s u b r o u t i n ef u l f i l l s . R e f e r e n c e i m a d e t R A l o c a t i o n s a n t h e i r p u r p o s e ,t h e r e b y g i v i n g a m u c h b e t t e r s e n s e o w h a t i h a p p e n i n g . T h i s p a r to t h b o o k i n o t y p e s e t , w h i c h ( t m e m e a n s t h e r e w o n ' t b a n t y p o s t h a t t h p r i n t e r i n t r o d u c e d . A l s o , t h e a u t h o r s s u g g e s t s y b o l i c l a b e l s f o t h v a r i o u s r o u t i n e s , h a n d y t o u c h . T h d o c u m e nt a t i o n i a l s o t h a t o f t h e a r l i e r R O M , b u t h t e x t i d e n t i f i e s t h f e c h a n g e s m a d e f o t h 9 0 1 2 2 9 - 0 5 R O M .

T m a n y , t h a b o v e c o n t e n t w o u l d b t h r e a s o n t b u t h b o o k s .W s h o u l d e x a m i n e w h a t o t h e r t o p i c s a r c o v e r e d i e a c h :

A n a t o m y g i v e s a r e v i e w o t h d i s k c o m m a n d s , t s u p p l e m e n tt h e i n f o r m a t i o n i t h ( t e r r i b l e ) C o m m o d o r e m a n u a l . T d e v e l o pf a m i l i a r i t y w i t h s e q u e n t i a l f i l e s , B A S I C m a i l l i s t p r o g r a m i d e v e l o p e d a n e x p l a i n e d . T h c o n c e p t s o r e l a t i v e a c c e s s a r ee x p l a i n e d a n B A S I C h o m e a c c o u n t i n g p r o g r a m s e r v e s t a p p l yt h e t e c h n i q u e s . C h a p t e r d o c u m e n t s t h s y n t a x a n p u r p o s e o t h e d i r e c t - a c c e s s c o m m a n d s . B r i e f e x a m p l e p r o g r a m s d e m o ns t r a t e t h e i r u s e . T h t e c h n i c a l i n f o r m a t i o n i C h a p t e r s h o w sb l o c k d i a g r a m o m e m o r y a l l o c a t i o n a n g i v e s t h e p u r p o s e o t h l o m e m o r y " v a r i a b l e " l o c a t i o n s . b r i e f p i c t u r e o h o t h d a t a i o r g a n i z e d o t h e d i s k s u r f a c e g i v e s h e x a d e c i m a l d u m p s o s e v e r a l" t y p e s " o d i s k s e c t o r s . C h a p t e r 4 g i v e s q u i t e n u m b e r o h e l p f u lu t i l i t i e s f o d e a l i n g w i t h t h d i s k d r i v e . M a n y a r i m a c h i n el a n g u a g e , a n t h a s s e m b l e r s o u r c e c o d e i s u p p l i e d . T h m o s ts o p h i s t i c a t e d o t h e s e i " d i s k m o n i t o r " w h i c h a l l o w s y o t r e a d ,d i s p l a y , e d i t a n w r i t e a s e c t o r d i r e c t l y .

I n s i d e g i v e s t h o r o u g h d e s c r i p t i o n o t h p r i n c i p a l D O c o r n -

I n s i d e C o m m o d o r e D O R i c h a r d I m m e r s G e r a l d N e u f e l dD a t a m o s t I n c .2 0 6 6 0 N o r d h o f f S t r e e tC h a t s w o r t h , C 9 1 3 1 1 - 6 1 5 21 9 8 4 , 5 0 p a g e s$ 1 9 . 9 5 ( U . S . )a d v a n c e d , m a c h i n e l a n g u a g e

m a n d s . C h a p t e r s a n d e t a i l t h e o r g a n i z a t i o n o t h d a t a o t h d i s k . M o r e t h a n 4 p a g e s a r d e v o t e d t p r e s e n t i n g d i a g r a m s o t h d a t a o t h s e c t o r s w h e r e B A M , d i r e c t o r y , p r o g r a m a n d a l t y p e s o f i l e e n t r i e s a r e r e c o r d e d . C h a p t e r i n t r o d u c e s t h e d i r e c t - a c c e s sc o m m a n d s . T h e x a m p l e p r o g r a m s a r e e x t e n s i v e , a n f u l l y e p l a i n e d . S o m e c o u l d q u a l i f y a s f u l l - f l e d g e d u t i l i t y p r o g r a m s i t h e i r o w r i g h t . C h a p t e r i r e a l l y m e a t y — h o w t h e f l o p p y d i s kc o n t r o l l e r a c t u a l l y e x e c u t e s D O c o m m a n d . T h i s i p r e f a c e t C h a p t e r 7 w h e r e w l e a r n t h e n c o d i n g s c h e m e f o t h d a t aw r i t t e n o t h d i s k . T h a u t h o r s p r e s e n t t h i r t e e n p r o g r a m s t h a tp e r m i t y o t d u p l i c a t e D O S - p r o t e c t e d d i s k e t t e s . E r r o r - w r i t i n gs c h e m e s a r g i v e n f o a l t h k n o w n m e t h o d s o c o p y - p r o t e c t i o n .T h a s s e m b l e r s o u r c e c o d e f o t h M p o r t i o n s i g i v e n . T h e s ep r o g r a m s r e a l l y s h o w y o h o t h e d i s k w o r k s . C h a p t e r 8 h a s v e r yw e l c o m e a d v i c e o r e c o v e r y f r o m t r o u b l e . n u m b e r o u t i l i t yp r o g r a m s i s u p p l i e d . c o m p r e h e n s i v e o v e r v i e w o t h 1 5 4 1 D O i g i v e n i C h a p t e r 9 T h m a j o r r o u t i n e s o b o t h t h F l o p p y D i s kC o n t r o l l e r a n t h I n t e r f a c e P r o c e s s o r a r i d e n t i f i e d , a n h o t u s t h e m . D e t a i l s o t h t i m i n g o t h r e a d a n w r i t e c y c l e s a r ee x p l a i n e d . T h c h a p t e r c o n c l u d e s w i t h a d i s c u s s i o n o D O b u g s ,b o t h r e a l a n i m a g i n e d , a n s o m e o p i n i o n s o t h " w r i t e -i n c o m p a t i b i l i t y " o t h e 1 5 4 1 a n t h 4 0 4 0 t y p e d r i v e s .

r e a l l y l i k e d t h A n a t o m y ' s d i s c u s s i o n o r e l a t i v e a n s e q u e n t i a lf i l e s . T h e x a m p l e p r o g r a m s a r e q u i t e u s e f u l a n i n s t r u c t q u i t ew e l l . A b a c u s u n c o v e r e d a " M m o d e f o r e a d i n g a u n c l o s e d f i l e ,a n a l s o f o u n d w a t " s c r a t c h - p r o t e c t " f i l e s . T h e s e h a v e b e e nd e e p , d a r k s e c r e t s u n k n o w n t a l m o s t a l u s e r s . T h l a c k o m o r ed e t a i l e d a n a l y s i s o t h R O M s i c o m p a r a t i v e s h o r t c o m i n g .( H o w e v e r , f o l o n g t i m e , n o o n e h a d o c u m e n t e d a m u c h a t h e y h a d . )

T h I n s i d e b o o k i r e m a r k a b l e p i e c e o s c h o l a r s h i p . I r a n k sr i g h t a l o n g s i d e R a e t o W e s t ' s P r o g r a m m i n g t h P E T / C B M i i t c o m p r e h e n s i v e t r e a t m e n t o t h t o p i c . f i n d t h a t t h e d e s c r i p t i o n o t h R O M s i m o r e u s e f u l t h a n t h a c t u a l c o d e , p a r t i c u l a r l y g i v e nt h q u a l i t y o t h e i n f o r m a t i o n . T h b o o k i h i g h l y c o n t r o v e r s i a l i i t t r e a t m e n t o b a c k i n g - u p o c o p y - p r o t e c t e d d i s k s . O n e x p e r ts u g g e s t s t h a t t h l e v e l o c o p y - p r o t e c t i o n u s e d w i t h C o m m o d o r ef o r m a t d i s k s i p r e t t y u n s o p h i s t i c a t e d a p r e s e n t a n y w a y . A f t e rs t a t i n g t h a t I ' n e v e r b u s o f t w a r e t h a t c o u l d n ' t b a c k - u p , h a v es c a d o s u c h d i s k s n o w . I m v i e w , i t ' s n o i m p r o p e r t w a n tc o p y o n - h a n d , r a t h e r t h a n w a i t i n g w e e k s f o r t h a t r e p l a c e m e n t t a r r i v e f r o m t h m a n u f a c t u r e r . T h 4 u t i l i t y p r o g r a m s a r e a r e a lb o o n . T h w e a l t h o i n f o r m a t i o n i t h i s b o o k m a k e s i v e r y e a s y t r e c o m m e n d t t h a d v a n c e d u s e r . T h b o o k i w e l l - w r i t t e n , a n t r e a t s e a c h t o p i c t h o r o u g h l y . M o r e o v e r , t h l a n g u a g e i p l a i nE n g l i s h a n q u i t e r e a d a b l e .

h a v e p u r c h a s e d b o t h b o o k s . T h A n a t o m y o t h 1 5 4 1p r e d a t e s t h e o t h e r , b u d n o r e g r e t h a v i n g i n v e s t e d i i t B o t hb o o k s a r r e c o m m e n d e d t y o u , b u i y o u c h o o s e t b u o n l y o n e ,t h e n I n s i d e C o m m o d o r e D O s h o u l d b e t h e c h o i c e .

T h T 2 V o l u m e 5 I s s u e 0

Page 23: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 23/88

M a c h i n e L a n g u a g e F o T h C o m m o d o r e 6 A n O t h e r C o m m o d o r e C o m p u t e r s :

R e v i e wb D a v i d A H o o k

B a r r i e , O n t a r i o

A u t h o r J i B u t t e r f i e l dP u b l i s h e r B r a d y C o m m u n i c a t i o n s C o . , I n c .

P r e n t i c e - H a l l P u b l i s h i n g C o .B O W I E , M 2 0 7 1 5 , U . S . A 1 9 8 4 , 3 2 p a g e s

P r i c e $ 1 2 . 9 5 U ( $ 1 7 . 9 5 C a n a d i a n )A u d i e n c e B e g i n n e r , m a c h i n e l a n g u a g e p r o g r a m m i n g

B e g i n n e r s w h w i s h t v e n t u r e i n t o t h w o r l d o 6 5 0 2 ( 6 5 1 0 )m a c h i n e l a n g u a g e h a v e m a n y m o r e c h o i c e s n o w a d a y s . W v e e r a n s o P E T d o m h a v e w a d e d t h r o u g h s o m e p r e t t y m u d d y w a t e r st l e a r n s o m e o t h t r i c k s . T h e r e i s w a r m o b o o k s o t h s u b j e c t t o d a y , b u i t ' s h a r d t f i n d s i n g l e o n t h a t a d m i t s t h a t t h m i c r o p r o c e s s o r d o e s n o o p e r a t e i v o i d . T h c h i p l i v e s i n s i d er e a l c o m p u t e r , a n t h a t m e a n s t h e n v i r o n m e n t m u s t b c o n s i de r e d w h e n y o a r t a l k i n g a b o u t r e a l m a c h i n e l a n g u a g e p r g r a m . A e a r l i e r t e x t i t h L e v a n t h a l b o o k ( 1 ) . T h e x a m p l e s t h e r ec a u s e d t h P E t r u a w a y a n d h i d e — t h e p r o g r a m s h a b e e np l a c e d i v e r y s e n s i t i v e a r e a o m e m o r y !

T h e r e i a n o t h e r m a j o r f a c t o r . t e l e v i s i o n g a m e s h o w c a l l e dJ e o p a r d y ( r e v i v e d a f t e r e i g h t y e a r s ) , p r o v i d e s t h " a n s w e r " , w h i l ea s k i n g c o n t e s t a n t s t p r o v i d e t h e " q u e s t i o n " . L e t ' s p l a y :

T h A n s w e r : J i m B u t t e r f i e l dT h Q u e s t i o n : W h a t i m i s s i n g f r o m a l o t h e r b o o k s o m a c h i n e

l a n g u a g e p r o g r a m m i n g ?

M r B u t t e r f i e l d i r e c o g n i z e d a t h w o r l d ' s f o r e m o s t a u t h o r i t y o C o m m o d o r e c o m p u t e r s . F e p e o p l e h a v e n o b e e n t o u c h e d b h i w o r k a w r i t e r , a n a A s s o c i a t e E d i t o r o C O M P U T E ! s i n c e i t i n c e p t i o n . W i t h T o r o n t o a r e a h a v e b e e n p a r t i c u l a r l y b l e s s e d ,s i n c e w h a v e s e e n J i p e r f o r m a t e a c h e r . H i s t a l e n t i i m p r e s s i v e — h e h a k n a c k o e x p l a i n i n g t h m o s t d i f f i c u l t c o c e p t s i s i m p l e a n e n t e r t a i n i n g w a y . T h b o o k i w r i t t e n i t h i sl i g h t c o n v e r s a t i o n a l s t y l e .

T h m i c r o p r o c e s s o r i t h C o m m o d o r e 6 i t h 6 5 1 0 , w h i c h h a t h s a m e s e t o f i n s t r u c t i o n s a s t h M O S T e c h n o l o g y 6 5 0 2 . J i B u t t e r f i e l d c o - a u t h o r e d b o o k o m a c h i n e l a n g u a g e p r o g r a m s f o t h 6 5 0 2 ( 2 w a b a c k i 1 9 7 8 .

T h c o m b i n a t i o n o J i m ' s w r i t i n g s k i l l a n h i p r a c t i c a l a p p r o a c ht t h t o p i c a r u n b e a t a b l e . T h b e s t e x p r e s s i o n o t h t h e m e o t h b o o k i t h a t s t a t e d b t h a u t h o r i t h P r e f a c e . P r o g r a m m e r s l e a r nb d o i n g , s o g i v e l o t s o e x a m p l e s a n p r o j e c t s f o t h e m t d o T

M a c h i n e * l a n g u a g e

J i B u t t e r l k ' k l

e n t e r a n u s t h e x a m p l e s , y o u m u s t h a v e s o m e t o o l s t h a t a r m a c h i n e - s p e c i f i c . A l t h o u g h t h e s e h a v e a l m o s t n o t h i n g t d w i t ht h m a c h i n e l a n g u a g e , y o a r e h e l p l e s s w i t h o u t t h e m . S J i p r o v i d e s t h t o o l s a n t e l l s y o h o t u s e t h e m . A l s o , y o u m u s tu n d e r s t a n d t h e a r c h i t e c t u r e o t h c o m p u t e r — y o u r p r o g r a m s h a v et f i s o m e w h e r e i m e m o r y a n d y o u n e e d t k n o w h o w t p e r f o r mi n p u t a n o u t p u t o p e r a t i o n s .

H h a s t u c k t t h o s e p r i n c i p l e s t h r o u g h o u t t h b o o k , a n t h e r e i a e x c e l l e n t r e a s o n f o t h i s . M o r e t h a n f i v e y e a r s a g o , J i s t a r t e dc o u r s e i m a c h i n e l a n g u a g e f o b e g i n n e r s . O v e r t h a t p e r i o d i h a b e e n r e f i n e d , a n n o e x i s t s a t w o - d a y i n t e n s i v e p r o g r a m . J i h a t a k e n h i s h o w o t h r o a d , a n t h o u s a n d s o p e o p l e h a v ep a r t i c i p a t e d i h i s e m i n a r s — a l l o v e r t h e w o r l d . W i t h t h a t b a c kg r o u n d , i t ' s e a s y t u n d e r s t a n d w h t h b o o k i w e l l - o r g a n i z e da n u n i f i e d i t h e m e .

T h b o o k i d i v i d e d i n t o e i g h t l e s s o n s w i t h r e f e r e n c e s e c t i o n t h a tr e p r e s e n t s m o r e t h a n h a l f t h t o t a l p a g e s . W e ' l l d i s c u s s t h a t p a r tl a t e r .

C h a p t e r d i s c u s s e s t h e f i r s t c o n c e p t s . W m e e t t h m i c r o p r o c e ss o r , t h a d d r e s s a n d a t a b u s s e s , c o v e r b i n a r y a n h e x a d e c i m a ln o t a t i o n , a n t h i n t e r n a l r e g i s t e r s . O t h p r a c t i c a l s i d e , w l e a r na b o u t m a c h i n e l a n g u a g e m o n i t o r ( M L M ) . T h M L M s f o C o m m od o r e h a v e c o m m o n s e o c o m m a n d s , s t h e s e a r e e x p l a i n e d .

T h T r a n s a c t o r 2 V o l u m e 5 I s s u e 0

Page 24: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 24/88

Page 25: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 25/88

C o m m d o r e 1 6 / P l u s - 4M e m o r y M a p s

J i B u t t e r f i e l dT o r o n t o , O n t .

I ' h a p p y t s e t h a t C o m m o d o r e h a v e ( t h i n k f o t h f i r s t t i m e )m a d e a e a r l y p u b l i c a t i o n o f " o f f i c i a l " R A m e m o r y m a p s f o t h e i rn e m a c h i n e s . Y o c a f i n d t h e m i t h N o v e m b e r / D e c e m b e r1 9 8 4 i s s u e s o " C o m m o d o r e M i c r o c o m p u t e r s " m a g a z i n e , a n t h e yi n c l u d e s o m e t h i n g q u i t e v a l u a b l e : C o m m o d o r e ' s i n t e r n a l " l a b e l s "b w h i c h t h e y i d e n t i f y t h l o c a t i o n s . W i t h t h e s e l a b e l s , a a s s e mb l l a n g u a g e p r o g r a m m e r c a n o u s e s t a n d a r d i d e n t i f i e r s i nw r i t i n g a p r o g r a m I ' l l c e r t a i n l y t r y t o d s o

I ' v e b e e n p i c k i n g a p a r t t h e l o g i c o t h m a c h i n e s , a n I ' l i k e t oo f f e r m m a p s , t o o . T h e y a r s i m i l a r i w o r d i n g t p r e v i o u s m a p sI ' v e p u b l i s h e d .

f e t h i n g s t h a t a r e n o t i c e a b l e a b o u t t h n e m a c h i n e s . T h e yh a v e n e a r c h i t e c t u r e w h i c h c a l l s f o r y o t r e a d t h m a m o r ec a r e f u l l y .

C o m m o d o r e P l u s / 4 S e r i e s

( n o t d r a w n t s c a l e )

D i a g r a m c o u r t e s y o C o p p C l a r k P u b l i s h i n g

S i n c e R A l i e s p a r t l y b e n e a t h t h R O o R O M s a b o v e , w m u s tu n d e r s t a n d t h a t a a d d r e s s m i g h t r e f e r t a n o s e v e r a l " l e v e l s " .F o e x a m p l e : P R I N T P E E K ( 3 2 7 6 8 ) w i l l g i v e y o v a l u e f r o m R A a t h a t l o c a t i o n ; b u i y o s w i t c h t t h m o n i t o r a n d i s p l a y t h c o n t e n t s o h e 8 0 0 0 , y o u ' l l s e t h R O a n g e q u i t e d i f f e r e n tv a l u e . F o m o s t a p p l i c a t i o n s ( a n d f o m e m o r y l o c a t i o n s b e l o w3 2 7 6 8 ) , y o w o n ' t n e e d t w o r r y a b o u t a l t h i s . B u w h e n y o g e i n t o t h a d v a n c e d s t u f f , y o u ' l l n e e d t k n o w h o w t w o r k a l t h p i c k y d e t a i l s .

F e D i f f e r e n c e s

I n n e r s p a c e e n g i n e e r s w i l l n o t i c e t h a t m u c h o z e r o p a g e l o o k sv e r y m u c h l i k e t h a t o f t h C o m m o d o r e 6 4 T h f i r s t b i s u r p r i s e i

p r o b a b l y t h C H R G E T r o u t i n e : i t ' s m i s s i n g f r o m z e r o p a g e . I t u r n so u t h a t C H R G E T ( w h i c h h a r e l o c a t e d t p a g e 4 n e e d s t b u s e di m o r e c o m p l e x w a y , s i n c e t h e c a l l i n g r o u t i n e s m u s t s p e c i f y i t h e y a r l o o k i n g f o i n f o r m a t i o n f r o m R O o R A M .

A n w o n d e r o w o n d e r s : T h e r e ' s a w h o l e b l o c k o s p a r e m e m o r yi z e r o p a g e , f r o m a l e a s t $ D t $ E 8 . I t ' s e n o u g h t d i s o r i e n tp r o g r a m m e r .

E x t r a s p a c e i p u t v a r i e t y o u s e s . P a g e i s s t i l l m o s t l y t h s y s t e m s t a c k ( s e e t h n o t e a b o u t t h e B a s i c s t a c k , b e l o w ) . P a g e i i n p u t a r e a s a s b e f o r e , w i t h s p a c e f o w o r k i n g t h n e D O c o m m a n d s . P a g e 3 c o n t a i n s l i n k s a n v e c t o r s s i m i l a r t t h o s e o t h 6 4 w a t c h t h e s e c l o s e l y , s i n c e t h e a b s e n c e o a N M s h o r t e n su t h t a b l e b o n a d d r e s s .

P a g e c o n t a i n s s o m e c o m m u n i c a t i o n s b u f f e r i n g , a n s o m e r p l a c e m e n t s f o t h m i s s i n g C H R G E T r o u t i n e . T h e r e ' s a l s o w o r ka r e a f o P R I N T U S I N G a n o t h e r a c t i v i t i e s . T h c u r r e n t d e f i n i t i o n so t h p r o g r a m m a b l e f u n c t i o n k e y s t a k e u m u c h o p a g e 5 a n p a g e s e e m s t b l a r g e l y r e s e r v e d f o s y s t e m e x p a n s i o n , s u c h a s p e e c h s y n t h e s i s .

T h e r e ' s n e s t a c k m o s t l y i p a g e 7 t h e B a s i c s t a c k , w h i c h h o l d sl o o p a n s u b r o u t i n e t y p e i n f o r m a t i o n . F O R / N E X T , G O S U B /R E T U R N , a n D O / L O O P w i t h i t W H I L E a n U N T I L p r o v i s i o n s . I l e t s y o w r i t e s o m e w h a t m o r e c o m p l e x p r o g r a m s , a n l e a v e s t h m a c h i n e s t a c k l e s s c l u t t e r e d .

T h s c r e e n i n o a c c o m p a n i e d b a s u c e s s o r t t h " c o l o rn y b b l e " t a b l e ; i t ' s c a l l e d t h " a t t r i b u t e " t a b l e . I t ' s l i k e t h e c o l o rn y b b l e s , b u t c o n t a i n s e x t r a i n f o r m a t i o n : n o t j u s t c o l o r , b u h u a w e l l , a n a l s o " f l a s h " b i t . I t ' s i m a i n m e m o r y n o w , r e s i d i n g a h e x 0 8 0 0 ( d e c i m a l 2 0 4 8 ) , w i t h t h s c r e e n f o l l o w i n g i a h e 0 C 0 0( d e c i m a l 3 0 7 2 ) . T h e x t r a s p a c e m e a n s t h a t B a s i c s t a r t s h i g h e rt h a n b e f o r e , a h e 1 0 0 0 o d e c i m a l 4 0 9 6 .

T h R O s y s t e m i q u i t e m a s s i v e . A t 3 2 K , m a e n d s u p l e n g t h ye v e n i i t ' s a b r i d g e d . f e s u r p r i s e s i n c l u d e : b u i l t - i n m a c h i n el a n g u a g e m o n i t o r ; g r a p h i c s , e r r o r t r a p p i n g a n d i s k c o m m a n d sb u i l t i n t o B a s i c ; a n a c l e v e r m e a n s o f i n t e r n a l l y c a t a l o g i n g a l t h R O M s t h a t h a p p e n t b f i t t e d a n d m a k i n g t h e m a v a i l a b l e a sd e s i r e d .

T h e s a m e o l K e r n a l r o u t i n e s a r e s t i l l t h e r e a n d t h s a m e j o b ,b u t h e r e ' s n e s t u f f , i n c l u d i n g a " u n o f f i c i a l J u m p T a b l e " t h a n d l e s o m e c l e v e r b a n k s w i t c h i n g t a s k s .

I l o o k s l i k e l o o f u n . G o o d h u n t i n g

T h T r a n s a c t o r 2 V o l u m e 5 I s s u e 0

Page 26: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 26/88

C o m m o d o r e 1 P l u s R A M e m o r y M a ( P r e l i m i n a r y : S e p t e m b e r 2 5 / 8 4 . N o t e t h a t t h e p r e v i o u s l y a v a i l a b l e l o c a t i o n s f o V I C / C 6 4 , S O O F C t $ 0 0 F F , a r n o u s e d a n a r e n o t a v a i l a b l e .

H e 0 0 0 00 0 0 10 0 0 20 0 0 3 - 0 0 0 60 0 0 70 0 0 80 0 0 90 0 0 A0 0 0 Bo o o c0 0 0 DO O O E0 0 0 F0 0 1 00 0 1 10 0 1 20 0 1 30 0 1 4 - 0 0 1 50 0 1 60 0 1 7 - 0 0 1 80 0 1 9 - 0 0 2 10 0 2 2 - 0 0 2 50 0 2 6 - 0 0 2 A0 0 2 B - 0 0 2 C0 0 2 D - 0 0 2 E0 0 2 F - 0 0 3 00 0 3 1 - 0 0 3 20 0 3 3 - 0 0 3 40 0 3 5 - 0 0 3 60 0 3 7 - 0 0 3 80 0 3 9 - 0 0 3 A0 0 3 B - 0 0 3 C0 0 3 D - 0 0 3 E0 0 3 F - 0 0 4 00 0 4 1 - 0 0 4 20 0 4 3 - 0 0 4 40 0 4 5 - 0 0 4 60 0 4 7 - 0 0 4 80 0 4 9 - 0 0 4 A0 0 4 B - 0 0 4 C0 0 4 D0 0 4 E - 0 0 5 30 0 5 4 - 0 0 5 60 0 5 7 - 0 0 6 00 0 6 10 0 6 2 - 0 0 6 50 0 6 60 0 6 70 0 6 80 0 6 9 - 0 0 6 E0 0 6 F0 0 7 00 0 7 1 - 0 0 7 20 0 7 3 - 0 0 7 40 0 7 50 0 7 6 - 0 0 7 90 0 7 C - 0 0 7 D0 0 7 E - 0 0 8 F0 0 9 00 0 ! )0 0 9 40 0 9 50 0 9 60 0 9 70 0 9 80 0 9 90 0 9 A0 0 9 B - 0 0 9 C0 0 9 D - 0 0 9 E0 0 9 F - 0 0 A 00 0 A 1 - 0 0 A 20 0 A 3 - 0 0 A 50 0 A 60 0 A 70 0 A 80 0 A 90 0 A AO O A B0 0 A C0 0 A DO O A E0 0 A F - 0 0 B 0O 0 B 1O O B 2 - O O B 3O O B 3 - O O B 4

D e c i m a l

3 -

1 1 1 1 1 1 1 1 1 1 2 0 - 2 12 2 3 - 2 42 5 - 3 33 4 - 3 73 8 - 4 24 3 - 4 44 5 - 4 64 7 - 4 84 9 - 5 05 1 - 5 25 3 - 5 45 5 - 5 65 7 - 5 85 9 - 6 06 1 - 6 26 3 - 6 46 5 - 6 66 7 - 6 86 9 - 7 07 1 - 7 27 3 - 7 47 5 - 7 67 7 8 - 8 38 4 - 8 68 7 - 9 69 9 8 - 1 0 1

1 0 1 0 1 0 1 0 5 - 1 1 01 1 1 1 1 1 3 - 1 1 41 1 5 - 1 1 61 1 1 1 8 - 1 2 31 2 4 - 1 2 51 2 6 - 1 4 31 4 1 4 1 4 1 4 1 5 1 5 1 5 1 5 1 5 1 5 5 - 1 5 61 5 7 - 1 5 81 5 9 - 1 6 01 6 0 - 1 6 11 6 3 - 1 6 51 6 1 6 1 6 1 6 1 7 1 7 1 7 1 7 1 7 1 7 5 - 1 7 61 7 1 7 8 - 1 7 91 8 0 - 1 8 1

D e s c r i p l i o nC h i p d i r e c t i o n a l r e g i s t e r 0 0 B 6 - 0 0 B 7 1 8 2 - 1 8 3C h i p I / O ; s e r i a l b u s / c a s s e t t e 0 0 B 8 - 0 0 B 9 1 8 4 - 1 8 5L o o p t y p e m a t c h 0 0 B A - 0 0 B B 1 8 6 - 1 8 7R e n u m b e r p a r a m e t e r s 0 0 B C - 0 0 C 1 1 8 8 - 1 9 3S e a r c h c h a r a c t e r 0 0 C 2 1 9 S c a n - q u o t e s f l a g 0 0 C 3 1 9 T A c o l u m n s a v e O O C 4 - 0 O C 5 1 9 6 - 1 9 7

= L O A D , 1 = V E R I F Y 0 0 C 6 1 9 I n p u t b u f f e r p o i n t e r / * o s u b s c r i p t s 0 0 C 7 1 9 D e f a u l t D I f l a g 0 0 C 8 - 0 O C 9 2 0 0 - 2 0 1T y p e : F F = s t r i n g ; O O = n u m e r i c O O C A 2 0 T y p e : 8 0 = i n t e g e r ; 0 0 f l o a t i n g p o i n t O O C B 2 0 D A T A s c a n / L I S T q u o l e / m e m o r y f l a g O O C C 2 0 S u b s c r i p t / F N x f l a g O O C D 2 0 0 = . | N P U T ; $ 4 0 = G E T ; $ 9 8 = R E A D O O C E 2 0 A T s i g n / C o m p a r i s o n e v a l u a t i o n f l a g O O C F 2 0 C u r r e n t I / p r o m p t f l a g 0 0 D 0 - 0 0 D 7 2 0 8 - 2 1 5I n t e g e r v a l u e 0 0 D 8 - 0 0 E 8 2 1 6 - 2 3 2P o i n t e r : t e m p o r a r y s t r i n g s l a c k 0 0 E 9 2 3 L a s t t e m p o r a r y s t r i n g v e c t o r O 0 E A - 0 O E B 2 3 4 - 2 3 5S t a c k f o t e m p o r a r y s t r i n g s O O E C - O O E E 2 3 6 - 2 3 8U t i l i t y p o i n t e r a r e a O O E F 2 3 P r o d u c t a r e a f o m u l t i p l i c a t i o n 0 0 F 0 2 4 P o i n t e r : S t a r t - o f - B A S I C 0 0 F 1 - F 4 2 4 1 - 2 4 4P o i n t e r : S t a r t - o f - v a r i a b l e s 0 0 F 5 2 4 P o i n t e r : S t a r t - o f - a r r a y s 0 O F 6 2 4 P o i n t e r : E n d - o f - a r r a y s 0 0 F 7 - 0 0 F 8 2 4 7 - 2 4 8P o i n t e r : S t r i n g - s t o r a g e ( m o v i n g d o w n ) 0 0 F 9 2 4 U t i l i t y s i r i n g p o i n t e r O O F A 2 5 P o i n t e r : L i m i t - o f - M e m o r y O O F B 2 5 C u r r e n t B A S I C l i n e n u m b e r 0 1 0 0 - O I F F 2 5 6 - 5 1 1T e x t p o i n t e r : B A S I C w o r k p o i n t 0 2 0 0 - 0 2 5 8 5 1 2 - 6 0 0P o i n t e r : B A S I C s t a c k f o C O N T O 2 5 9 - O 2 5 A 6 0 1 - 6 0 2C u r r e n t D A T A l i n e n u m b e r 0 2 5 B - 0 2 5 C 6 0 3 - 6 0 4C u r r e n t D A T A a d d r e s s 0 2 5 D - 0 2 A C 6 0 5 - 6 8 4I n p u t v e c t o r 0 2 A D - 0 2 B 0 6 8 5 - 6 8 8C u r r e n t v a r i a b l e n a m e 0 2 B 1 - 0 2 B 4 6 8 9 - 6 9 2C u r r e n t v a r i a b l e a d d r e s s O 2 B 5 - O 2 C B 6 9 3 - 7 1 5V a r i a b l e p o i n t e r f o F O R / N E X T 0 2 C C - 0 2 E 8 7 1 6 - 7 4 4Y - s a v e ; o p - s a v e ; B A S I C p o i n t e r s a v e 0 2 E 9 7 4 C o m p a r i s o n s y m b o l a c c u m u l a t o r 0 2 E A 7 4 M i s c . w o r k a r e a , p o i n t e r s , a n s o 0 2 E B 7 4 J u m p v e c t o r f o f u n c t i o n s 0 2 E C - 0 2 E E 7 4 8 - 7 5 0M i s c e l l a n e o u s n u m e r i c w o r k a r e a 0 2 E F 7 5 A c c u m ' l : e x p o n e n t 0 2 F 0 7 5 A c c u m ' l : m a n t i s s a 0 2 F 1 7 5 3A c c u m * l : s i g n 0 2 F 2 - 0 2 F 3 7 5 4 - 7 5 5S e r i e s e v a l u a t i o n c o n s t a n t p o i n t e r 0 2 F 4 - 0 2 F 5 7 5 6 - 7 5 7A c c u m ' l h i - o r d e r ( o v e r f l o w ) 0 2 F 6 - 0 2 F D 7 5 8 - 7 6 5A c c u m ' 2 : e x p o n e n t , a n s o O 2 F E - O 2 F F 7 6 6 - 7 6 7S i g n c o m p a r i s o n , A c c ' l v e r s u s " 2 0 3 0 0 - 0 3 0 1 7 6 8 - 7 6 9A c c u m ' l l o - o r d e r ( r o u n d i n g ) 0 3 0 2 - 0 3 0 3 7 7 0 - 7 7 1C a s s e t t e b u f f e r l e n / S e r i e s p o i n t e r 0 3 0 4 - 0 3 0 5 7 7 2 - 7 7 3A u t o l i n e n u m b e r i n c r e m e n t 0 3 0 6 - 0 3 0 7 7 7 4 - 7 7 5G r a p h i c s f l a g 0 3 0 8 - 0 3 0 9 7 7 6 - 7 7 7M i s c w o r k v a l u e s 0 3 0 A - 0 3 0 B 7 7 8 - 7 7 9B A S I C p s e u d o - s t a c k p o i n t e r 0 3 0 C - 0 3 0 D 7 8 0 - 7 8 1M i s c w o r k v a l u e s 0 3 0 E - 0 3 0 F 7 8 2 - 7 8 3S t a t u s w o r d S 0 3 1 0 - 0 3 1 1 7 8 4 - 7 8 5K e y s w i t c h I A S T O P a n R V f l a g s 0 3 1 2 - 0 3 1 3 7 8 6 - 7 8 7S e r i a l o u t p u t : d e f e r r e d c h a r a c t e r f l a g 0 3 1 4 - 0 3 1 5 7 8 8 - 7 8 9S e r i a l d e f e r r e d c h a r a c t e r 0 3 1 6 - 0 3 1 7 7 9 0 - 7 9 1R e g i s t e r s a v e 0 3 1 8 - 0 3 1 9 7 9 2 - 7 9 3H o m a n y o p e n f i l e s 0 3 1 A - 0 3 1 B 7 9 4 - 7 9 5I n p u t d e v i c e , n o r m a l l y 0 O 3 1 C - O 3 1 D 7 9 6 - 7 9 7O u t p u t C M d e v i c e , n o r m a l l y 3 O 3 1 E - O 3 1 F 7 9 8 - 7 9 9D i r e c t $ 8 0 / R U N o u t p u t c o n t r o l 0 3 2 0 - 0 3 2 1 8 0 0 - 8 0 1P o i n t e r : t a p e b u f f e r , s c r o l l i n g 0 3 2 2 - 0 3 2 3 8 0 2 - 8 0 3E n o p r o g r a m p o i n t e r 0 3 2 4 - 0 3 2 5 8 0 4 - 8 0 5W o r k a r e a 0 3 2 6 - 0 3 2 7 8 0 6 - 8 0 7M o n i t o r w o r k i n g v e c t o r 0 3 2 8 - 0 3 2 9 8 0 8 - 8 0 9J i f f y C l o c k H M 0 3 2 A - 0 3 2 B 8 1 0 - 8 1 1S e r i a l b i c o u n t / E O I f l a g 0 3 2 C - 0 3 2 D 8 1 2 - 8 1 3T a p e s h i f t b y t e 0 3 2 E - 0 3 2 F 8 1 4 - 8 1 5 'S e r i a l c y c l e c o u n t 0 3 3 0 - 0 3 3 1 8 1 6 - 8 1 7T e m p o r a r y c o l o r v e c t o r 0 3 3 2 - 0 3 F 2 8 1 8 - 1 0 1 0C o u n t d o w n , t a p e w r i t e / b i t c o u n t 0 3 F 3 - 0 3 F 6 1 0 1 1 - 1 0 1 4N u m b e r o c h a r a c t e r s i f i l e n a m e 0 3 F 7 - 0 4 3 6 1 0 1 5 - 1 0 7 8C u r r e n t l o g i c a l f i l e 0 4 3 7 - 0 4 7 2 1 0 7 9 - 1 1 3 8C u r r e n t s e c o n d a r y a d d r e s s 0 4 7 3 1 1 3 9C u r r e n t d e v i c e 0 4 7 9 1 1 4 5P o i n t e r t f i l e n a m e 0 4 9 4 1 1 7 2T a p e e r r o r c o u n t 0 4 A 5 1 1 8 9I / s t a r t a d d r e s s 0 4 B 0 1 2 0 0L o a d a d d r e s s p o i n t e r 0 4 B B 1 2 1 1

P o i n t e r : s t a r t o t a p e b u f f e rM i s c . p o i n t e rC a s s e t t e I / w o r k p o i n t e rW o r k p o i n t e r sS c r e e n r e v e r s e f l a gE n d - o f - l i n e f o i n p u t p o i n t e rI n p u t c u r s o r l o ( r o w , c o l u m n )W h i c h k e y : 6 i f n k e I n p u t f r o m s c r e e n / f r o m k e y b o a r dP o i n t e r t s c r e e n l i n eP o s i t i o n o c u r s o r o a b o v e l i n e

d i r e c t c u r s o r ; e l s e p r o g r a m m e dC u r r e n t s c r e e n l i n e l e n g t hR o w h e r e c u r s o r l i v e sL a s t I / c h a r a c t e rN u m b e r o I N S E R T S o u t s t a n d i n gU n u s e d ; r e s e r v e d f o s p e e c hU n u s e dW o r k v a l u eC o l o r l i n e p o i n t e rS c r e e n w o r k v a l u e sN u m b e r o c h a r a c t e r s i k e y b o a r d b u f f e rS c r e e n f r e e z e f l a gM o n i t o r w o r k v a l u e sC a s s e t t e c h e c k s u mM o n i t o r w o r k v a l u eC a s s e t t e w o r k v a l u e sD M c o n t r o l m a s kW o r k b y t eC u r r e n t R O b a n kP r o c e s s o r s t a c k a r e aB A S I C i n p u t b u f f e rP r e v i o u s B a s i c l i n e n u m b e rP o i n t e r : B a s i c s t a t e m e n t f o C O N TD O S c o m m a n d w o r k a r e aG r a p h i c s c u r s o r , a n G r a p h i c s w o r k i n g c u r s o rG r a p h i c s w o r k a r e aP r i n t - u s i n g , g r a p h i c s w o r k a r e aT e m p s c r e e n r o n u m b e rS t r i n g l e n g t h2 5 T r a c e o D i r e c t o r y w o r k a r e aG r a p h i c s w o r k a r e aN u m b e r o g r a p h i c s p a r a m e t e r sP a r a m e t e r r e l a t i v e ( 1 o a b s o l u t e ( 0 F l o a t - f i x e d v e c t o rF i x e d - f l o a t v e c t o rU n u s e dR e s e r v e d f o c a r t r i d g e v e c t o rE r r o r m e s s a g e l i n k [ 8 6 8 6 ]B A S I C w a r m s t a r t l i n k [ 8 7 1 2 ]C r u n c h B A S I C t o k e n s l i n k [ 8 9 5 6 ]P r i n t t o k e n s l i n k [ 8 B 6 E ]S t a r t n e B A S I C c o d e l i n k [ 8 B D 6 ]G e t a r i t h m e t i c e l e m e n t l i n k [ 9 4 1 7 ]C r u n c h h o o k v e c t o rL i s t h o o k v e c t o rE x e c u t e h o o k v e c t o rI n t e r r u p t l i n kI R v e c t o rB r e a k i n t e r r u p t v e c t o rO P E N v e c t o rC L O S E v e c t o rS e t - i n p u t v e c t o rS e t - o u t p u t v e c t o rR e s t o r e I / v e c t o rI n p u t v e c t o rO u t p u t v e c t o rT e s t - S T O P v e c t o rG E v e c t o rA b o r t I / v e c t o rU S v e c t o rL O A D v e c t o rS A V E v e c t o rC a s s e t t e b u f f e rT a p e w r i t e / r e a d c o u n t e r sR S 2 3 2 i n p u t b u f f e rT a p e e r r o r l o C H R G E T s u b r o u t i n eC H R G O T s u b r o u t i n eS u b r o u t i n e ( s e l f b a n k i n g )S u b r o u t i n e ( b a n k v i $ 3 B )S u b r o u t i n e ( b a n k v i $ 2 2 )

S u b r o u t i n e ( b a n k v i S 2 4 )

[ 8 9 6 A ]

( C E 4 2 )( C E 0 E )( F 4 4 C )( E F 5 3 )( E E 5 D )( E D 1 8 )( E D 6 0 )( E F 0 C )( E B E 8 )( E C 4 B )( F 2 6 5 )( E B D 9 )( E F 0 8 )( F 4 4 C )( F 0 4 A )( F 1 A 4 )

O 4 C 60 4 D 10 D 0 4 E 7 - 0 4 E A0 4 E B - 0 4 E E0 4 E F - 0 4 F 60 4 F 70 4 F 8 - 0 4 F BO 4 F C - O 4 F F0 5 0 0 - 0 5 0 20 5 0 3 - 0 5 0 80 5 0 9 - 0 5 1 20 5 1 3 - 0 5 1 C0 5 1 D - 0 5 2 60 5 2 7 - 0 5 3 00 5 3 1 - 0 5 3 20 5 3 3 - 0 5 3 40 5 3 5 - 0 5 3 60 5 3 7 - 0 5 3 80 5 3 90 5 3 A0 5 3 B0 5 3 C0 5 3 D0 5 3 E0 5 3 F0 5 4 00 5 4 1 - 0 5 4 20 5 4 30 5 4 40 5 4 5 - 0 5 4 60 5 4 70 5 4 8O 5 4 9 - O 5 4 A0 5 4 B - 0 5 5 10 5 5 2 - 0 5 5 70 5 5 8 - 0 5 5 C0 5 5 D0 5 5 E0 5 5 F - 0 5 E 60 5 E 7 - 0 5 E B0 5 E C - 0 5 E F0 5 F 0 - 0 5 F 10 5 F 2 - 0 5 F 40 5 F 5 - 0 6 E B0 6 E C - 0 7 A F0 7 B 0 - 0 7 C C0 7 C D - 0 7 D 00 7 D 10 D 0 7 D 30 7 D 4 - 0 7 D 80 7 D 9 - 0 7 E 40 7 E 50 7 E 6O 7 E 70 7 E 80 7 E 90 7 E A0 7 E B

1 2 2 21 2 3 31 2 4 41 2 5 5 - 1 2 5 81 2 5 9 - 1 2 6 21 2 6 3 - 1 2 7 01 2 7 11 2 7 2 - 1 2 7 51 2 7 6 - 1 2 7 91 2 8 0 - 1 2 8 21 2 8 3 - 1 2 8 8

S u b r o u t i n e ( b a n k v i $ 6 F )S u b r o u t i n e ( b a n k v i $ 5 F )S u b r o u t i n e ( b a n k v i $ 6 4 )P c h a r a c t e r s ( , . $ )S t r i n g w o r k a r e aT R A P a n e r r o r f l a g sS t a c k p o i n t e r f o e r r o r t r a pD l o o p w o r k a r e aS o u n d w o r k a r e aU S p r o g r a m j u m pR N s e e d v a l u e

1 2 8 9 - 1 2 9 8 L o g i c a l f i l e t a b l e1 2 9 9 - 1 3 0 81 3 0 9 - 1 3 1 81 3 1 9 - 1 3 2 81 3 2 9 - 1 3 3 01 3 3 1 - 1 3 3 2

D e v i c e n u m b e r t a b l eS e c o n d a r y a d d r e s s t a b l eK e y b o a r d b u f f e rS t a r t o B A S I C m e m o r yT o o B A S I C m e m o r y

1 3 3 3 - 1 3 3 4 T i m e o u t / e n d f l a g s , n o u s e d m u c h1 3 3 5 - 1 3 3 6 T a p e b u f f e r c o u n t s , n o t u s e d m u c h1 3 3 7 T a p e b u f f e r p o i n t e r1 3 3 8 T a p e f i l e t y p e1 3 3 9 C h a r a c t e r ( c o l o r ) a t t r i b u t e1 3 4 0 F l a s h f l a g1 3 4 1 U n u s e d1 3 4 2 S c r e e n p a g e ( u n u s e d )1 3 4 3 K e y b o a r d b u f f e r s i z e1 3 4 4 K e r e p e a t : 1 2 a l l , 6 n o n e1 3 4 5 - 1 3 4 6 K e r e p e a t c o u n t e r s1 3 4 7 K e s h i f t f l a g1 3 4 8 K e f o n t i n t e r l o c k f l a g1 3 4 9 - 1 3 5 0 K e y i n p u t v e c t o r ( D B 7 A )1 3 5 1 T e x t / G r a p h i c s m o d e l o c k o u t f l a g1 3 5 2 S c r o l l e n a b l e f l a g1 3 5 3 - 1 3 5 4 S c r e e n w o r k v a l u e s1 3 5 5 - 1 3 7 2 M L w o r k l o c a t i o n s1 3 6 2 - 1 3 6 7 M L r e g i s t e r s ( P C / S R / A / X / Y )1 3 6 8 - 1 3 7 2 M L w o r k l o c a t i o n s1 3 7 3 F k e y p e n d i n g c o u n t1 3 7 4 F k e p o i n t e r1 3 7 5 - 1 5 1 0 K e d e f i n i t i o n a r e a1 5 1 1 - 1 5 1 5 D M w o r k l o c a t i o n s1 5 1 6 - 1 5 1 9 R O I D ( P A T ) t a b l e1 5 2 0 L o n g J u m p v e c t o r1 5 2 2 - 1 5 2 4 L o n g J u m p r e g i s t e r s1 5 2 4 - 1 7 9 1 R e s e r v e d R A f o e x t r a R O M s1 7 9 2 - 1 9 6 7 B A S I C p s e u d o - s l a c k1 9 6 8 - 1 9 9 6 T a p e w o r k i n g v a l u e s1 9 9 7 - 2 0 0 0 R S 2 3 2 w o r k i n g v a l u e s

2 0 0 1 R S 2 3 2 i p o i n t e r2 0 0 2 R S 2 3 2 r e a d p o i n t e r2 0 0 3 R S 2 3 2 i n p u t c o u n t e r2 0 0 4 - 2 0 0 8 R S 2 3 2 w o r k v a l u e s2 0 0 9 - 2 0 2 0 C h a r a c t e r l o a d p r o g r a m2 0 2 1 C u r r e n t s c r e e n b o t t o m m a r g i n2 0 2 2 C u r r e n t s c r e e n t o p m a r g i n

C u r r e n t s c r e e n l e f t m a r g i n2 0 2 4 C u r r e n t s c r e e n r i g h t m a r g i n2 0 2 5 0 = S c r o l l i n g e n a b l l e d2 0 2 6 2 5 A u t o I n s e r t e n a b l e d2 0 2 7 P r e v i o u s c h a r a c t e r p r i n t e d

0 7 E C - 0 7 E D 2 0 2 8 - 2 0 2 9 C u r r e n t ( c o l o r ) a t t r i b u t e0 7 E E - 0 7 F 10 7 F 20 7 F S0 7 F 40 7 F 50 7 F 60 7 F 70 7 F 80 7 F 90 7 F A0 7 F B0 7 F C0 8 0 0 - 0 B E 70 C 0 0 - 0 F E 71 0 0 0 - F F F F2 0 0 0 - F F F F

2 0 3 0 - 2 0 3 3 S c r e e n l i n e w r a p t a b l e2 0 3 4 S Y A - r e g s a v e2 0 3 5 S Y X - r e g s a v e2 0 3 6 S Y Y - r e g s a v e2 0 3 7 S Y s t a t u s r e s a v e2 0 3 8 N e k e d e t e c t2 0 3 9 L o c k o u t C t r l - S2 0 4 0 M o n i t o r r e a d : R O o R A 2 0 4 1 C o l o r d e c o d e s w i t c h2 0 4 2 S p l i t s c r e e n b i m a s k2 0 4 3 S p l i t s c r e e n v i d e o b a s e2 0 4 4 T a p e m o t o r i n t e r l o c k2 0 4 8 - 3 0 4 7 C o l o r m e m o r y3 0 7 2 - 4 0 7 1 S c r e e n m e m o r y4 0 9 6 - 6 5 5 3 5 B A S I C R A m e m o r y ( n o r m a l )8 1 9 2 - 6 5 5 3 5 B A S I C R A m e m o r y ( h i - r e s )

8 0 0 0 - F F F F 3 2 7 6 8 - 6 5 5 3 5 R O M ; B A S I CD 0 0 0 - D 7 F F 5 3 2 4 8 - 5 5 2 9 5 C h a r a c t e r s e t s i n R O F D 0 0 - F D 0 F 6 4 7 6 8 - 6 4 7 8 3 A C I A c o m m u n i c a t i o n s c h i pF D 1 0 - F D 1 F 6 4 7 8 4 - 6 4 7 9 9 P a r a l l e l p o r t / 6 5 2 9F D D 0 - F D D F 6 4 9 7 6 - 6 4 9 9 1 R O b a n k s e l e c t ( w r i t e o n l y )F E O O - F E F F 6 5 0 2 4 - 6 5 2 7 9 D M d i s k i n t e r f a c eF F 0 0 - F F 1 F 6 5 2 8 0 - 6 5 3 1 1 T E I / c o n t r o l c h i pF F 3 E - F F 3 F 6 5 3 4 2 - 6 5 3 4 3 R O M / R A M s e l e c t ( w r i t e o n l y )

V o l u m e 5 I s s u e 0

Page 27: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 27/88

C o m m o d o r e 1 P l u s R O M e m o r y M a p

8 0 0 0 C - 1 6 R O s t a r t8 0 0 3 W a r m s t a r t8 0 1 9 B a s i c s e t u p8 0 2 A F i x / f l o a t v e c t o r s8 0 2 E I n t i a l i z e B a s i c8 0 B C C H R G E T p o i n t e r s8 0 C 2 P r i n t B a s i c s t a r t m s 8 1 0 5 P a g e v e c t o r s8 1 2 3 C H R G E T c o p y8 1 8 E K e y w o r d s8 3 8 3 A c t i o n v e c t o r s8 4 1 5 F u n c t i o n v e c t o r s8 4 5 3 D f u n c t v e c t o r s8 4 7 1 M e s s a g e s8 6 6 F P r i n t ' R E A D Y . '8 6 8 3 E r r o r r o u t i n e8 7 0 F R e a d y f o B a s i c8 7 2 E H a n d l e n e l i n e8 8 1 8 R e c h a i n l i n e s8 8 5 A R e c e i v e i n p u t l i n e8 8 7 1 S c a n B a s i c - s t a c k8 9 0 5 E x p a n d B a s i c - s t a c k8 9 5 3 C r u n c h t o k e n s8 A 3 D F i n d B a s i c l i n e8 A 7 9 P e r f o r m [ N E W ]8 A 9 3 R u n8 A 9 8 P e r f o r m [ C L R ]8 A E D P U D E F c h a r a c t e r s8 A F 1 B a c k u p t e x t p o i n t e r8 A F F P e r f o r m [ L I S T ]8 B B C P e r f o r m [ R U N ]8 C 9 A P e r f o r m [ R E S T O R E ]8 C D 8 P e r f o r m [ S T O P ]8 C D A P e r f o r m [ E N D ]8 D 0 3 P e r f o r m [ C O N T ]8 D 2 C P e r f o r m [ G O S U B ]8 D 4 D P e r f o r m [ G O T O ]8 D 8 3 P e r f o r m [ R E T U R N ]8 D B 0 P e r f o r m [ D A T A ]8 D B E S c a n f o n e x t s t a t e m e n t8 D C 1 S c a n f o n e x t l i n e8 D E 1 P e r f o r m [ I F ]8 E 0 B P e r f o r m [ R E M / E L S E ]8 E 1 B P e r f o r m [ O N ]8 E 3 E G e f i x e d p o i n t n u m b e r8 E 7 C P e r f o r m [ L E T ]8 F E 0 P e r f o r m [ P R I N T * ]8 F E 6 P e r f o r m [ C M D ]9 0 0 0 P e r f o r m [ P R I N T ]9 0 8 8 P r i n t f r o m ( y . a )9 0 A 6 P r i n t f o r m a t c h a r9 0 B 8 P e r f o r m [ G E T ]9 0 E E P e r f o r m [ I N P U T * ]9 1 0 8 P e r f o r m [ I N P U T ]9 1 4 2 P r o m p t a n d i n p u t9 1 4 F P e r f o r m [ R E A D ]9 2 9 4 P e r f o r m [ N E X T ]9 3 1 4 C h e c k t y p e m a t c h9 3 2 C E v a l u a t e e x p r e s s i o n9 4 7 1 F i x e d - f l o a t c o n v e r s i o n9 4 8 5 E v a l w i t h i n p a r e n s9 4 A D S e a r c h f o v a r i a b l e9 5 F 8 E v a l u a t e < O R >9 5 F B E v a l u a t e < A N D >9 6 2 8 E v a l u a t e < C O M P A R E >9 6 9 B P e r f o r m [ D I M ]9 6 A 5 L o c a t e v a r i a b l e9 7 3 A C h e c k a l p h a b e t i c9 7 4 4 C r e a t e v a r i a b l e9 8 5 B A r r a y p o i n t e r s u b r o u t i n e9 8 7 1 F l o a t - f i x e d c o n v e r s i o n9 8 9 B S e u a r r a y9 A 2 F C o m p u t e a r r a y s i z e9 A 6 2 E v a l u a t e < F R E >9 A 7 6 F i x e d - f l o a t9 A 7 D E v a l u a t e < P O S >

9 A 8 6 C h e c k d i r e c t9 A 9 D P e r f o r m [ D E F ]9 A C B C h e c k F s y n t a x9 A D E P e r f o r m [ F N ]9 B 5 4 S e u s t r i n g d e s c r i p t o r9 B 6 6 E v a l u a t e < S T R $ >9 B 7 0 C a l c u l a t e s t r i n g v e c t o r9 B 7 4 S e u s t r i n g9 B D A C o n c a t e n a t e9 C 1 B B u i l d s t r i n g i n t o m e m o r y9 C 4 B D i s c a r d u n w a n t e d s t r i n g9 C 5 2 M a k e r o o m f o r s t r i n g9 C A A C l e a n d e s c r i p t o r s t a c k9 C B B E v a l u a t e < C H R $ >9 C C F E v a l u a t e < L E F T $ >9 D 0 3 E v a l u a t e < R I G H T $ >9 D 1 5 E v a l u a t e < M I D $ >9 D 4 6 P u l l s t r i n g p a r a m s9 D 6 1 E v a l u a t e < L E N >9 D 6 7 E x i t s t r i n g m o d e9 D 7 O E v a l u a t e < A S C >9 D 8 1 I n p u t b y t e p a r a m e t e r9 D 9 3 E v a l u a t e < V A L >9 D D 2 G e p a r a m s f o P O K E / W A I T9 D D E G e p a r a m s f o S O U N D9 D E 4 C o n v e r t t f i x e d p o i n t9 D F A E v a l u a t e < P E E K >9 E 1 2 P e r f o r m [ P O K E ]9 E 1 B E v a l u a t e < D E C >9 E 6 A P e r f o r m [ W A I T ]9 E 8 7 E v a l u a t e < s u b t r a c t >9 E 9 E E v a l u a t e < a d d >9 F 7 B C o m p l e m e n t F A C * 19 F B 7 M u l t i p l y b z e r o b y t eA 0 1 E E v a l u a t e < L O G >A 0 7 B E v a l u a t e < m u l t i p l y >A 0 A 9 M u l t i p l y b i A 0 D C M e m o r y t F A C * 2A 1 0 7 M e m o r y t F A C * 2A 1 3 7 A d j u s t F A C l / * 2A 1 5 4 U n d e r / o v e r f l o wA 1 6 2 M u l t i p l y b t e A 1 8 3 D i v i d e b t e A 1 9 7 E v a l u a t e < d i v i d e >A 2 1 F M e m o r y t F A C ' lA 2 4 C F A C * 1 t m e m o r yA 2 8 1 F A C * 2 t o F A C * lA 2 9 1 F A C * 1 t F A C * 2A 2 A 0 R o u n d F A C * 1A 2 B 0 G e s i g nA 2 B E E v a l u a t e < S G N >A 2 C E F i x e d - f l o a tA 2 D D E v a l u a t e < A B S >A 2 E 0 C o m p a r e F A C * 1 t m e m o r yA 3 2 7 F l o a t - f i x e dA 3 5 8 E v a l u a t e < I N T >A 3 7 F S t r i n g t F A C * 1A 4 5 3 P r i n t ' I N . . 'A 4 5 A P r i n t n u m b e rA 4 6 F F l o a t t A S C I IA 5 E 4 E v a l u a t e < S Q R >A 5 E E E v a l u a t e < p o w e r >A 6 2 7 E v a l u a t e < n e g a t i v e >A 6 6 0 E v a l u a t e < E X P >A 6 B 3 S e r i e s e v a l u a t i o nA 6 C 9 S e r i e s e v a l u a t i o nA 7 0 7 E v a l u a t e < R N D >A 7 6 0 S a v e B a s i c - s t a c kA 7 6 9 R e s t o r e B a s i c - s t a c kA 7 7 2 T r i m B a s i c - s t a c kA 7 7 D K e r n a l c a l l sA 7 B 5 P e r f o r m [ S Y S ]A 7 C F S Y r e t u r nA 7 D E P e r f o r m [ S A V E ]A 7 F 0 P e r f o r m [ V E R I F Y ]A 7 F 3 P e r f o r m [ L O A D ]

A 8 4 D P e r f o r m [ O P E N ]A 8 5 A P e r f o r m [ C L O S E ]A 8 6 B P a r a m s f o L O A D / S A V EA 8 9 D C h e c k d e f a u l t p a r a m e t e r sA 8 A 5 C h e c k c o m m aA 8 A 8 P a r a m s f o O P E N / C L O S EA 9 0 6 A l l o c a t e s t r i n g s p a c eA 9 5 4 G a r b a g e c o l l e c t i o nA A 5 7 C a l c u l a t e e n o f s t r i n gA A 7 0 E v a l u a t e < C O S >A A 7 7 E v a l u a t e < S I N >A A C 0 E v a l u a t e < T A N >A B 1 A E v a l u a t e < A T N >A B 8 F P e r f o r m [ R E N U M B E R ]A D C A P e r f o r m [ F O R ]A E 5 A P e r f o r m [ D E L E T E ]A E F 7 P r i n t u s i n gB 4 2 B P e r f o r m [ T R A P ]B 4 4 0 P e r f o r m [ R E S U M E ]B 4 B E E v a l u a t e < E R R $ >B 5 0 7 E v a l u a t e < H E X $ >B 5 4 4 P e r f o r m [ P U D E F ]B 5 5 7 P e r f o r m [ D O ]B 5 A C P e r f o r m [ E X I T ]B 6 0 3 P e r f o r m [ L O O P ]B 6 5 2 P e r f o r m [ T R O N ]B 6 5 5 P e r f o r m [ T R O F F ]B 6 C D P e r f o r m [ A U T O ]B 6 E 8 P e r f o r m [ H E L P ]B 7 2 9 P e r f o r m [ K E Y ]B 8 4 9 P e r f o r m [ S O U N D ]B 8 B D P e r f o r m [ V O L ]B 8 D 1 P e r f o r m [ P A I N T ]B 9 D 4 P e r f o r m [ C H A R ]B A E 2 P e r f o r m [ B O X ]B D 3 5 P e r f o r m [ G S H A P E ]B E 2 9 P e r f o r m [ S S H A P E ]B F 7 9 E v a l u a t e < R G R >B F 8 5 E v a l u a t e < R C L R >B F 8 7 E v a l u a t e < R L U M >B F C 1 E v a l u a t e < J O Y >B F F D E v a l u a t e < R D O T >C 0 1 E P e r f o r m [ C I R C L E ]C 3 7 B S e g r a p h i c s c u r s o rC 3 F 7 P a r s e g r a p h i c s c o m m a n dC 4 8 F G e t g r a p h i c s p a r a m e t e rC 4 D 9 P e r f o r m [ D R A W ]C 5 0 F P e r f o r m [ L O C A T E ]C 5 1 A P e r f o r m [ C O L O R ]C 5 6 7 P e r f o r m [ S C N C L R ]C 5 B 8 P e r f o r m [ S C A L E ]C 5 C 3 P e r f o r m [ G R A P H I C ]C 7 B F C o n f i r m g r a p h i c sC 8 B C P e r f o r m [ D I R E C T O R Y ]C 9 4 1 P e r f o r m [ D S A V E ]C 9 5 1 P e r f o r m [ D L O A D ]C 9 6 8 P e r f o r m [ H E A D E R ]C 9 9 C P e r f o r m [ S C R A T C H ]C 9 C C P e r f o r m [ C O L L E C T ]C 9 D A P e r f o r m [ C O P Y ]C 9 F 4 P e r f o r m [ R E N A M E ]C A 0 0 P e r f o r m [ B A C K U P ]C B 1 F P a r s e D O S c o m m a n dC E 0 0 I n t e r r u p t e n t r yC E 0 E I R s e q u e n c eC E 6 0 D s c r e e n s p l i tC E F 0 K e r n a l U D T I MC F 2 6 K e r n a l - R D T I MC F 2 D K e r n a l - S E T T I MC F 8 A G e c o l o r m o d eC F 9 6 F e t c h m e m o r yC F B F H a n d l e t a p e m o t o rD 0 0 0 G r a p h i c c h a r a c t e r s e D 4 0 0 T e x t c h a r a c t e r s e D 8 0 2 S c r e e n a d d r e s s e sD 8 3 4 K e r n a l - S C R E E N

D 8 3 9 K e r n a l - P L O TD 8 8 8 E S C - n n o r m a l s c r e e nD 8 A 1 S e t u p s c r e e n l i n eD 9 B A Q u o t e t e s tD 9 C 7 S c r e e n o u t p u t w r a pD 9 D 9 S e t u p s c r e e n p r i n tD B 1 1 K e r n a l S C N K E YD C 4 1 F u n c t i o n k e y sD C 4 9 O u t p u t t s c r e e nD C 9 B E S C - O ; k e e s c a p eD E 0 6 D e c o d e e s c a p e sD E E S v e c t o r sD E 4 8 E S C - R ; r e d u c e s c r e e nD E 5 E E S C - T ; t o w i n d o wD E 6 0 E S C - B ; b o t t o m w i n d o wD E 8 B E S C - I ; i n s e r t l i n eD E A 0 E S C - D ; d e l e t e l i n eD E C B E S C - Q ; e r a s e t e n D E E 1 E S C - P ; e r a s e f s t a r tD E F 6 E S C - V ; s c r o l l u D F 0 4 E S C - W ; s c r o l l d o w nD F 1 D E S C - L ; s c r o l l e n a b l eD F 2 0 E S C - M ; s c r o l l d i s a b l eD F 2 6 E S C - C ; c a n c e l i n s e r tD F 2 9 E S C - A ; a u t o i n s e r tD F 3 9 C h e c k s c r e e n l i n e w r a pD F 4 6 B r e a k s c r e e n w r a pD F 5 9 M a k e s c r e e n w r a pD F 6 6 C a l c u l a t e s c r e e n w r a p m a s kD F 8 2 E S C - J ; s t a r t - l i n eD F 9 5 E S C - K ; e n d - l i n eE 0 1 E K e y b o a r d s e t sE 1 5 3 S e n d T a l k 'E 1 5 6 S e n d ' L i s t e n 1E 1 8 1 S e n d t o s e r i a l b u E 1 E 9 S e r i a l t i m e o u t sE 1 F 7 S e n d l i s t e n S E 1 F C S l e a r A T NE 2 0 3 S e n d t a l k S E 2 0 C W a i t f o c l o c kE 2 1 D S e n d s e r i a l d e f e r r e dE 2 2 F S e n d ' U n t a l k 'E 2 B 8 S e r i a l c l o c k o E 2 B F S e r i a l c l o c k o f E 2 C 6 S e r i a l o u t p u t ' 1 'E 2 C D S e r i a l o u t p u t ' 0 'E 2 D 4 G e s e r i a l c l o c kE 2 D C D e l a y m E 3 1 9 P r i n t ' P r e s s p l a y r e c 'E 3 1 B P r i n t ' P r e s s p l a y 'E 3 8 D S t a r t t a p eE 3 B 0 K i l l m o t o rE 3 B 7 C l e a r t a p e b u f f e rE 3 C 3 S e t u p t a p e b u f f e rE 4 1 3 S e n d t a p e c y c l eE 4 4 7 S e n d t a p e ' l o n g 'E 4 5 2 S e n d t a p e ' s h o r t 'E 4 5 D S e n d t a p e ' m e d i u m 'E 4 6 8 S e n d t a p e ' 0 ' b i tE 4 7 4 S e n d t a p e ' 1 ' b i tE 4 8 C S e n d t a p e b y t eE 5 3 5 I n i t i a t e t a p e w r i t eE 5 6 C W r i t e t a p e h e a d e rE 6 8 E B i m a s k sE 9 C C F i n d a n t a p e h e a d e rE A 2 1 F i n d s p e c i f i c h e a d e rE A 5 B R S - 2 3 2 o u ( I R Q )E A 9 5 R S - 2 3 2 i ( I R Q )E B D 9 K e r n a l G E T I NE B E 8 K e r n a l - C H R I NE C 0 E G e f r o m t a p eE C 1 4 G e f r o m R S - 2 3 2E C 1 C G e f r o m s e r i a lE C 4 B K e r n a l - C H R O U TE C 6 3 S e n d t t a p eE C 8 4 S e n d t R S - 2 3 2

E C 8 B K e r n a l - A C P T RE C D F K e r n a l C I O U TE D 1 8 K e r n a l - C H K I NE D 6 0 K e r n a l - C H K O U TE D F A K e r n a l - T A L KE E 1 A K e r n a l - T K S AE E 2 C K e r n a l L I S T E NE E 4 D K e r n a l - S E C O N DE E 5 D K e r n a l - C L O S EE F 0 8 K e r n a l C L A L LE F 0 C K e r n a l C L R C H NE F 2 3 K e r n a l U N L S NE F 3 B K e r n a l - U N T L KE F 5 3 K e r n a l - O P E NF 0 0 5 S e n d S F 0 4 3 K e r n a l - L O A DF 0 6 4 L o a d f r o m s e r i a lF 0 F 0 L o a d f r o m t a p eF 1 7 2 P r i n t f i l e n a m eF 1 9 4 K e r n a l - S A V EF 1 A 4 . S a v e l i n kF 1 B 5 S a v e t o s e r i a lF 2 2 8 P r i n t ' S A V I N G 'F 2 3 4 S a v e t t a p eF 2 6 5 K e r n a l - S T O PF 2 A 4 S y s t e m r e s e tF 2 C E T r a n s f e r p a g e v e c t o r sF 2 E B V e c t o r s p a g eF 3 5 2 I d e n t i f y 1 6 K / 3 2 K / 6 4 K R A F 3 D 2 K e l e n g t h sF 3 D A K e d e f i n i t i o n sF 4 0 C K e r n a l - S E T N A MF 4 1 3 K e r n a l S E T L F SF 4 1 A K e r n a l - S E T M S GF 4 1 C K e r n a l R E A D S TF 4 1 E C h a n g e S TF 4 2 3 K e r n a l - S E T T M OF 4 2 7 K e r n a l - M E M T O PF 4 2 F S e M E M T O PF 4 3 6 K e r n a l - M E M B O T -F 4 4 5 P e r f o r m [ M O N I T O R ]F 4 4 C B R K / U S R e n t r yF 4 7 8 P e r f o r m [ . R ]F 4 D 7 P e r f o r m [ . M ]F 5 0 A P e r f o r m [ c h a n g e r e g ]F 5 2 9 P e r f o r m [ > F 5 4 B P e r f o r m [ . G ]F 5 7 0 M o n i t o r c o m m a n d sF 5 8 0 M o n i t o r v e c t o r sF 5 C E P e r f o r m [ . C ]F 5 D 1 P e r f o r m [ . T ]F 6 0 E P e r f o r m [ . H ]F 6 6 E P e r f o r m [ . S / . L / . V ]F 7 0 A P e r f o r m [ . F ]F 7 2 4 P e r f o r m [ . D ]F 8 3 D O c o d e m o d eF 8 8 1 M a c h i n e l a n g u a g e c o d e sF 8 9 B M n e m o n i c sF 9 1 F P e r f o r m [ . A ]F B 7 2 D e c r e m e n t $ F l / 2F B 8 6 D e c r e m e n t $ 9 F / A 0F B 9 4 I n c r e m e n t $ A l / 2F B B 7 S a v e r e g i s t e r sF B C 1 R e c a l l r e g i s t e r sF C 1 9 K e r n a l - I O B A S E -F C 5 9 ' P h o e n i x ' r o u t i n eF C 7 F L o n g F e t c h r o u t i n eF C 8 9 L o n g J u m p r o u t i n eF C B 3 I R e n t r yF C B 8 L o n g I R Q r o u t i n eF C F 1 ' S R T ' k e r n a l e n t r yF C F 4 ' P h o e n i x ' e n t r yF C F 7 L o n g F e t c h e n t r yF C F A L o n g J u m p e n t r yF C F D L o n g I R Q e n t r yF F 9 0 J u m p t a b l eF F F C S y s t e m v e c t o r s

T h T r a n s a c t o r 2 V o l u m e 5 I s s u e 0

Page 28: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 28/88

T h M f l N f l G E R C o l u m n D o B e l lS c o t l a n d , O n t a r i o

L e t t e r s t T h e M a n a g e r

J o s e p h J M a u s o W a t e r M i l l N e Y o r k h a b e e n w o r k i n g o 3 w e e k m o v i n g a v e r a g e a n h a v i n g t r o u b l e w i t h t h

r e p o r t g e n e r a t e p a r t o i t I ' m n o t q u i t e s u r e w h a t t h a p p l i c a t i o n i b u i s o u n d s l i k e s p r e a d s h e e t m i g h t b b e t t e r w a o u t . I a n y b o d y o u t h e r e h a s o l u t i o n , p l e a s e l e m k n o w .

T h e r e a r e a s a l w a y s f e a s t o l e t t e r s d e c r y i n g t h e m a n u a l ,p a r t i c u l a r l y t h R E P O R T G E N E R A T E a n t h A R I T H M E T I Co p t i o n s . A l c a s a i t r t o g e t h o l d o t h a r t i c l e s w r o t eo t h e s e o p t i o n s a n r e a d t h c o l u m n f o f u r t h e r p o i n t e r s .

R i c h a r d E . C . H o l m o O a k v i l l e , O n t a r i o d o e s h i C h r i s t m a sc a r d s w i t h T H M A N A G E R . H d o e s n ' t l i k e t h t a c k y l o o k o m a i l i n g l a b e l s ( d o n ' t e i t h e r ) . T h u s , h p r e f e r s t p r i n t e a c hn a m e / a d d r e s s d i r e c t l y o a e n v e l o p e . T h p r o b l e m i t h a tR E P O R T G E N E R A T E w i l l n o p a u s e d u r i n g a p r i n t e d r e p o r ts t h a t h e c a n i n s e r t n e e n v e l o p e . s o l u t i o n t t h i sp r o b l e m i p r e s e n t e d b e l o w .

H e l p F o M a i l L i s t s

h a v e h a d a q u e s t i o n o h o t g e a m a i l i n g l i s t r e p o r t t p r i n t o n l y o n n a m e / a d d r e s s a t i m e . T h i s w o u l d a l l o w f o n o n - f o r m f e e d p r i n t e r s ; a l s o , i t ' s s o m e t i m e s d i f f i c u l t t g e t h l a b e l s t o p r i n t e x a c t l y a t h r i g h t p o s i t i o n .

U n f o r t u n a t e l y , T H M A N A G E R R E P O R T G E N E R A T E h a n s o p h i s t i c a t e d ' p r i n t p a u s e ' f e a t u r e . w a a r o u n d t h i sp r o b l e m i t o u t p u t t h r e p o r t t d i s k a a s e q u e n t i a l f i l e .T h e n u s w o r d p r o c e s s o r t h a t c a r e a d s e q u e n t i a l f i l e sc r e a t e d b o t h e r p r o g r a m s . O n c e y o u h a v e t h d a t a a v a i l ab l t w o r d p r o c e s s o r , i i i i u s u a l l y n t r o u b l e t s p e c i f y

p a u s e a t h e n o e a c h p a g e , o i n t h i s c a s e , n a m e /a d d r e s s l a b e l .

T h o n l y o t h e r w a a r o u n d t h i s p r o b l e m w i t h i n T H M A A G E R p r o g r a m i t s e l f t h a t k n o w o i t s i m p l y r u ns e p a r a t e r e p o r t f o e a c h m a i l i n g l a b e l . Y o n e e d f i e l d t h a tg i v e s u n i q u e n u m b e r f o e a c h r e c o r d ( y o u m a w a n t t u s

f i e l d f o r e c o r d n u m b e r s ) . T h e n y o c a n r u n t h r e p o r ts p e c i f y i n g o n l y p a r t i c u l a r r e c o r d . W h e n y o u w a n t t h e n e x tl a b e l , r u t h r e p o r t a g a i n o n l y c h a n g e t h s e a r c h c r i t e r i a t t h n u m b e r o t h n e x t r e c o r d y o u w a n t p r i n t e d . T h i s i v e r yt e d i o u s w o r k !

T h E a s y W a o R e v i s i n g F i l eC h a n g i n g P r o m p t s

I p r e v i o u s a r t i c l e d i s c u s s e d r e v i s i n g f i l e u s i n g t h eR E A R R A N G E f u n c t i o n i t h M A N I P U L A T E F I L E S o p t i o n .F r a n k l y , I ' v e h a m i x e d s u c c e s s w i t h t h i s o p e r a t i o n . w o u l dt r y t o a v o i d m a k i n g s u b s t a n t i a l r e v i s i o n s t y o u r f i l e . I y o t h i n k i m a n e e d r e v i s i o n s , c r e a t e o n l y s m a l l f i l e a n e n t e r o n l y f e r e c o r d s . T h u s , i y o d e c i d e t r e v i s e y o u rf i l e a n s t a r t f r o m s c r a t c h a g a i n , y o w o n ' t h a v e w a s t e dm u c h t i m e i d a t a e n t r y .

H i n d s i g h t i w o n d e r f u l i y o c a s t i l l p r e v e n t i f r o m b e i n g" t o o l a t e " t a c o n O n w a t r e v i s e y o u r f i l e w i t h o u tr e a l l y r e v i s i n g i i t s i m p l y c h a n g e t h p r o m p t f o o n o t h f i e l d s y o u ' r e n o t u s i n g v e r y o f t e n . I y o o v e r d e s i g n e dy o u r f i l e ( a m o s t o u d o y o p r o b a b l y h a v e o f i e l d st h a t a r e x p e n d a b l e o a w o r s t l u x u r y . I y o f e e l t h a t t h n e p i e c e o i n f o r m a t i o n i m o r e i m p o r t a n t t h a n o n o y o u rp r e s e n t f i e l d s , t h e n i s e e m s l i k e f a i r t r a d e . T h i m p o r t a n tp o i n t i t h a t t h f i e l d t y p e b t h s a m e ( i . e . n u m e r i c o a l p h a n u m e r i c ) a n t h l e n g t h o t h f i e l d b l o n g e n o u g h t a c c o m m o d a t e t h n e i n f o r m a t i o n . Y o c a n t h e n r e v i s e t h s c r e e n i t h C R E A T E / R E V I S E o p t i o n . J u s t w a t c h o u f o t h a t d e a d l y p r o m p t :

F I L E H A S B E E N A L T E R E D . N E F I L E ( Y / N ) ?

A N S W E R T T H I S Q U E S T I O N W I L L D E S T R O Y Y O U RE X I S T I N G F I L E .

S p e e d i n g U D a t a E n t r yC h a n g e t h F i r s t F i e l d E n t e r e d

W h e n y o u w a n t t u p d a t e f i l e , y o u ' l l o f t e n f i n d t h a t t h o n l y f i e l d y o u w i s h t c h a n g e i n e a r o a t h b o t t o m o t h

T h T r a n s a c t o r 2 V o l u m e 5 I s s u e 0

Page 29: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 29/88

Page 30: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 30/88

S u b r o u t i n e E l i m i n a t o r s J e f f G o e b e lG e o r g e t o w n , O n t .

A a l w a y s , h a v e b r o u g h t f o r t h f e w g o o d i e s t h a t d t h w o r k o e n t i r e s u b r o u t i n e s . T h i s m o n t h , m o s t o t h a r t i c l e i d e d i c a t e d t o n p o w e r f u l p o k e t h a t o p e n s u w o r l d o n e u n e x p l o r e ds u b r o u t i n e e l i m i n a t o r s .

B e f o r e s t a r t i n g o f f , m u s t a p o l o g i z e t a n p e o p l e w h t r u s t e d l a s ti s s u e ' s U N - N E W p o k e f o t h 6 4 ( p o k e 2 0 5 0 , l : s y s 4 2 2 9 1 ) I d o e si n d e e d b r i n g b a c k y o u r l i s t i n g a f t e r N E o s y s 6 4 7 3 8 b u u n f o r t u n a t e l y , i d o e s n o c l e a r u a l y o u r p o i n t e r s . I y o a t t e m p tt r e - e d i t l i n e s o e n t e r n e l i n e s . . W H A M M O ! b i z a r r e c r a s ht h l i k e s o f w h i c h a l m o s t d e s e r v e s s p o t i B I T S P I E C E S . I d o e sh o w e v e r a l l o w y o t L I S T t h p r o g r a m f i n e , s y o c o u l d L I S T i t d i s k a n c r e a t e a s e q u e n t i a l f i l e w h i c h c o u l d l a t e r b c o n v e r t e db a c k i n t o p r o g r a m . A n y w a y , h a v e s i n c e d i s c o v e r e d t h a t t h P O K E w o r k s w e l l w i t h m a c h i n e l a n g u a g e r o u t i n e s ( w h i c h s t a r tw i t h B A S I C S Y S c o m m a n d ) b u t n o t w e l l w i t h p u r e B A S I C . S o r r ya b o u t t h a t . h o p e n o b o d y e r a s e d m o n t h ' s w o r k t e s t i n g i t

B e f o r e t h m a i n a t t r a c t i o n , s h o u l d e x p l a i n t h P O K E l e f t y o w i t h i t h " S p i f f y L i s t i n g s " a r t i c l e i n V o l u m e 5 I s s u e 3 T h P O K Ec a u s e d l i n e n u m b e r s t v a n i s h f r o m p r o g r a m l i s t i n g s , b u d i d n ' te x p l a i n w h a t i w a g o o d f o r . W e l l , t h e i d e a i s i t ' s a n e a s y w a t c r e a t e a n i c e n e a t s e q u e n t i a l f i l e . T h f i l e c a t h e n b s e n t o v e rm o d e m , u s e d f r o m w i t h i n p r o g r a m , p r i n t e d o u ( o n a p r i n t e r ) , o l o a d e d i n t o m a n y c o m m o n w o r d p r o c e s s o r s . T c r e a t e t h e f i l e ,s t a r t o f b e n t e r i n g a l i n e n u m b e r f o l l o w e d b q u o t e a n y o u rt e x t . T h f o r m a t w i l l r e s e m b l e p r o g r a m , b u y o w o n ' t a c t u a l l yb u s i n g a n c o m m a n d s a s u c h . I s h o u l d e n d u p l o o k i n gs o m e t h i n g l i k e t h e x a m p l e b e l o w :

1 H e l l o t h e r e p e o p l e . a s h o r t2 p i e c e o t e x t . I m o m e n t ,3 " w i l l b e c o m e s e q u e n t i a l f i l e .

W h e n y o h a v e f i n i s h e d t y p i n g i y o u r e n t i r e f i l e , e n t e r :

P O K E 2 2 , 3 5 f o V I C / 6 4o r P O K E 1 9 , 3 2 f o C B B A S I C 2 . 0 / 4 . 0

I y o L I S T y o u r p r o g r a m n o w , y o u ' l l s e t h a t t h l i n e n u m b e r sh a v e t e m p o r a r i l y v a n i s h e d . I i n o s i m p l e m a t t e r t o p e n u f i l e t t h e d i s k o r p r i n t e r a n L I S T y o u r p r o g r a m t i t T d u m p t d i s k , e n t e r O P E N 1 , 8 , 1 , " F I L E N A M E . S . W " : C M D 1 : L I S T ( R E T U R N ) ,t h e n P R I N T * 1 : C L O S E 1 T p r i n t i t O P E N 4 , 4 : C M D 4 : L I S T ( R T U R N ) , t h e n P R I N T # 4 : C L O S E 4 w h e n t h l i s t i n g h a f i n i s h e d .

T h t r i c k i e v e n b e t t e r i y o u h a v e B A S I C A I t y p e u t i l i t y ( l i k eP O W E R ) i m e m o r y . U s i n g t h e e x t r a f e a t u r e s c o m b i n e d w i t h a e x t e n s i o n l i k e t h a t m a k e s t h i s P O K E q u i t e a n i c e w o r d p r o c e s s o r ,

c o m p l e t e w i t h s c r o l l i n g u a n d o w n , s e a r c h a n r e p l a c e , a u t o l i n en u m b e r i n g a n d r e n u m b e r i n g a n d e x t r a t e x t s p a c e . N o b a f o o n p o k e . I l e a v e s t h e r e a l m o s u b r o u t i n e e l i m i n a t i o n a n e n t e r s t h a r e a o c o m p l e t e p r o g r a m e l i m i n a t i o n .

T h r e s t o f t h i s a r t i c l e d e s c r i b e s o n a l l - p o w e r f u l P O K E I ' v e n e v e rs e e n d o c u m e n t e d . T h e r e h a v e b e e n m a n y a r t i c l e s w r i t t e n a b o u ts e l f m o d i f y i n g p r o g r a m s u s i n g t h d y n a m i c k e y b o a r d . H e r e , I ' l i k e t o p r e s e n t S E L F M O D I F Y I N G P O K E . B a s i c c o m m a n d s a r s t o r e d i m e m o r y a t o k e n s . E a c h c o m m a n d h a c o r r e s p o n d i n gv a l u e . I w w e r e t s e a r c h t h r o u g h o u r B A S I C m e m o r y w i t h am a c h i n e l a n g u a g e m o n i t o r , w w o u l d s e a l t h B A S I C t o k e n ss t o r e d a l o n g w i t h o u r r e g u l a r t e x t . S i n c e B A S I C i s t o r e d i R A M ,w c a P O K E t i t I l o g i c a l l y f o l l o w s t h a t o u B A S I C t o k e n s c a e a s i l y b c h a n g e d b y p o k i n g n e v a l u e o v e r t o o t h e o l d v a l u e .E n t e r a n R U t h e x a m p l e b e l o w .

1 0 r e m 6 4 7 3 82 p o k e 2 0 5 3 , 1 5 8 : r e m * c h a n g e f i r s t t o k e n t S Y S "

( F o r m a c h i n e s o t h e r t h a n V I 2 o C 6 4 , u s e t h v a l u e 1 0 2 9i n s t e a d o 2 0 5 3 i t h a b o v e a n d a l s u b s e q u e n t e x a m p l e s . U s 3 0 7 7 f o t h + 4 / C 1 6 )

W h e n t h p r o g r a m i R U N , t h p o k e i n l i n e 2 w i l l p l a c e t h e t o k e nv a l u e 1 5 o v e r w h a t e v e r w a t h e r e b e f o r e . I w i l l c h a n g e l i n e 1 f r o m a h a r m l e s s R E M , t m a c h i n e r e s e t t i n g S Y c o m m a n d . T h a ti b e c a u s e 2 0 5 3 i t h f i r s t l o c a t i o n o o u B A S I C p r o g r a m , a n t h v a l u e 1 5 8 i t h B A S I C t o k e n v a l u e o t h S Y c o m m a n d . I y o n o l i s t t h p r o g r a m , l i n e 1 w i l l r e a d : 1 0 s y s 6 4 7 3 8 . T h n e x t t i m et h i s e x a m p l e i r u n , t h c o m p u t e r w i l l r e s e t . Y o m a f e e l t h i s i q u i t e u s e l e s s , a n w o u l d t e n d t a g r e e . H o w e v e r , i d e m o n s t r a t e st h c o n c e p t w e l l . I t h e f o l l o w i n g e x a m p l e s , w p o k e s o m e o t h o t h e r B A S I C c o m m a n d s i n t o o u f i r s t l i n e o f B A S I C ; s o m e o t h e mh a v e m o r e u s e f u l a p p l i c a t i o n s .

1 i t h e n x l o a d " m a c h i n e l a n g u a g e " , 8 , 12 p o k e 2 0 5 3 , 1 4 r e m * c h a n g e f i r s t t o k e n t R E

W i t h t h i s p o k e , t h p r o g r a m w i l l l o a d s u b r o u t i n e o n l y t h f i r s tt i m e . T h n e x t t i m e i i r u n , l i n e 1 w i l l h a v e b e e n c h a n g e d t R E s t a t e m e n t a n t h e r e f o r e t h e s t a t e m e n t w i l l b i g n o r e d . T h i s i m u c h e a s i e r t h a n w a i t i n g f o y o u r s u b r o u t i n e s t r e - l o a d e v e r yt i m e y o r u p r o g r a m .

1 0 r e m 4 , 4 c m d 42 p o k e 2 0 5 3 , 1 5 r e m * c h a n g e s t o k e n t O P E N "

W h e n t h a b o v e e x a m p l e i r u t h f i r s t t i m e , a l w i l l f u n c t i o n

T h T r a n s a c t o r 2 V o l u m e 5 I s s u e 0

Page 31: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 31/88

n o r m a l l y . W h e n i i r u s e c o n d t i m e , a l o u t p u t w i l l b t r a n s f e rr e t t h p r i n t e r i n s t e a d o t h e s c r e e n . T h r e w i l l n o b e a nO P E N c o m m a n d .

1 r e m 1 0 0 02 0 p o k e 2 0 5 3 , 1 3 7 r e m * c h a n g e s t o k e n t G O T O "

T h i s a p p l i c a t i o n p e r h a p s o n o t h m o s t h a n d y w i l l c h a n g ey o u r p r o g r a m s t h a t w h e n i r u n s t h s e c o n d t i m e , i i c a p a b l e o b y p a s s i n g a l t h o p e n i n g r o u t i n e s a n j u m p i n g d i r e c t l y t t h m a i n p r o g r a m . T h v a l u e 1 3 7 c h a n g e s t h R E t G O T O . M o s to u k n o w h o w d u l l i i t s i t h r o u g h g r a p h i c o p e n i n g t w e n t yt i m e s . S u b s t i t u t e t h e 1 0 0 0 v a l u e i l i n e 1 f o t h s t a t e m e n t t h a ty o u r m a i n p r o g r a m s t a r t s w i t h .

1 p o k e 5 3 2 8 0 , p o k e 5 3 2 8 1 , 0 : p o k e 2 0 5 3 , 1 4

I m o s t o t h p r o g r a m s w r i t e , c h a n g e t h s c r e e n a n b o r d e rc o l o u r s t b b l a c k , b u g i v e t h u s e r t h o p p o r t u n i t y t r e - s e t t h s c r e e n t w h a t e v e r c o m b i n a t i o n i t h e i r f a v o r i t e . W h e n l i n e 1 i r e - r u n , i w i l l n o r e - p o k e t h s c r e e n b l a c k . T h P O K E w i l l h a v eb e e n c h a n g e d t R E M .

1 0 r e m 1 0 , 0 , 7 0 , 8 7 , 7 6 , 6 7 1 2 0 p o k e 2 0 5 3 , 1 3 r e m * c h a n g e 1 s t o k e n t " D A T A "

T h a b o v e e x a m p l e c h a n g e s t h R E i n l i n e 1 t D A T As t a t e m e n t s w h e n t h p r o g r a m i r u t h s e c o n d t i m e , n e s e r i e s o v a l u e s w i l l b R E A D .

T O K E N L O O K U P T A B L E

( m o s t c o m m o n B a s i c c o m m a n d s a r i n c l u d e d - f o c o m p l e t e l i s t ,s e T h R e f e r e n c e T r a n s a c t o r V o l . I s s u e 5

1 0 r e m a = 1 0 0 0 : b = 1 0 0 02 p o k e 2 0 5 3 , 1 3 6 : r e m * c h a n g e s t o k e n t L E T "

T h a b o v e e x a m p l e w i l l c h a n g e t h r e i l i n e 1 t b t h L E c o m m a n d . N o r m a l l y t h L E c o m m a n d i r a t h e r u s e l e s s , a n y o m a h a v e n e v e r u s e d i b e f o r e , b u h e r e , i a l l o w s t h e v a r i a b l e s i l i n e 1 t b a c t i v e o t h s e c o n d r u o n l y . T h i s p r o d u c e d i f f e r e n tr e s u l t s e a c h t i m e t h p r o g r a m i r u n .

T h e s e a r v e r y f e e x a m p l e s o t h p o w e r o f t h i s p o k e . R e f e r t t h T O K E N C H A R T a t h e n o f t h i s a r t i c l e a n e x p e r i m e n t o y o u r o w n . H o w e v e r , t h e r e i a l s o a n o t h e r w a t u s t h i s s a m ec o n c e p t . W c a p o k e v a l u e s i t h a t a r N O t o k e n i z e d k e y w o r d s .B d o i n g t h i s , w a r e a b l e t c h a n g e o t h e r a s p e c t s o o u B a s i cs t a t e m e n t . E n t e r t h e x a m p l e b e l o w .

1 0 a = 1 0 0 02 0 p o k e 2 0 5 3 , 6 6 r e m * s t a r t s t l i n e w i t h b

H e r e , w a r p o k e i n g t h v a l u e o t h e c h a r a c t e r b t l o c a t i o n 1 T h i s w i l l c h a n g e 1 t r e a d 1 0 0 0 . S i n c e t h e r e a r e n t o k e n i z e dk e y w o r d s h e r e , i i e a s y t c a l c u l a t e t h e p o s i t i o n o o u c h a n g e .L o c a t i o n 2 0 5 3 i t h f i r s t c h a r a c t e r ; l o c a t i o n 2 0 5 4 i t h s e c o n d ;2 0 5 5 t h t h i r d a n s o n I w k n o w t h i s , w c a c h a n g e 1 0 0 0t 2 0 0 0 o 2 0 0 1 s i m p l y b y p o k i n g t h v a l u e s f o o i t h c o r r e c t p o s i t i o n s .

T s o m e o n e w i t h e n o u g h i m a g i n a t i o n a n l o g i c , t h e s e c o n c e p t so p e n u n e w o r l d . I n o b e c o m e s f a i r l y s i m p l e t c r e a t eB A S I C p r o g r a m t h a t h a t h p o w e r t d e l e t e s p a c e s f r o m w i t h i np r o g r a m , o c h a n g e A L R E M s t P O K E S , o c h a n g e a l o c c u r e n c e so o n c h a r a c t e r t a n o t h e r , s i m i l a r t w o r d p r o c e s s o r ' s s e a r c ha n r e p l a c e f u n c t i o n .

a b a n a s c h r $ (c l o s ec l c m c o n td a t ad e f f nd i e n f o n e x ts t e pt g e g o t oi i n p u ti n l e f t $l e

1 8 1 7 1 9 1 9 1 6 1 5 1 5 1 5 1 3 1 5 0 , 1 6 51 3 1 2 1 2 1 3 1 6 1 6 1 6 1 3 1 3 1 3 1 8 2 0 1 9

l e l i s tl o a dm i d $n e o o p e np e e kp o k ep r i n tr e a dr e r i g h t sr u s a v es t o ps y v a w a i tv e r i f y

1 3 1 5 1 4 2 0 1 6 1 4 1 5 1 9 1 5 1 5 1 3 1 4 2 0 1 3 1 4 1 4 1 5 1 9 1 4 1 4

E d i t o r ' s n o t e : W h i l e J e f f ' s t e c h n i q u e o f h a v i n g a p r o g r a m d y n a m ic a l l y m o d i f y i t s e l f a i r u n s i c l e v e r a n t h o u g h t - p r o v o k i n g ,e x t e n s i v e u s e o f i s h o u l d p r o b a b l y b e a v o i d e d , e s p e c i a l l y i p r o g r a m s o a n c o m p l e x i t y . S e l f - m o d i f y i n g c o d e m e a n s t h a t t h i n s t r u c t i o n s c o n t a i n e d i p r o g r a m a a n g i v e n p o i n t d e p e n d o nw h a t p a r t s o f t h a t p r o g r a m w e r e e x e c u t e d b e f o r e y o l o o k a i t W h a t d e b u g g i n g n i g h t m a r e ! U s e d i m o d e r a t i o n , a s i J e f f ' se x a m p l e s , t h t e c h n i q u e c a n b e q u i t e h a n d y . N o t e t h a t t h e a b o v ee x a m p l e s o n l y c h a n g e a s i n g l e t o k e n ( t h e f i r s t o n i t h p r o g r a m ,a 2 0 5 3 ) , a n t h c h a n g e i o n l y m a d e a o n p o i n t i t h p r o g r a m ,a l w a y s o t h s e c o n d l i n e . A d h e r i n g t t h i s p r a c t i c e , a n d o c um e n t i n g t h e f f e c t o t h c h a n g e w i t h R E s t a t e m e n t o t h s e c o n d l i n e s h o u l d a v o i d c r e a t i n g u n c o n t r o l l a b l e , c h a m e l e o n i cm o n s t e r - c o d e .

F u r t h e r m o r e , t h t e c h n i q u e s h o w n c h a n g e s t h e o r i g i n a l t o k e n t n e t o k e n , b u t n e v e r r e p l a c e s t h e o r i g i n a l . T a l t e r n a t e b e t w e e nt w t o k e n , s a L E a n d R E M , c h a n g e t h s e c o n d l i n e t o

1 0 r e m a 1 0 0 0 : b = 1 0 0 02 0 p o k e 2 0 5 3 , 2 7 9 - p e e k ( 2 0 5 3 )

T h n u m b e r 2 7 i t h s u o t h t o k e n v a l u e s f o R E a n L E T .O n t h f i r s t R U N , t h t o k e n i l i n e 1 i c h a n g e d t L E T , s o t h a to n t h s e c o n d R U t h e v a r i a b l e s a n w i l l b s e t . F o t h t h i r dR U N , l i n e 1 w i l l a g a i n s t a r t w i t h R E M . T a l t e r n a t e b e t w e e n a n t w t o k e n s , y o m u s t s t a r t o u t w i t h o n o t h o t h e r ( s i n c e t h P O K E i d e p e n d e n t o t h p r e v i o u s v a l u e ) a n r e p l a c e t h e n u m b e r2 7 i n l i n e 2 w i t h t h e s u o f t h e t w t o k e n v a l u e s ( o r i g i n a l p l u sa l t e r n a t e ) . - T E d

T h T r a n s a c t o r 2 V o l u m e 5 I s s u e 0

Page 32: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 32/88

I n t r o d u c i n g T r a n s B A S I C N i c k S u l l i v a nS c a r b o r o u g h , O n t a r i o

t r a n s - , p r e f . 1 A c r o s s , b e y o n d , o o t t h o t h e r s i d e , t h r o u g h , i n t o d i f f e r e n t s t a t e o p l a c e . 2 O f o p e r t a i n i n g t o T h T r a n s a c t o r .

T h v e r s i o n o B A S I C b u i l t i n t o t h C o m m o d o r e 6 h a c o m e i n f o rl o o c r i t i c i s m , a n i i s n ' t h a r d t s e w h y . M o s t 6 o w n e r s u s

d i s k d r i v e , y e B A S I C d o e s n o s u p p o r t t h d i s k c o m m a n d s p r v i d e d w i t h s o m e o t h e r C o m m o d o r e c o m p u t e r s . M o s t o u w e r ed r a w n t t h m a c h i n e i l a r g e p a r t b i t p o w e r f u l g r a p h i c s a n s o u n d c a p a b i l i t i e s , y e c o m m a n d s t t a k e a d v a n t a g e o t h e m a r n o t i n c l u d e d . L i k e a t r e a s u r e c h e s t w i t h o u t k e t h 6 d e m a n d si e x c h a n g e f o i t s e c r e t s l o m o r e w o r k t h a n w e v e r e x p e c t e d .

T h e r e a r r e m e d i e s .

O n i t g e a l o n g , g r u m b l i n g , w i t h t h B A S I C t h e y g a v e u s u s i n gP R I N T * t s e n d c o m m a n d s t t h d i s k , P E E K i n g a n P O K E i n g t h h u n d r e d o s m e m o r y l o c a t i o n s t h a t a r e r e l e v a n t t s o u n d a n dg r a p h i c s p r o g r a m m i n g . T h c o s t ? S t y l e , s i z e a n s p e e d s p e e da b o v e a l l . M a n y g r a p h i c s a n d s o u n d a p p l i c a t i o n s w o u l d b u n d e rm i n e d e n t i r e l y i t h e y h a t d e p e n d o n t h t o o l s B A S I C p r o v i d e s .

A n o t h e r r e m e d y i t u s m a c h i n e l a n g u a g e s u b r o u t i n e s . T h a d v a n t a g e s o m a c h i n e l a n g u a g e a r m a n y c o n c i s e n e s s , b l i s t e ri n g s p e e d , u n p a r a l l e l e d c o n t r o l o v e r t h c o m p u t e r . N o t o n l y t h a t ,b u o n c e y o k n o w h o w , w r i t i n g m a c h i n e l a n g u a g e i f u n . A l a s ,l o o p e o p l e d n o k n o w h o w , a n l a c k t h e t i m e a n i n c l i n a t i o n t l e a r n . A n e v e n i y o c a w r i t e m a c h i n e l a n g u a g e , o h a v e o t h e ra c c e s s t t h u t i l i t i e s y o n e e d , t h i n t e r f a c e w i t h B A S I C i r a r e l ye l e g a n t a n o f t e n p r o b l e m a t i c a l .

T h t h i r d c h o i c e i t a c q u i r e a e n h a n c e m e n t s p a c k a g eS i m o n ' s B A S I C , f o e x a m p l e , w h i c h b o a s t s a e n o r m o u s s e o a d d i t i o n a l c o m m a n d s ( m o r e t h a n 1 0 0 ) i s e v e r a l c a t e g o r i e s . T h a t ' sd a n d y , b u a g a i n t h e r e a r e d r a w b a c k s , l a c k o p o r t a b i l i t y b e i n gp r o b a b l y t h m o s t s e r i o u s . T h a t k i n d o p a c k a g e a l s o t e n d s t b i n f l e x i b l e : i y o u w a n t o n l y h a l f d o z e n o t h o s e 1 0 c o m m a n d s ,t o u g h . Y o c a n ' t j u s t p i c k t h e o n e s y o u w a n t a n u s t h r e m a i n i n gm e m o r y f o s o m e t h i n g e l s e i t ' s a l o r n o t h i n g . A n i b y c h a n c ey o u w a n t c o m m a n d t h p a c k a g e d o e s n o i n c l u d e , t h a t t o i y o u r m i s f o r t u n e .

T h a t ' s t h e s t o r y s f a r . N o r e a d o n

S t a r t i n g w i t h t h i s i s s u e T h T r a n s a c t o r i o f f e r i n g a n o t h e r a p r o a c h t e x p a n d i n g C o m m o d o r e 6 4 B A S I C , o n d e s i g n e d t a v o i dt h p r o b l e m s o u t l i n e d a b o v e . T h n e a p p r o a c h i c a l l e d T r a n sB A S I C . I t t o o , w i l l o f f e r l a r g e n u m b e r o c o m m a n d s e i g h t i t h i s f i r s t i n s t a l m e n t ; i t h l o n g r u p e r h a p s 5 0 0 o m o r e . T h

c o m m a n d s w i l l i n c l u d e b o t h s t a t e m e n t s a n f u n c t i o n s , a n t h e yw i l l l o o k a n f e e l j u s t l i k e t h B A S I C c o m m a n d s w e ' r e u s e d t o U n l i k e o t h e r p a c k a g e s h o w e v e r , T r a n s B A S I C w i l l l e a v e i u t y o w h i c h e x t r a c o m m a n d s y o u a d d f r o m t h o s e c u r r e n t l y a v a i l a b l e .T h i s m e a n s t h a t y o w o n ' t b w a s t i n g m e m o r y o u n u s e d c o m a n d s , a n t h a t i m a n y i n s t a n c e s y o u r c u s t o m i z e d p a c k a g e w i l lb e a s i l y t r a n s p o r t a b l e v i D A T A s t a t e m e n t s .

I t h e r e a c a t c h ? W e l l , y e s .

T r a n s B A S I C i w r i t t e n i a s s e m b l y l a n g u a g e s o u r c e c o d e , s p e c i f ic a l l y t h a t o P r o L i n e S o f t w a r e ' s P A a s s e m b l e r , b B r a d T e m p l e -t o n . U n l e s s y o u h a v e a c c e s s t c o p y o P A L , o s o m e o t h e ra s s e m b l e r t h a t p a r a s i t i z e s t h B A S I C e d i t o r , T r a n s B A S I C i n o f o y o u .

O b v i o u s l y , d e p e n d e n c e o n P A i s e v e r e r e s t r i c t i o n . O t h o t h e r h a n d , P A h a w e l l - e a r n e d r e p u t a t i o n f o i t s m a l l s i z e ,e a s e o u s e , a n t r u l y e x c e p t i o n a l s p e e d , s d o n ' t m i n d s u g g e s t i n gt h a t i y o h a v e a n y i n t e r e s t a a l i w o r k i n g w i t h m a c h i n el a n g u a g e , y o p r o b a b l y s h o u l d o w P A a n y w a y .

H o T r a n s B A S I C w o r k s

I y o a r e n ' t m u c h i n t e r e s t e d i t h n u t s a n b o l t s o T r a n s B A S I C ,i n v i t e y o t s k i p t h i s s e c t i o n o r r e t u r n t i l a t e r . Y o c a u s T r a n s B A S I C p e r f e c t l y w e l l w i t h o u t k n o w i n g t h e t e c h n i c a l d e t a i l sg i v e n h e r e .

T r a n s B A S I C i b u i l t a r o u n d k e r n e l o f l e s s t h a n 5 0 b y t e s , w h i c hi m o s t l y d e v o t e d t f o u r f u n d a m e n t a l r o u t i n e s . T h e s e r o u t i n e s a r ee n t e r e d t h r o u g h t h l i n k v e c t o r s p r o v i d e d b B A S I C a h e x a dd r e s s e s $ 0 3 0 4 t h r o u g h $ 0 3 0 B .

C r u n c h T o k e n s : T h e f i r s t o t h f o u r r o u t i n e s i r e s p o n s i b l ef o t o k e n i z i n g t h e n e c o m m a n d s . T h e f a c t t h a t T r a n s B A S I Ct o k e n i z e s e a c h i n p u t l i n e b e f o r e B A S I C i t s e l f d o e s h a s o m ei n t e r e s t i n g c o n s e q u e n c e s .

O n i t h a t T r a n s B A S I C c a n ' t m a k e u s o B A S I C - s t y l e p r og r a m t o k e n s ( h e x v a l u e s $ 8 t h r o u g h $ F F ) , s i n c e B A S I C ' St o k e n i z e r t h r o w s o u a n c h a r a c t e r i t h i s r a n g e . T r a n s B A S I Ct h e r e f o r e u s e s a t w b y t e t o k e n . T h f i r s t b y t e i t h n o r m a l l yu n u s e d l e f t - a r r o w c h a r a c t e r ( A S C I I $ 5 F ) , a n t h s e c o n d b y t e ,

Page 33: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 33/88

w h i c h i d e n t i f i e s t h k e y w o r d , i a c h a r a c t e r i t h A S C I I r a n g e$ 4 t h r o u g h $ 7 F . T h o n l y t r o u b l e s o m e c h a r a c t e r i t h a tr a n g e i $ 5 E , t h e u p - a r r o w , u s e d b B A S I C a t h e x p o n e n t i at i o n o p e r a t o r a n t h e r e f o r e n o a v a i l a b l e f o u s a s a t o k e n .T h f o u r k e r n e l r o u t i n e s t a k e a e x t r a s t e p t d e a l w i t h t h i sc h a r a c t e r .

D o i n g t h T r a n s B A S l C t o k e n i z a t i o n f i r s t a l s o m e a n s t h a t i i p o s s i b l e f o T r a n s B A S l C k e y w o r d s t i n c l u d e B A S I C k e y w o r d sw i t h i n t h e m , b u n o t t h e o t h e r w a a r o u n d . S O R T , f o i s t a n c e , w o u l d b l e g i t i m a t e T r a n s B A S l C k e y w o r d , e v e nt h o u g h i c o n t a i n s t h B A S I C k e y w o r d O R b e c a u s e t h e ' O R 'w o u l d b s u b s u m e d i n t o T r a n s B A S l C t o k e n b e f o r e B A S I Ch a c h a n c e t s e i t S T O R E , h o w e v e r , w o u l d n o b g o o dT r a n s B A S l C k e y w o r d b e c a u s e i w o u l d d i s a b l e B A S I C ' S R S T O R E c o m m a n d : R E S T O R E w o u l d b e c o m e R p l u s T r a n sB A S l C t o k e n . s i d e e f f e c t i t h a t i y o a r u s e d t a b b r e v i a t i n g B A S I C k e y w o r d s ( e . g . p f o P E E K ) y o m a f i n dt h a t T r a n s B A S l C h a s i n t r u d e d t t h e e x t e n t o c o m m a n d e e r i n gs o m e a b b r e v i a t i o n s t k e y w o r d s o i t o w ( e . g . e f o E X b e c o m e s e f o E X I T ) .

E x p a n d T o k e n : T h e s e c o n d r o u t i n e i t h T r a n s B A S l Ck e r n e l t a k e s c a r e o e x p a n d i n g t h t o k e n s b a c k i n t o k e y w o r d sf o L I S T . F a s c i n a t i n g f a c t : t h B A S I C k e y w o r d l i s t c o n t a i n se x a c t l y 2 5 c h a r a c t e r s p l u s a z e r o b y t e . T h i s i m a x i m u mc a p a c i t y t h l i s t i s s c a n n e d u s i n g i n d i r e c t i n d e x e d a d d r e s si n g , i n w h i c h t h i n d e x i o n e - b y t e v a l u e . T h s a m er e s t r i c t i o n a p p l i e s t T r a n s B A S I C ' s o w k e y w o r d l i s t ; t h e r ef o r e i i m p l e m e n t i n g l a r g e T r a n s B A S l C a p p l i c a t i o n , w i t hm a n y k e y w o r d s , t h t o t a l n u m b e r o k e y w o r d c h a r a c t e r s h a t b c o n s i d e r e d .

E x e c u t e S t a t e m e n t : T h t h i r d k e r n e l r o u t i n e i r e s p o n s i b l ef o e x e c u t i n g T r a n s B A S l C s t a t e m e n t s . ( I t h i s c o n t e x t , t h w o r d ' s t a t e m e n t ' r e f e r s t t h o s e c o m m a n d s t h a t , l i k e P R I N T ,P O K E , L O A D , e t c , m a b e u s e d a v e r b s i B A S I C i n s t r u ct i o n . ) T h i s r o u t i n e i f a i r l y s t r a i g h t f o r w a r d . O n c o m p l i c a t i o n ,t h o u g h , i t h a t t h I s t a t e m e n t i B A S I C d o e s n o e m p l o y t h e x e c u t e l i n k - v e c t o r w h e n e x e c u t i n g t h c l a u s e t h a t f o l l o w sT H E N ; i n s t e a d i j u m p s a c r o s s t h v e c t o r d i r e c t l y i n t o t h B A S I C R O M . N a t u r a l l y , t h R O k n o w s n o t h i n g a b o u t T r a n sB A S l C k e y w o r d s a n d t e n d s t i d e n t i f y t h e m a S Y N T A XE R R O R S . T g e a r o u n d t h i s d i f f i c u l t y t h I s t a t e m e n t i r e d e f i n e d i t h T r a n s B A S l C k e r n e l ( a n d a b o n u s a l l o w s a o f t e n - h a n d y E L S E c l a u s e ) .

E v a l u a t e E x p r e s s i o n E l e m e n t : T h e f o u r t h k e r n e l r o u t i n et a k e s c a r e o T r a n s B A S l C f u n c t i o n s ( ' f u n c t i o n s ' a r c o m m a n d st h a t , l i k e P E E K a n A B S , a r u s e d w i t h i n B A S I C e x p r e s s i o n s ,a n r e t u r n v a l u e ) . T r a n s B A S l C p e r m i t s v a r i e t y o f u n c t i o nt y p e s .

A p a r t f r o m t h e s e f o u r c r u c i a l r o u t i n e s , t h k e r n e l c o n t a i n s a s h o r ti n i t i a l i z a t i o n s e c t i o n , t h I a n E L S E s t a t e m e n t s d e s c r i b e d a b o v e ,a n d a n E X I T s t a t e m e n t , w h i c h d i s a b l e s T r a n s B A S l C a n r e s t o r e st h o l v a l u e s o t h f o u r l i n k v e c t o r s .

a s e l e c t i o n o n e c o m m a n d s t C o m m o d o r e 6 4 B A S I C , r e s u l t i n gi T r a n s B A S l C d i a l e c t t a i l o r e d t p a r t i c u l a r a p p l i c a t i o n . T h s o u r c e c o d e f o t h d i a l e c t i g e n e r a t e d i t w s t a g e s . F i r s t , t h T r a n s B A S l C k e r n e l ( P r o g r a m f o l l o w i n g t h i s a r t i c l e ) i l o a d e d f r o md i s k i n t o B A S I C m e m o r y s p a c e w i t h t h c o m m a n d :

L O A D " T B / K E R N E L " , 8

S e c o n d , m o d u l e s c o n t a i n i n g r o u t i n e s f o a d d e d c o m m a n d s a r m e r g e d w i t h t h e k e r n e l , a n l i n e 9 o t h c o m b i n e d p r o g r a m i u p d a t e d ( a d e s c r i b e d l a t e r ) t o r e f l e c t t h t o t a l n u m b e r o a d d e ds t a t e m e n t s a n f u n c t i o n s i t h d i a l e c t . T h m e r g i n g o m o d u l e sw i t h t h e k e r n e l i m o s t e a s i l y d o n e u s i n g t h T r a n s B A S l C A D s t a t e m e n t , w h i c h y o u w i l l h a v e a v a i l a b l e t y o a f t e r t y p i n g i t h p r o g r a m s t h a t a c c o m p a n y t h i s a r t i c l e .

I y o u w a n t t a v o i d t h e h a s s l e o t y p i n g i t h p r o g r a m s , o c o u r s e ,t h e y c a a l s o b e f o u n d o T h T r a n s a c t o r ' s p r o g r a m d i s k f o t h i si s s u e . I n t h a t c a s e y o c a s k i p f r o m h e r e d i r e c t l y t t h n e x ts e c t i o n , U s i n g T r a n s B A S l C .

P A c o m m e n t s ( b e g i n n i n g w i t h s e m i - c o l o n ) s h o u l d b e o m i t t e dw h e n y o t y p e i t h p r o g r a m s i o r d e r t c o n s e r v e d i s k a n m e m o r y s p a c e . T h B A S I C R E s t a t e m e n t s a t h b e g i n n i n g o t h s o u r c e f i l e s s h o u l d b e l e f t i n h o w e v e r , a t h e y c o n t a i n d o c u m e n t at i o n t h a t y o w i l l u s o c o n t i n u i n g b a s i s . A n o t h e r p o i n t t n o t ei t h a t t h l i n e n u m b e r s o t h s o u r c e p r o g r a m s a r n o t a b l yd i s c o n t i n u o u s . I i v e r y i m p o r t a n t t h a t y o f o l l o w t h e n u m b e r i n ge x a c t l y w h e n y o t y p e t h p r o g r a m s i n

O u m a i n t a s k h e r e i t s e u t h T r a n s B A S l C s y s t e m f o f u t u r eu s e ( t h o u g h w e ' l l a l s o b g e t t i n g d e c e n t h a n d f u l o n e w c o mm a n d s ) . T h i s m e a n s t y p i n g i t h r e e f i l e s t h a t y o u ' l l b u s i n g a g a i na n a g a i n : ' T R A N S B A S I C , ' T B / K E R N E L ' , a n d ' T B / A D D . O B J ' . T h f i r s t o f t h e s e , ' T R A N S B A S I C , a p p e a r s f o l l o w i n g t h i s a r t i c l e a P r o g r a m 4 I s h o u l d b t y p e d i a g i v e n , i n c l u d i n g t h e p e c u l i a rl o o k i n g l i n e 1 1 0 , w h i c h i a c t u a l l y t h t o k e n f o t h T r a n s B A S l CE X I T s t a t e m e n t . H o y o t y p e i t h o t h e r t w o p r o g r a m s d e p e n d so n w h e t h e r y o u h a v e h a n d y m e r g e r o u t i n e , l i k e t h o n i B r a dT e m p l e t o n ' s P O W E R / M O R E P O W E R p a c k a g e , o r t h e o n b y G l e nP e a r c e t h a t a p p e a r e d i T h T r a n s a c t o r l a s t y e a r ( a n d o w h i c h t h T r a n s B A S l C A D s t a t e m e n t i b a s e d ) . I y o d o h a v e m e r g er o u t i n e , f o l l o w t h e i n s t r u c t i o n s i B o 1 I y o d o n ' t , f o l l o w t h ei n s t r u c t i o n s i B o 2 E i t h e r w a y , w h e n y o u ' r e d o n e y o u ' l l h a v e i y o u r d i s k d i r e c t o r y t h e f o l l o w i n g n e f i l e s :

2 1 1

T B / A D D . O B J" T B / A D D . S R C" T B / K E R N E L "" A D D "

P R P R P R P R

A l t h a t r e m a i n s i t t y p e i t h ' S C R E E N T H I N G S ' m o d u l e , w h i c hi g i v e n a P r o g r a m 3 Y o a r n o i p o s i t i o n t c r e a t e y o u r o w T r a n s B A S l C d i a l e c t .

T y p i n g i t h p r o g r a m s

T h T r a n s B A S l C s y s t e m , a w h a v e s e e n , c o n s i s t s o n u m b e r o f i l e s w r i t t e n i P A s o u r c e c o d e . T h s y s t e m m a k e s i s i m p l e t a d T h T r a n s a c t o r 3 V o l u m e 5 I s s u e 0

Page 34: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 34/88

B o x l

F o l l o w t h e i n s t r u c t i o n s i t h i s b o i y o h a v e m e r g er o u t i n e a v a i l a b l e . T h s t e p s t b f o l l o w e d a r e :

1 T y p e i a n s a v e T R A N S B A S 1 C ( P r o g r a m 4 i y o h a v en o t a l r e a d y d o n e s o

2 T y p e i a n s a v e ' T B / K E R N E L ' ( P r o g r a m 1 )

3 T y p e i a n s a v e t h m o d u l e ' A D D ' ( P r o g r a m 2 )

4 M e r g e T B / K E R N E L ' w i t h ' A D D ' a n a l t e r l i n e 9 o t h c o m b i n e d r e s u l t t r e a d a f o l l o w s :

9 X T R A . B Y T E 3 , S T M T S . F N C S

N o s a v e t h c o m b i n e d p r o g r a m a ' T B / A D D . S R C .

5 A s s e m b l e T B / A D D . S R C w i t h P A L , a n s a v e t h o b j e c t c o d e a T B / A D D . O B J ' . T h i s i t h e o b j e c t f i l ef o t h T r a n s B A S I C m i n i - d i a l e c t t h a t e n a b l e s t h A D c o m m a n d .

U s i n g T r a n s B A S I C

T h i s i t h e a s y p a r t . T h f i r s t s t e p i t l o a d a n r u t h p r o g r a m' T r a n s B A S I C ( p r o g r a m 4 ) N o s e l e c t t h m o d u l e s y o n e e d f r o mt h o s e y o h a v e o n d i s k ( a p r e s e n t , o c o u r s e , t h e r e a r e o n l y t w o ) .T h e n , f o e a c h m o d u l e , f o l l o w t h e s e s t e p s :

1 U s t h A D s t a t e m e n t t m e r g e t h m o d u l e i n t o m e m o r y , f o e x a m p l e :

A D " S C R E E N T H I N G S "

( T h e o n l y o t h e r a l t e r n a t i v e u n t i l n e x t i s s u e i s A D A D D " ) .

2 ) L i s t l i n e o y o u r p r o g r a m . T h i s l i n e n u m b e r i c o m m o n t a l m o d u l e s . I w i l l r e a d s o m e t h i n g l i k e :

R E S T A T E M E N T S , F U N C T I O N S

3 ) L i s t l i n e 9 5 T h i s k e r n e l l i n e r e c o r d s t h n u m b e r o s t a t e m e n t sa n f u n c t i o n s i t h T r a n s B A S I C t h a t y o a r c r e a t i n g . W h e ny o f i r s t l o a d i t h k e r n e l , l i n e 9 r e a d s :

9 X T R A . B Y T E 2 , S T M T S . F N C S

( t h i s i o n l i n e w h e r e m a k e a e x c e p t i o n a n r e t a i n t h c o m m e n t ) , i n d i c a t i n g t h a t t h e k e r n e l c o n t a i n s t w s t a t e m e n t s( E L S E a n d E X I T ) a n n f u n c t i o n s . Y o a r e r e s p o n s i b l e f o u p d a ti n g t h e t w n u m b e r s a p p r o p r i a t e l y a y o u a d d m o d u l e s . A f t e ra d d i n g S C R E E N T H I N G S , f o i n s t a n c e , t h f i r s t n u m b e r i l i n e 9 w o u l d b i n c r e a s e d b f i v e , t h s e c o n d w o u l d b l e f t u n c h a n g e d .

W h e n y o h a v e f i n i s h e d a d d i n g m o d u l e s , i w o u l d p r o b a b l y b g o o d i d e a t s a v e t h c o m p l e t e d s o u r c e f i l e , a l e a s t t e m p o r a r i l y .T h e n l o a d P A L , i y o h a v e n ' t p r e v i o u s l y , a n r u y o u r p r o g r a m .

B o

F o l l o w t h e i n s t r u c t i o n s i n t h i s b o i y o d o n ' t h a v e m e r g er o u t i n e . T h s t e p s t b e f o l l o w e d a r e :

1 T y p e i a n s a v e T R A N S B A S I C ( P r o g r a m 4 i y o u h a v en o t a l r e a d y d o n e s o

2 T y p e i a n s a v e T B / K E R N E L ' ( P r o g r a m 1 )

3 W i t h o u t N E W i n g a f t e r s t e p 2 t y p e i t h m o d u l e ' A D D '( P r o g r a m 3 ) C h a n g e l i n e 9 o t h c o m b i n e d r e s u l t t r e a d a f o l l o w s :

9 X T R A . B Y T E 3 , S T M T S . F N C S

N o s a v e t h c o m b i n e d p r o g r a m a ' T B / A D D . S R C

5 A s s e m b l e ' T B / A D D . S R C w i t h P A L , a n s a v e t h o b j e c tc o d e a T B / A D D . O B J ' . T h i s i t h o b j e c t f i l e f o t h T r a n s B A S I C m i n i - d i a l e c t t h a t e n a b l e s t h A D c o m a n d .

6 D e l e t e f r o m T B / A D D . S R C a l t h l i n e s b e l o n g i n g t ' T B /K E R N E L ' . S a v e t h r e s u l t o t h i s o p e r a t i o n a ' A D D ' .

N o r m a l l y t h e o b j e c t c o d e i o r i g i n e d t t h a t p o p u l a r n i c h e a $ C 0 0 0 , b e t w e e n B A S I C a n t h I / r e g i s t e r s , b u y o u c a n s e l e c ta n o t h e r s t a r t i n g p o i n t i y o w i s h ( s e e l i n e 3 o t h s o u r c e c o d e ) .S a v e t h o b j e c t c o d e d i r e c t l y , p e r h a p s w i t h S u p e r m o n , o c o n v e r t i i n t o D A T A s t a t e m e n t s t h a t c a n b e l o a d e d i w i t h w h a t e v e r p r g r a m o p r o g r a m s y o i n t e n d s h a l l m a k e u s o t h a d d e d c o m a n d s . F o t h l a t t e r p u r p o s e a l w a y s u s t h D a t a f i e r , w h i c h y o uc a f i n d e l s e w h e r e i n t h i s i s s u e , s i n c e i p a c k s t h D A T A s t a t em e n t s m o r e c o m p a c t l y a n d u n p a c k s t h e m m o r e p r o m p t l y t h a n i o t h e r w i s e p o s s i b l e .

W i t h t h a t , t h w o r k i d o n e . T a c t i v a t e t h n e w c o m m a n d s t y p eS Y 4 9 1 5 2 . P r e s t o ! y o u h a v e j u s t e x t e n d e d B A S I C t y o u r o w s p e c i f i c a t i o n s , a n n o i t ' s r e a d y f o u s e . N o o n l y t h a t b u t o m o r r o w y o u c a n d o i a g a i n , w i t h d i f f e r e n t s e o a d d e dc o m m a n d s , a n a g a i n t h d a a f t e r t h a t , t o s u i t y o u r m o m e n t a r yn e e d s ( a t l e a s t , y o w i l l b a b l e t w h e n y o u r c o l l e c t i o n o m o d u l e sh a g r o w n b i t ) .

T h i s k i n d o f l e x i b i l i t y c o u l d h a v e i n t e r e s t i n g c o n s e q u e n c e s . C o s i d e r a s e t o f T r a n s B A S I C m o d u l e s e n c o m p a s s i n g m a n y h u n d r e d so c o m m a n d s . I i l i k e l y t h a t w i t h t h a t s i z e o k e y w o r d v o c a b u l a r yo u n o t i o n o B A S I C , a n o p r o g r a m m i n g l a n g u a g e s i g e n e r a l ,w i l l r e m a i n u n c h a n g e d ? W h e n w a r e a b l e s o r e a d i l y t m o d i f y t h l a n g u a g e i t s e l f t a a p p l i c a t i o n , h o w m u c h t i m e p r o p o r t i o n a t e l yw i l l b s p e n t o t h a c t u a l c o d i n g , a n h o m u c h o c a r e f u l l yc o n s i d e r i n g w h i c h c o m m a n d s t e n a b l e ?

M o r e o n t h o s e q u e s t i o n s a n o t h e r t i m e . M u n d a n e m a t t e r s d e m a n do u a t t e n t i o n .

F o o n t h i n g , w o r d o w a r n i n g .

A m e n t i o n e d a b o v e , T r a n s B A S I C h i j a c k s f o u r i m p o r t a n t B A S I Cv e c t o r s a n r e r o u t e s t h e m t h r o u g h i t o w p r o g r a m s p a c e . B e

T h T r a n s a c t o r 3 V o l u m e 5 I s s u e 0

Page 35: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 35/88

w a r e , t h e r e f o r e , o o v e r w r i t i n g y o u r T r a n s B A S I C d i a l e c t w i t ha n o t h e r p r o g r a m , o e v e n w i t h a n o t h e r T r a n s B A S I C d i a l e c t , a s t h ev e c t o r s w i l l b s c r a m b l e d , a n d y o u r c o m p u t e r w i l l c r a s h m o s ta g o n i z i n g l y w h i l e y o l o o k h e l p l e s s l y o n T h m o r a l : a l w a y s u s t h T r a n s B A S I C E X I T c o m m a n d t r e s t o r e t h o l v e c t o r s b e f o r ey o d a n y t h i n g n e w i t h t h m e m o r y w h e r e T r a n s B A S I C i r o o s t i n g .

A n n o l o o k i n t o t h f u t u r e .

F r o m n o o n n e T r a n s B A S I C m o d u l e s , e a c h a d d i n g o n o m o r ec o m m a n d s t y o u r c o l l e c t i o n , w i l l b r e g u l a r f e a t u r e i T h T r a n s a c t o r . S o m e m o d u l e s w i l l d e a l w i t h s p r i t e s , s o m e w i t h t h S I c h i p . S o m e w i l l o f f e r s o p h i s t i c a t e d s t r i n g h a n d l i n g c o m m a n d st h a t m i g h t b e w a n t e d , f o e x a m p l e , i p r o g r a m m i n g a d v e n t u r eg a m e s . S o m e m o d u l e s m a o f f e r c o m m a n d s n o t a v a i l a b l e i a n c o m p u t e r l a n g u a g e y e e x i s t i n g , a n n o y e t h o u g h t o b a n y o n ee x c e p t y o u .

Y o s e e , d o n ' t w a n t t w r i t e a l t h e s e n e c o m m a n d s m y s e l f . P a r to w h a t T r a n s B A S I C i a l a b o u t i t h a t i o f f e r s m e a n s w h e r e b ya l m o s t a n y o n e c a m a k e a c o n t r i b u t i o n t t h g r o w t h o B A S I C ,o u c o m m o n t o n g u e , a n t h r e s t o f u s c a n b e n e f i t . M a n y r e a d e r s ,a s u r e , a l r e a d y h a v e t h e e x p e r t i s e t w r i t e a n e c o m m a n d ;o t h e r s w i l l r e q u i r e o n l y l i t t l e i n f o r m a t i o n t g e t h e m s t a r t e d ( a n dw i l l f i n d i i t h n e x t i s s u e ) . B u e v e n t h o s e w h o s e m a c h i n el a n g u a g e p r o g r a m m i n g s k i l l s a r r u d i m e n t a r y c a n c o n t r i b u t e t t h e e x t e n t o s e n d i n g i t h e i r i d e a s f o c o m m a n d s t h e y w o u l d l i k et s e e , e v e n i t h e y c a n ' t p r o v i d e t h e c o d e .

N e x t i s s u e w e ' l l l o o k a s o m e r o u t i n e s i t h B A S I C R O t h a t a r h e l p f u l o n e c e s s a r y f o w r i t i n g T r a n s B A S I C c o m m a n d s , e x a m i n e

m a o T r a n s B A S I C l i n e r a n g e a l l o c a t i o n s , r e s p o n d t q u e s t i o n sr e a l o i m a g i n e d , a n w h a t e v e r e l s e f i t s . S e y o t h e n .

N e C o m m a n d s

T h i s p a r t o t h T r a n s B A S I C c o l u m n i d e v o t e d t d e s c r i b i n g t h en e w c o m m a n d s t h a t w i l l b a d d e d e a c h i s s u e . T h d e s c r i p t i o n sf o l l o w a s t a n d a r d f o r m a t :

T h f i r s t l i n e g i v e s t h e c o m m a n d k e y w o r d , t h e t y p e ( s t a t e m e n t o rf u n c t i o n ) , a n t h r e e d i g i t s e r i a l n u m b e r .

T h s e c o n d l i n e g i v e s t h l i n e r a n g e a l l o t t e d t t h e x e c u t i o nr o u t i n e f o t h c o m m a n d .

T h t h i r d l i n e g i v e s t h e m o d u l e i w h i c h t h c o m m a n d i i c l u d e d .

T h f o u r t h l i n e ( a n d t h e f o l l o w i n g l i n e s , i n e c e s s a r y ) d e m o n s t r a t et h c o m m a n d s y n t a x .

T h r e m a i n i n g l i n e s d e s c r i b e t h e c o m m a n d .

I ( T y p e : S t a t e m e n t C a * 0 0 0 )L i n e R a n g e : 2 4 7 4 - 2 5 1 2M o d u l e : T B / K E R N E LE x a m p l e : I T H E N P R I N TT h I s t a t e m e n t i r e d e f i n e d t a c c e p t T r a n s B A S I C s t a t e m e n t s i t h T H E N - c l a u s e . A l s o , a E L S E h a b e e n a d d e d ( O O l ) .

E L S E ( T y p e : S t a t e m e n t C a * 0 0 1 )L i n e R a n g e : 2 5 1 4 - 2 5 4 0M o d u l e : T B / K E R N E LE x a m p l e : I T H E N P R I N T B E L S E P R I N TW h e n t h e t e s t - e x p r e s s i o n o a I s t a t e m e n t f a i l s , t h r e m a i n d e r o t h l i n e i s c a n n e d f o s t a t e m e n t b e g i n n i n g w i t h E L S E . I o n i f o u n d , t h e s t a t e m e n t s f o l l o w i n g a r e e x e c u t e d . T h f i r s t E L S E a f t e rt h f a i l e d e x p r e s s i o n i t h o n u s e d E L S E s a r e n o t m a t c h e da g a i n s t i F s . E x c e p t a f t e r f a i l e d I s t a t e m e n t , E L S E i r e f e r r e d t R E a n h a n e f f e c t .

E X I T ( T y p e : S t a t e m e n t C a * 0 0 2 )L i n e R a n g e : 2 5 4 2 - 2 5 5 8M o d u l e : T B / K E R N E LE x a m p l e : E X I TD e a c t i v a t e s T r a n s B A S I C . T r a n s B A S I C m a b r e a c t i v a t e d w i t h S Y 4 9 1 5 2 .

G R O U N D ( T y p e : S t a t e m e n t C a t * 0 1 3 )L i n e R a n g e : 2 7 4 0 - 2 7 4 6M o d u l e : S C R E E N T H I N G SE x a m p l e : G R O U N D 2 R E R E B A C K G R O U N DT h b a c k g r o u n d c o l o u r i s e t t o t h s p e c i f i e d c o l o u r .

F R A M E ( T y p e : S t a t e m e n t C a * 0 1 4 )L i n e R a n g e : 2 7 4 8 - 2 7 5 4M o d u l e : S C R E E N T H I N G SE x a m p l e : F R A M E 4 R E P U R P L E B O R D E RT h b o r d e r c o l o u r i s e t t h s p e c i f i e d c o l o u r .

T E X T ( T y p e : S t a t e m e n t C a * 0 1 5 )L i n e R a n g e : 2 7 5 6 - 2 7 6 6M o d u l e : S C R E E N T H I N G SE x a m p l e : T E X T 1 R E W H I T E P R I N TT h s c r e e n p r i n t c o l o u r i s e t .

C R A M ( T y p e : S t a t e m e n t C a t * : 0 1 6 )L i n e R a n g e : 2 7 6 8 - 2 7 8 8M o d u l e : S C R E E N T H I N G SE x a m p l e : C R A MC o l o u r m e m o r y i f i l l e d w i t h t h s p e c i f i e d v a l u e .

C L ( T y p e : S t a t e m e n t C a * 0 1 7 )L i n e R a n g e : 2 7 9 0 - 2 8 3 2M o d u l e : S C R E E N T H I N G SE x a m p l e : C L R E C L E A R S C R E E N , H O M E C U R S O RE x a m p l e : C L 1 R E C L E A R S C R E E N , L I N E 1 T B O T T O ME x a m p l e : C L 4 , 7 : R E C L E A R L I N E S T H R O U G HI t h s e c o n d a n d t h i r d f o r m s o t h c o m m a n d t h e c u r s o r p o s i t i o ni n o a f f e c t e d . A l l t h r e e f o r m s c l e a r c o l o u r m e m o r y t b a c k g r o u n dc o l o u r i t h r a n g e c o r r e s p o n d i n g t t h l i n e s c l e a r e d o t h s c r e e n .

A D ( T y p e : S t a t e m e n t C a * 0 5 5 )L i n e R a n g e : 4 4 7 4 - 4 8 0 4I M o d u l e ( s ) : A D E x a m p l e : A D V O C A B M A N A G E R "E x a m p l e : A D " W I T H I N " , T h n a m e d f i l e i m e r g e d w i t h t h e p r o g r a m i m e m o r y . I n d e v i c e n u m b e r i g i v e n t h d e f a u l t i e i g h t . T h f i l e n u m b e r a n s e c o n d a r y a d d r e s s u s e d i $ 6 ( 9 9 ) . T h r o u t i n e u s e d i b a s e d o p r o g r a m b y G l e n P e a r c e i T h T r a n s a c t o r , v o l u m e 5 i s s u e 2

3

Page 36: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 36/88

P r o g r a mr e t r a n s b a s i c k e r n e l ( s e t p 2 7 / 8 4 )

r e 2 s t a t e m e n t s . f u n c t i o n s

r e m k e y w o r d c h a r a c t e r s :

6 r e m k e y w o r d r o u t i n er e s / e l s e e l s r t nr e s / e x i t e x

l i n e s e 2 5 1 4 0 0 2 5 4 2 0 0 2

1 r e u t i l i t y : c i f c h r ( 2 5 6 0 / 0 0 3 )1 1 r e k e r n e l a l s o i n c l u d e s m o d i f i e d1 r e ' i s t a t e m e n t ( i f r t n / 2 4 7 4 / 0 0 0 )1 2 i f p e e k ( 7 7 3 ) < 1 9 2 g o t o 2 9 r e l e s t i f

t r a n s b a s i c a l r e a d y e n a b l e d2 2 « - a : r e ' e x i t ' s t a t e m e n t t o k e n2 2 s y 7 0 3 . o p t o 3 = $ c 0 0 03 3 t = 3 t = 3 t = 3 1 = 3 t = 3 9 9 j m s t a r t9 j m e x 9 9 x t r a . b y t e 2 , 9 9 . b y t e O9 9 s k

1 0 0 a s c ' e l s E e x i T5 9 5 9 f k

1 0 9 61 0 9 7 . b y t e1 0 9 81 0 9 9 c m d s

i t r a n s b a s i c t a k e s o v e r t h l u n u s e d l o c a t i o n a 2 a n ; t h e n u m e r i c c o n v e r s i o n; v e c t o r s a a n f o i t ; z e r o p a g e w o r k s p a c e

l e m e r g e n c y e x i t s y 4 9 1 5 5

i s t m t s . f u n c s

; s t a t e m e n t k e y w o r d l i s t

f u n c t i o n k e y w o r d l i s t

0 ; k e y w o r d l i s t t e r m i n a t o r

i s t a t e m e n t v e c t o r s1 1 0 0 . w o r d $ a 9 3 a , e x t - 11 5 9 81 5 9 9 f n c s2 0 9 92 1 0 0 s t a r t I d # 2 1 0 2 s t t i I d $ 3 0 4 , x2 1 0 4 s t t v e c x2 1 0 6 I d n u v e c s . x2 1 0 8 s t $ 3 0 4 , x2 1 1 0 d e 2 1 1 2 b p s t t i2 1 1 4 I d x t r a2 1 1 6 c l 2 1 1 8 a d c x t r a + 12 1 2 0 s t x t r a2 1 2 2 I d # $ 6 02 1 2 4 s t s t a r t2 1 2 6 r t 2 1 2 82 1 3 0 t v e c , w o r d $ a 5 7 c2 1 3 2 I v e c w o r d $ a 7 1 a2 1 3 4 e v e c , w o r d $ a 7 e 42 1 3 6 f v e c w o r d $ a e 8 62 1 3 8

f u n c t i o n v e c t o r s

; s w a p o u o l i b a s i c v e c t o r s .i s w a p i n e o n e s

; c a l c u l a t e t o t a l; n e w k e y w o r d s

; d i s a b l e t h i s; r o u t i n e w i t h r t

i s t o r a g e f o ; o l d v e c t o r s

2 1 4 0 n u v e c s . w o r d t o k . h s . e x e , f u n ; n e w v e c t o r s2 1 4 22 1 4 4 t o k I d x # 2 1 4 6 I d # 2 1 4 8 t k I d $ 2 0 0 , x2 1 5 0 c m # $ 2 22 1 5 2 b e q t k 2 1 5 4 j s c i f c h r2 1 5 6 b c t k 2 1 5 8 s t $ 7 2 1 6 0 s t t 2 1 6 2 I d # 2 1 6 4 s t $ 0 2 1 6 6 d e 2 1 6 8 d e 2 1 7 0 t k 2 i n y2 1 7 2 i n 2 1 7 4 t k I d $ 2 0 0 . x2 1 7 6 s e 2 1 7 8 s b s k w . y2 1 8 0 b e q t k 2 1 8 2 c m # $ 8 02 1 8 4 b n e t k 2 1 8 6 I d # $ 5 f2 1 8 8 I d $ 7 2 1 9 0 s t $ 2 0 0 . y

T h T r a n s a c t o r

i t o k e n i z e

f e t c h b y t e; c h e c k f o o p e n q u o t e

; c h e c k f o a l p h a b e t i c; s k i p i f n o ; s a v e . a n .

; s e t u c o u n t e r; s e t u i n d i c e s

; f e t c h u n t o k e n i z e d b y t e

i c o m p a r e w i t h k e y w o r d l i s t: g b a c k f o a n o t h e r b y t e; c h e c k f o m a t c h e x c e p t h i g h b i ; t r y n e x t k e y w o r d; f i r s t b y t e o t o k e n ,; t h e l e f t a r r o w

2 1 9 22 1 9 42 1 9 62 1 9 8 t k 2 2 0 02 2 0 22 2 0 42 2 0 62 2 0 82 2 1 02 2 1 2 t k 2 2 1 4 t k 2 2 1 62 2 1 82 2 2 02 2 2 2 t k 2 2 2 42 2 2 62 2 2 82 2 3 02 2 3 22 2 3 42 2 3 62 2 3 82 2 4 0 t k 2 2 4 22 2 4 42 2 4 62 2 4 8 t k 2 2 5 02 2 5 22 2 5 42 2 5 62 2 5 8 l i 2 2 6 02 2 5 22 2 6 42 2 6 62 2 6 82 2 7 02 2 7 22 2 7 4 1 2 2 7 62 2 7 82 2 8 02 2 8 2 1 2 2 8 42 2 8 62 2 8 8 1 2 2 9 02 2 9 22 2 9 42 2 9 6 1 2 2 9 82 3 0 02 3 0 22 3 0 42 3 0 62 3 0 82 3 1 02 3 1 2 1 2 3 1 42 3 1 62 3 1 82 3 2 02 3 2 22 3 2 42 3 2 62 3 2 8 1 2 3 3 02 3 3 2 e x 2 3 3 4 e x 2 3 3 62 3 3 82 3 4 02 3 4 22 3 4 42 3 4 62 3 4 82 3 5 0 e x 2 3 5 22 3 5 42 3 5 62 3 5 82 3 6 0 e x 2 3 6 22 3 6 42 3 6 62 3 6 82 3 7 02 3 7 22 3 7 42 3 7 62 3 7 82 3 8 0 e x 52 3 8 22 3 8 42 3 8 6 e x

i n I d $ 0 a d # $ 3 fi n s t $ 2 0 0 , i n I d $ 2 0 0 , yb n t k j m ( t v e c )

I d t i n $ 0 I d $ 0 c m # $ 1 eb e t k i n I d s k w - 1 . yb p l t k 7I d s k w . yb n t k I d $ 7 I d $ 2 0 0 , xb p l I k 4

I d $ 2 0 0 . xb e t k c m # $ 2 2b e t k s t $ 2 0 0 , yi n i n b n t k

c m # $ 5 fb n 1 i n I d ( $ 5 f ) . ys b # $ 4 0c m # $ 1 eb c 1 s b # c m x t r a +b c 1 d e I d ( $ 5 f ) , yt a j m ( I v e c )

s t y t 3I d # t a b e 1 I d s k w . yp h i n p i b p 1 d e b n 1

I d s k w . yp h a n # $ 7 fj s $ a b 4 7i n p i b p 1 I d t j m p $ a 7 0 0

j s $ 7 c m # $ 8 bb e q e x 8c m # $ 5 fb n e x j s $ 7 j s e x j m $ a 7 a e

s e s b # $ 4 0c m # $ 1 eb c c e x 3s b #

i s e c o n d b y t e o t o k e n

; l o o p u n l e s s l i n e e x h a u s t e d

i r e j o i n b a s i c

; f i n d n e x t k e y w o r d

; s k i p p a s t e x p o n e n t i a t e t o k e n

; n m a t c h i n g k e y w o r d .: g i v e u a t t e m p t t i t o k e n i z e

i s c a n f o e n o ; l i n e o e n o i q u o t e s w i t h o u t; t o k e n i z i n g

; l i s t e x p a n d t o k e n s; s k i p i f n o l e f t - a r r o w; g e t n e x t b y t e ,i c o n v e r t t t o k e ni n u m b e r

i c h e c k i f i b o u n d s; g s c a n k e y w o r d l i s t

; r e j o m b a s i c

i c o u n t d o w n i , : w h i ! e s c a n n i n gk e y w o r d l i s t

; l a s t k e y w o r di c h a r a c t e r h a b i ; 7 s e t

i p r i n t k e y w o r d; u s i n g b a s i c ' s; c h a r a c t e r - p r i n t: r o u t i n e a t $ a b 4 7

. r e j o i n b a s i c

l e x e c u t e s t a t e m e n t; ' i f h a n d l e a i f r t n

; t h e l e f t a r r o wi s k i p t o r e j o i n b a s i c; g e t n e x t b y t e; e x e c u t e; s e t u n e x t s t a t e m e n t

i c o n v e r t t o k e n t ; k e y w o r d n u m b e r

c m x t r a ; c h e c k i f i b o u n d sb c s e x 7 ; s y n t a x e r r o ra s t a I d c m d s + , ; f e t c h v e c t o rp h ; a d d r e s s f r o m t a b l eI d c m d s . yp h j u m p t h r o u g h c h r g e tj m p $ 7 3 ; t s t a t e m e n t r o u t i n e

I d $ 7 b n e x d e c $ 7 bd e c $ 7 a

; d e c r e m e n t c h r g e ti p o m t e r

3

2 3 8 82 3 9 02 3 9 22 3 9 42 3 9 62 3 9 82 4 0 02 4 0 22 4 0 42 4 0 62 4 0 82 4 1 02 4 1 22 4 1 42 4 1 62 4 1 82 4 2 02 4 2 22 4 2 42 4 2 62 4 2 82 4 3 02 4 3 22 4 3 42 4 3 62 4 3 82 4 4 02 4 4 22 4 4 42 4 4 62 4 4 82 4 5 02 4 5 22 4 5 42 4 5 62 4 5 82 4 6 02 4 6 22 4 6 42 4 6 62 4 6 82 4 7 02 4 7 22 4 7 42 4 7 62 4 7 82 4 8 02 4 8 22 4 8 42 4 8 62 4 8 82 4 9 02 4 9 22 4 9 42 4 9 62 4 9 82 5 0 02 5 0 22 5 1 22 5 1 42 5 1 62 5 1 82 5 2 02 5 2 22 5 2 42 5 2 62 5 2 82 5 3 02 5 3 22 5 3 42 5 3 62 5 3 82 5 4 02 5 4 22 5 4 42 5 4 62 5 4 82 5 5 02 5 5 22 5 5 42 5 5 62 5 5 82 5 6 02 5 6 22 5 6 42 5 6 62 5 6 82 5 7 02 5 7 25 2 2 25 2 2 4

e x

e x

e x

f u

f u

f u

f u

i f r t n

i f

i f

e l s r t n

e l s 1

e x e x l l

c i f c h r

j m ( e v e c )

j m $ a f O 8

j s e x j m p $ a 7 a e

I d a # > i f r t n - 1p h I d a # < i f r t n - 1p h j m p $ 7 3

j s $ 7 c m # $ 5 fb e f u I d $ 7 b n f u d e c $ 7 bd e c $ 7 aj m ( f v e c )

I d # s t $ 0 j s $ 7 s e s b # $ 4 0c m # $ 1 eb c f u s b # s e s b x t r ab c c e x 7c m x t r ab c e x a s t a I d f n c s , p h I d a f n c s . yp h j m p $ 7 3

j s $ a d 9 ej s $ 7 c m # $ 8 9b e i fI d # $ a 7j s $ a e f fj s $ 7 I d $ 6 b e e l s r t nb c i f j m p $ a 8 a Op l p l j s $ 7 j m e x

j s $ a 8 f 8j s $ 7 c m p # 0b n e l s 1r t j s $ 7 c m # $ 5 fb n e l s r t nj s $ 7 c m # $ 4 0b n e l s r t nj s $ 7 j m i !

I d # I d t v e c . xs t $ 3 0 4 , xd e b p l e x t 1I d # $ a 2s t s t a r tj m p d o w n

c m # $ 5 bb c c i c l b c c i c 2

c i c m # $ 4 1c i c 2 r t

p d o w n r t

; r e j o i n b a s i c

. s y n t a x e r r o r

; e x e c u t e ' i ; s e t u n e x t s t a t e m e n t

; j u m p t ; ' i f e x e c u t i o n; r o u t i n e

; e v a l u a t e f u n c t i o n; l e f t a r r o we v a l u a t e t r a n s b a s i c f u n l i o n

d e c r e m e n t e n r g e t; p o i n t e r .; r e j o i n b a s i c

: c l e a r d a t a t y p e r e g i s t e r

; f e t c h k e y w o r d i . d . b y t ei c o n v e r t t k e y w o r d n u m b e r

i c h e c k i f i r a n g e

i s y n t a x e r r o r

i s y n t a x e r r o r; f e t c h f u n c t i o ni v e c t o r f r o m t a b l e

; j u m p t f u n c t i o n; r o u t i n e t h r o u g h c h r g e t

l e v a l u a t e t e s t e x p r e s s i o n

; m u s t b f o l l o w e d b : g o t o ( $ 8 9 ); o r t h e n ( $ a 7 )

; c l e a r c a r r y o n n u m e r i c; c h e c k i f t e s t f a i l e d; y e s — s k i p t e l s e

; g o t ol e x e c u t e s t a t e m e n tl a t t e r ' t h e n '

; s k i p s t a t e m e n t

; r t s i f e n ; o l i n e

i c h e c k f o e l s ei t o k e n

; e x e c u t e

; e x i t r o u t i n ei r e s t o r e o l i v e c t o r s

i r e s t o r e I d c o d e t l e n a b l e s t a r t r o u t i n e; d p o w d o w n c o m m a n d i f p r e s e n t

i r e t u r n c a r r y s e l i a c c u m u l a t o ri c o n t a i n s; a l p h a b e t i c

; f o r u s e r s o ' p o w e r '

V o l u m e 5 I s s u e 0

Page 37: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 37/88

P r o g r a mr e a d ( s e p t 2 7 / 8 4 )

r e s t a t e m e n t , f u n c t i o n s

r e k e y w o r d c h a r a c t e r s : 3

r e k e y w o r d r o u t i n e l i n e s e r e m a d d x a d d 4 4 7 4 0 5 5

r e e / i o r t n s ( 3 9 / 0 5 6 )1 1 r e m = = = = = = = = = = = = = = =1 3 s e t l f s $ f f b a ; i / o r o u t i n e4 s e t n a m $ f f b d a d d r e s s e s i 4 o p e n = $ e 1 c 1 ; k e r n a l r o 4 c h k i n $ e 1 1 e4 c l o s e = $ e 1 c c4 d r c h n S f f c c4 g e t i n $ e 1 2 44

1 1 . a s c ' a d D '1 1 1 4 . w o r d x a d d - 14 4 7 4 x a d d j s $ a d 9 e ; g e t f i l e n a m e4 4 7 6 j s $ b 6 a 34 4 7 8 s t 1 ; s a v e l e n g t h4 4 8 0 t x 4 4 8 2 p h 4 4 8 4 t y 4 4 8 6 p h 4 4 8 8 I d 1 4 4 9 0 j s $ b 4 7 d ; r e s e r v e s p a c e4 4 9 2 t a 4 4 9 4 b n e x a 4 4 9 6 j m p $ a f O 8 m u l l s t r i n g s y n t a x e r r o r4 4 9 8 x a c l ; a d d , p t f i l e n a m e4 5 0 0 a d # 4 5 0 2 s t t 4 5 0 4 j s $ b 4 7 d4 5 0 6 t a 4 5 0 8 p l 4 5 1 0 s t $ 2 4 5 1 2 p l 4 5 1 4 s t $ 2 4 5 1 6 d e 4 5 1 8 I d # " p '4 5 2 0 s t a ( $ 6 2 ) , y4 5 2 2 d e 4 5 2 4 I d # " . "4 5 2 6 s t ( $ 6 2 ) . 4 5 2 8 x a 2 d e y4 5 3 0 b m i x a 34 5 3 2 I d a ( $ 2 2 ) , y4 5 3 4 s t ( $ 6 2 ) , 4 5 3 6 b n x a 4 5 3 8 x a I d t ; s e t u f o s e t n a m4 5 4 0 I d $ 6 4 5 4 2 I d $ 6 4 5 4 4 j s s e t n a m4 5 4 6 j s $ 7 : c h e c k f o r4 5 4 8 b e x a ; d e y i c e n u m b e r4 5 5 0 j s $ a e f d4 5 5 2 j s $ b 7 9 e4 5 5 4 . b y t e $ 2 4 5 5 6 x a I d # ; d e f a u l t d e v i c e4 5 5 8 I d # $ 6 3 ; f i l e n u m b e r a n 4 5 6 0 t a s e c o n d a r y a d d r 9 94 5 6 2 j s s e t l f s4 5 6 4 j s o p e n4 5 6 6 I d # $ 6 34 5 6 8 j s c h k i n ; o p e n c h a n n e l4 5 7 0 j s d s k g e t : s k i p l o a d a d d r e s s4 5 7 2 j s d s k g e t4 5 7 4 x a j s d s k g e t ; l i n e l i n k l o 4 5 7 8 j s d s k g e t : e n d o z e r o h i g h b y t e4 5 8 0 b n e x a 74 5 8 2 j s c l s c l r ; w r a p u i / 4 5 8 4 j s $ a 6 5 9 ; r e s e t c h r g e t p t r , c l 4 5 8 6 j m $ e 3 8 6 ; ' r e a d y . '4 5 9 0 x a j s d s k g e t : s a v e l i n e n u m b e r4 5 9 2 s t $ 1 4 5 9 4 j s d s k g e t4 5 9 6 s l $ 1 4 5 9 8 I d # 4 6 0 0 x a j s d s k g e t ; m o v e r e s t o f4 6 0 2 s t $ 2 0 0 , y ; l i n e t o i n p u t4 6 0 4 b e q x a i b u f f e r4 6 0 6 i n 4 6 0 8 b n x a 4 6 1 0 x a t y ; s a v e l i n e s i z e4 6 1 2 c l 4 6 1 4 a d c # 54 6 1 6 s t $ 0 4 6 1 8 j s $ a 6 1 3 i s e a r c h f o r l i n e4 6 2 0 b e c x a 1 3 : s k i p i f n o f o u n d4 6 2 2 I d #

4 6 2 4 I d ( $ 5 f ) , y ; d e l e t e l i n e4 6 2 6 s t $ 2 4 6 2 8 I d $ 2 4 6 3 0 S t $ 2 4 6 3 2 I d $ 6 4 6 3 4 s t $ 2 4 6 3 6 I d $ 5 4 6 3 8 d e 4 6 4 0 s b ( $ 5 f ) , y4 6 4 2 d 4 6 4 4 a d c $ 2 d4 6 4 6 s t $ 2 4 6 4 8 s t $ 2 4 6 5 0 I d $ 2 4 6 5 2 a d # $ f f4 6 5 4 s t $ 2 4 6 5 6 s b $ 6 4 6 5 8 t a 4 6 6 0 s e 4 6 6 2 x a 1 0 b e x a : l i n k4 6 6 4 I d $ 5 4 6 6 6 S b $ 2 4 6 6 8 t a 4 6 7 0 b e x a 1 14 6 7 2 i n 4 6 7 4 d e c $ 2 54 6 7 6 x a 1 1 d 4 6 7 8 a d c $ 2 24 6 8 0 b e c x a 1 24 6 8 2 d e c $ 2 34 6 8 4 d 4 6 8 6 x a 1 2 I d ( $ 2 2 ) , y4 6 8 8 s t ( $ 2 4 ) , y4 6 9 0 i n 4 6 9 2 b n e x a 1 24 6 9 4 i n $ 2 4 6 9 6 i n $ 2 4 6 9 8 d e 4 7 0 0 b n e x a 1 24 7 0 2 x a 1 3 j s $ a 6 6 3 : c l r4 7 0 4 i s $ a 5 3 3 ; r e - l i n k4 7 0 6 c l 4 7 0 8 I d $ 2 4 7 1 0 s t $ 5 4 7 1 2 a d c $ 0 b4 7 1 4 s t $ 5 4 7 1 6 I d $ 2 4 7 1 8 s t $ 5 4 7 2 0 b e c x a 1 44 7 2 2 m 4 7 2 4 x a 1 4 s t $ 5 ; m a k e s p a c e f o 4 7 2 6 j s $ a 3 b 8 ; n e w l i n e4 7 2 8 I d $ 1 4 7 3 0 I d $ 1 4 7 3 2 s t $ 1 f e4 7 3 4 s t $ 1 f l4 7 3 6 I d $ 3 4 7 3 8 I d $ 3 4 7 4 0 s t $ 2 4 7 4 2 s t $ 2 4 7 4 4 I d $ 0 4 7 4 6 d e 4 7 4 8 x a 1 5 I d $ 0 1 f c , y ; m o v e l i n e4 7 5 0 s t ( $ 5 f ) , y ; i n t o p r o g r a m4 7 5 2 d e 4 7 5 4 b p x a 1 54 7 5 6 j s S a 6 6 3 ; c l r4 7 5 8 j s $ a 5 3 3 ; r e - l i n k4 7 6 0 c l 4 7 6 2 b e x a 1 0 ; d a n o t h e r4 7 6 44 7 6 6 d s k g e t j s g e t i n ; g e t b y t e4 7 6 8 p h 4 7 7 0 I d $ 9 i c h e c k s t a t u s4 7 7 2 a n # $ b f4 7 7 4 b n e d k g 14 7 7 6 p l : r e t u r n i f o k4 7 7 8 r t 4 7 8 0 d k g 1 j s c l s c l r ; w r a p u p i / o4 7 8 2 I d # $ 1 d ; ' m e r g e e r r o r 14 7 8 4 I d # < m r g e r r4 7 8 6 s t $ 2 4 7 8 8 I d # > m r g e r r4 7 9 0 j m $ a 4 4 54 7 9 24 7 9 4 m r g e r r . a s c " m e r g E "4 7 9 64 7 9 8 c l s c l r I d # $ 6 3 ; c l o s e f i l e4 8 0 0 j s c l o s e ; c l e a r c h a n n e l s4 8 0 2 j m c l r e h n4 8 0 4

P r o g r a mr e s c r e e n t h i n g s ( a u g 2 5 / 8 4 )

r e 5 s t a t e m e n t s . f u n c t i o n s

r e k e y w o r d c h a r a c t e r s : 2

r e k e y w o r d r o u t i n e l i n e s e r e m s / g r o u n d g r 2 7 4 0 0 1 3r e m s / f r a m e f r a m 2 7 4 8 0 1 r e s / t e x t t e 2 7 5 6 0 1 5

1 r e m s / c r a m c f i l l 2 7 6 8 0 1 61 r e m s / c l s c l e a 2 7 9 0 0 1 71 1 r e m = = = = = = = = = = = = = = =1

1 0 4 a s c g r o u n D f r a m E t e x T "1 0 . a s c c r a M c I S "

1 1 0 4 . w o r d g r d - 1 , f r a m - 1 . t e x - 11 1 0 5 w o r d c f i l l - 1 . c l e a - 12 7 4 0 g r j s $ b 7 9 e ; g e t b y t e i n , x2 7 4 2 s t $ d O 2 1 ; p u t i b a c k g r o u n d2 7 4 4 r t ; c o l o u r r e g i s t e r2 7 4 62 7 4 8 f r a m j s $ b 7 9 e ; g e t b y t e i . 2 7 5 0 s t $ d O 2 O p u i b o r d e r2 7 5 2 r t ; c o l o u r r e g i s t e r2 7 5 42 7 5 6 t e j s $ b 7 9 e i g e t b y t e i n . x2 7 5 8 t x 2 7 6 0 a n d # $ 0 f p u l o w b y t e i 2 7 6 2 s t $ 2 8 6 ; t e x t c o i r r e g i s t e r2 7 6 4 r t

2 7 6 62 7 6 8 e f i l l j s $ b 7 9 e ; g e t b y t e i n . x2 7 7 0 t x 2 7 7 2 I d # 2 7 7 4 c f s t $ d 8 0 0 , y ; f i l l c o l o u r2 7 7 6 s t $ d 9 0 0 , y : m e m o r y2 7 7 8 s t $ d a 0 0 . y2 7 8 0 s t $ d b O O , y2 7 8 2 i n 2 7 8 4 b n e c f 2 7 8 6 r t 2 7 8 82 7 9 0 c l e a b n e d e l ; i n p a r a m e t e r s2 7 9 2 i m p $ e 5 4 4 j u s t d s c r e e n2 7 9 4 d e l j s $ b 7 9 e ; g e t a b y t e2 7 9 6 s t $ 1 ; c h e c k r a n g e2 7 9 8 c p # $ 1 92 8 0 0 b e c l e 52 8 0 2 j s $ 7 ; b r a n c h i f n 2 8 0 4 b e q d e ; 2 n d p a r a m e t e r2 8 0 6 j s $ a e f d ; c h e c k f o c o m m a2 8 0 8 j s $ b 7 9 e : g e t 2 n p a r a m e t e r2 8 1 0 c l e 2 c p $ 1 ; e x i t i t l e s s2 8 1 2 b e e c l e 4 ; t h a n f i r s t o n 2 8 1 4 c p # $ 1 9 ; c h e c k r a n g e2 8 1 6 b e c l e 52 8 1 8 b y t e $ 2 c2 8 2 0 d e I d # $ 1 8 ; d e f a u l t 2 n d p a r a m2 8 2 2 j s $ e 9 f f ; c l e a r a l i n e2 8 2 4 d e 2 8 2 6 b p c l e 22 8 2 8 c l e 4 j m p $ e 5 6 c r e s t o r e c u r s o r2 8 3 0 d e j m $ b 2 4 8 ; i l l e g a l q u a n t i t y2 8 3 2

P r o g r a m1 0 i p e e k ( 7 7 3 ) < 1 9 2 g o t o 1 2 1 1 " - r e e x i t1 2 i g o t o 1 4 1 3 a = 1 : l o a d " t b / a d d . o b j " , 8 , 11 4 s y 4 9 1 5 2 r e e n a b l e t b / a d d1 5 0 a $ c h r $ ( 3 4 ) + " t b / k e r n e l " + c h r $ ( 3 4 )1 6 p r i n t " J f l l o a d a " , 8 0 "1 7 p o k e 1 9 8 , 11 8 p o k e 6 3 1 , 1 3

T h T r a n s a c t o r 3 V o l u m e 5 I s s u e 0

Page 38: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 38/88

H a r d w a r e C o r n e r D o m e n i c D e F r a n c e s c o

I n p u t a n t h K e y b o a r d M a t r i x

I t h p r e v i o u s H a r d w a r e C o r n e r w c o v e r e d o u t p u t o t h p a r a l l e l p o r t a n c o n n e c t e d L E D s a a n e x a m p l e . T h i s a r t i c l e i t u t o r i a l a n d n o c o n s t r u c t i o n p r o j e c t w i l l b p r e s e n t e d . W w i l lc o v e r i n p u t f r o m t h p a r a l l e l p o r t a n l o o k i n t o r e a d i n g t h c o m p u t e r ' s b u i l t - i n k e y b o a r d b y s o f t w a r e .

S i m p l e i n p u t : R e a d i n g S w i t c h e s

C o n n e c t i n g s m a l l n u m b e r o s w i t c h e s ( u p t 8 i f a i r l y s i m p l ep r o c e s s . E a c h s w i t c h m u s t b c o n n e c t e d b e t w e e n a n I / l i n e a n g r o u n d . T h s w i t c h e s u s e d m a b p u s h b u t t o n s ( a i t h c a s e o k e y b o a r d ) , t o g g l e s w i t c h e s , r e l a y c o n t a c t s , o a n o p e n / c l o s ec i r c u i t e l e m e n t . A c t u a l l y c o n n e c t i n g t h s w i t c h e s t t h I / l i n e sc a n b e c o m p l i c a t e d b f e c o n s i d e r a t i o n s :

' p u l l - u p ' r e s i s t o r i s o m e t i m e s r e q u i r e d d e p e n d i n g o t h i n t e r n a l w o r k i n g s o t h I / c h i p b e i n g e m p l o y e d . T h 8 p e r i p he r a l I / l i n e s o t h u s e r p o r t o a l C o m m o d o r e c o m p u t e r s h a v et h i s p u l l - u p r e s i s t o r b u i l t i n t o t h c h i p , a n t h e r e f o r e , i i n o r e q u i r e d i o u a p p l i c a t i o n . P u l l - u p r e s i s t o r s v a r y i v a l u e f r o m I t 1 0 o h m s .

' s e r i e s d a m p i n g ' r e s i s t o r , u s e d t r e d u c e t r a n s i e n t v o l t a g e s , i o p t i o n a l , b u r e c o m m e n d e d w h e n t h s w i t c h i f a f r o m t h c o m p u t e r , o w h e n l o n g - t e r m r e l i a b i l t y i i m p o r t a n t . T y p i c a lv a l u e s f o s e r i e s d a m p i n g r e s i s t o r s a r b e t w e e n 2 o h m s a n 1 0 o h m s . S e f i g u r e f o s c h e m a t i c s h o w i n g t h d i f f e r e n t r e s i s t o ra r r a n g e m e n t s .

T r e a d t h e s t a t e o f t h s w i t c h e s , s i m p l y s e t h e d a t a d i r e c t i o nr e g i s t e r ( d d r ) t i n p u t ( z e r o ) , a n P E E K t h d a t a r e g i s t e r ( d r ) . Y o m a w a n t t r e f r e s h y o u r m e m o r y o t h o p e r a t i o n o t h d d a n d b r e f e r r i n g t t h f i r s t H a r d w a r e C o r n e r i V o l . 5 I s s u e 0 1 o t h s e c o n d i I s s u e 0 3 . T h f o l l o w i n g B A S I C s u b r o u t i n e , g i v e n a b i n u m b e r ' B N ' f r o m z e r o t h r o u g h s e v e n , w i l l a s s i g n v a r i a b l e ' D w i t h

o d e p e n d i n g o w h e t h e r t h s p e c i f i e d s w i t c h i o p e n o c l o s e d , r e s p e c t i v e l y .

1 0 0 0 r e m * * r e a d s w i t c h b ( 0 - 7 ) * 1 0 1 0 p e e k ( d r ) a n 2 t b n1 0 2 0 r e r e a d b i t ' b n ' o f d a t a r e g .1 0 3 0 d - ( d > 0 )1 0 4 0 r e m m a k e e i t h e r o 1 0 5 0 r e t u r n

H e r e ' s a e x a m p l e o p r o g r a m w h i c h u s e s t h a b o v e s u b r o u t i n e ,a n r e p o r t s o t h s t a t e o f e i g h t s w i t c h e s , e a c h c o n n e c t e d t a 1

l i n e o t h p a r a l l e l p o r t .

1 r e m * * r e a d s w i t c h e s o u s e r p o r t2 r e m * c h o o s e a p p r o p r i a t e l i n e b e l o w3 d d 5 9 4 5 9 : d 5 9 4 7 1 : r e p e t / c b m4 d d 3 7 1 3 8 : d 3 7 1 3 6 : r e v i 5 0 d d r 5 6 5 7 9 : d 5 6 5 7 7 : r e m c 6 46 0 7 p o k e d d r . O : r e a l l i n e s i n p u t s8 f o b t 7 r e a l 7 s w i t c h e s9 g o s u b 1 0 0 0 r e r e a d s w i t c h # b 1 0 p r i n t " s w i t c h " b n ;1 1 i t h e n p r i n t " : o f ( o p e n ) "1 2 i 0 t h e n p r i n t " : o ( c l o s e d ) "1 3 n e x t b 1 4 e n

T h K e y b o a r d M a t r i x

T h m e t h o d o u t l i n e d a b o v e i g o o d f o c o n n e c t i n g s m a l l n u m b e ro s w i t c h e s , b u c a b e c o m e v e r y e x p e n s i v e i m a n y s w i t c h e s ( l i k e

k e y b o a r d ) , n e e d t b c o n n e c t e d , s i n c e s e v e r a l I / c h i p s w i l l b r e q u i r e d ( a l o n g w i t h t h n e c e s s a r y e x t r a s p a c e o t h c i r c u i tb o a r d ) .

T h a l t e r n a t i v e m e t h o d i t c o n n e c t t h s w i t c h e s i m a t r i xa r r a n g e m e n t . F i g u r e s h o w s 1 p u s h b u t t o n s w i t c h e s c o n n e c t e dt t h u s e r p o r t w h i l e u s i n g o n l y l i n e s . W i t h t h a d d i t i o n o o n m o r e l i n e ( s h o w n i d a s h e s ) , 2 0 p u s h b u t t o n s c a n b c o n n e c t e d .T h i s s e t - u p u s e s f a f e w e r I / l i n e s , r e q u i r i n g l e s s c h i p s , c i r c u i t r y ,a n c o n n e c t i o n s . T h t w p o s s i b l e d i s a d v a n t a g e s a r e : 1 m o r es o f t w a r e i r e q u i r e d t r e a d t h s t a t e o f t h p u s h b u t t o n , a n 2 t h s o f t w a r e m a n o b a b l e t d e t e r m i n e w h i c h p u s h b u t t o n s a r c l o s e d i 3 o m o r e k e y s a r e p r e s s e d .

R e a d i n g t h 1 k e y s i f i g u r e i l i t t l e b i m o r e c o m p l i c a t e d t h a nr e a d i n g t h d i r e c t - c o n n e c t e d s w i t c h e s a a b o v e . T h g e n e r a l i d e ab e h i n d " s c a n n i n g " m a t r i x i t h a t t h e r e a r e t w s e t s o f l i n e s : T h r o s e l e c t l i n e s , a n t h k e y b o a r d c o l u m n i n p u t l i n e s . T h r o s e l e c t l i n e s a r o u t p u t s , a n d e t e r m i n e w h i c h r o o k e y s w i l l b r e a d o t h e i n p u t l i n e s . T h i n p u t l i n e s a r e , o b v i o u s l y , s e a i n p u t s , a n a r u s e d t d e t e r m i n e w h i c h k e i t h e d e s i r e d r o i d e p r e s s e d .

T h s c a n n i n g p r o g r a m g e n e r a l l y u s e s t w n e s t e d l o o p s : t h m a i n ,o u t s i d e l o o p i t e r a t e s o n c e f o e a c h r o i t h m a t r i x , a n t h e i n n e rl o o p i p e r f o r m e d a m a n y t i m e s a t h e r e a r e k e y s i r o w .

A y o u c a n s e i f i g u r e 2 P B 4 - P B 7 a r u s e d a t h r o s e l e c tl i n e s , a n P B t P B a r e t h e c o l u m n i n p u t l i n e s . T h d a t a

3

Page 39: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 39/88

d i r e c t i o n r e g i s t e r m u s t b s e u a c c o r d i n g l y : 1 1 1 1 0 0 0 0 ( b i n a r y ) .T h s c a n n i n g p r o g r a m m u s t s e l e c t e a c h r o i t u r n b b r i n g i n gt h e a p p r o p r i a t e r o s e l e c t l i n e L O W , a n t h e n t e s t i n g e a c h c o l u m ni n p u t l i n e t s e i i h a g o n e L O W . I i h a s , t h c o r r e s p o n d i n g k e yw a p r e s s e d . S o w c o u l d s t a r t b m a k i n g P B l o a n P B 5 - P B 7h i g h . z e r o b i i t h e i n p u t l i n e s w i l l i n d i c a t e p r e s s e d s w i t c h ,a n t h b i t ' s p o s i t i o n w i l l i n d i c a t e w h i c h o n e . B u p r o g r a m i w o r t h t h o u s a n d w o r d s , s o b e f o r e t h i s g e t s c o n f u s i n g , I ' l l l e y o s e f o y o u r s e l f h o i t ' s d o n e .T h p r o g r a m l i s t e d b e l o w s c a n s t h k e y b o a r d m a t r i x s h o w n i F i g u r e 2 a n a s s i g n s t h n u m b e r o k e p r e s s e d ( f r o m t o 1 5 ) t ot h e v a r i a b l e ' D ' . D e p e n d i n g o w h i c h m a c h i n e t h k e y b o a r d i c o n n e c t e d t o y o u m u s t s e u t h v a r i a b l e s ' D R ' a n ' D D R 'a c c o r d i n g l y .

1 0 0 r e m * r e a d b y k e y b o a r d m a t r i x1 1 p o k e d d r , 2 4 0 : r e m * d a t a d i r e c t i o n1 2 1 r e k e p r e s s e d1 3 0 f o r r o w 0 t o 31 4 p o k e d r , 1 6 * ( 1 5 - 2 t r o w ) 1 1 5 k e y s p e e k ( d r ) a n 1 1 6 i k e y s = 1 5 g o t o 2 0 01 7 f o c o t 1 8 i f ( k e y s a n 2 t c o l ) t h e n

c o 4 r o 1 9 n e x t c o 2 0 r e m — e n d i f2 1 n e x t r o 2 2 0 e n d

T h C o m m o d o r e 6 4 ' s K e y b o a r d

A l t h C o m m o d o r e c o m p u t e r s u s m a t r i x a r r a n g e m e n t f o t h e i rk e y b o a r d s . O t h C 6 4 , t h k e y b o a r d r o i s e l e c t e d w i t h t h r e g i s t e r a 5 6 3 2 0 , a n t h k e y b o a r d i n p u t l i n e s a r r e a d f r o ml o c a t i o n 5 6 3 2 1 . N o t e t h a t t h e s e p o r t s a r e t h s a m e o n e s u s e d f o t h j o y s t i c k s , w h i c h e x p l a i n s w h y o c a n ' t p r o p e r l y t y p e o t h k e y b o a r d w h i l e p l a y i n g a r o u n d w i t h t h j o y s t i c k .

T h 6 4 ' s k e y b o a r d i a r r a n g e d a a n 8 b y m a t r i x , g i v i n g a t o t a l o 6 k e y s . T s e l e c t k e y b o a r d r o w , t h e c o r r e s p o n d i n g b i i t h r o s e l e c t r e g i s t e r m u s t b s e t t o z e r o . T h s t a t e o f t h a t k e y b o a r d r o c a t h e n b r e a d f r o m l o c a t i o n 5 6 3 2 1 . T h k e y s c o r r e s p o n d i n g t t h g i v e n r o w s a n c o l u m n s a r s h o w n i t h e f o l l o w i n g t a b l e . T h r o n u m b e r a p p e a r s i t h e l e f t m o s t c o l u m n , f o l l o w e d b t h v a l u et h a t w o u l d b s t o r e d i t h s e l e c t r e g i s t e r 5 6 3 2 0 2 5 5 - 2 t ( r o wn u m b e r ) ) .

a b l e t s c a n t h k e y b o a r d y o u r s e l f i n s t e a d o f r e l y i n g o t h b u i l t -i r o u t i n e . F o e x a m p l e , y o m a w i s h t c h e c k f o o n l y s p e c i f i ck e y , o c h e c k t h e c u r r e n t k e p r e s s e d w i t h o u t a f f e c t i n g t h k e b o a r d b u f f e r . A l s o , c u s t o m k e y b o a r d - s c a n n i n g r o u t i n e w i l l a l l o wy o t d e t e c t t w k e y s w h i c h a r s i m u l t a n e o u s l y d e p r e s s e d ;c a p a b i l i t y t h a t i o f t e n d e s i r e d i g a m e s .

T s h o w h o e a s y i i t s c a n t h m a t r i x , t h s c a n n i n g p r o g r a m i p r e s e n t e d i B A S I C . W h e n s c a n n i n g t h k e y b o a r d , e i t h e r f r o mm a c h i n e l a n g u a g e o B A S I C , i i n e c e s s a r y t d i s a b l e t h e I R Q s t p r e v e n t t h e s y s t e m ' s k e y b o a r d s c a n n i n g r o u t i n e f r o m i n t e r f e r i n g .T h i s i d o n e i B A S I C b d i s a b l i n g t h e t i m e r w h i c h g e n e r a t e s t h i n t e r r u p t s . T h s c a n n i n g p r o g r a m b e l o w w i l l s c a n t h k e y b o a r da n r e t u r n a c o d e ( t h e s a m e a f r o m P E E K ( 1 9 7 ) f o t h k e p r e s s e d i t h a r r a y v a r i a b l e K ( 0 ) . I t w k e y s a r p r e s s e d , a n o t h e rv a l u e w i l l b s t o r e d i n K ( l ) . T h e n u m b e r o k e y s p r e s s e d , 0 , o 2 w i l l b s t o r e d i t h e v a r i a b l e ' C T h k e y b o a r d s c a n i d o n e b t h s u b r o u t i n e s t a r t i n g a l i n e 1 0 0 0 .

1 0 0 r e m * s c a n c 6 4 k e y b o a r d1 1 0 r e m *1 2 s e 5 6 3 2 0 : r e m * k b r o s e l e c t r e 1 3 i n 5 6 3 2 1 : r e m * k b i n p u t r e g i s t e r1 4 f o 0 t o 7 : e ( i ) 2 t i : n e x t1 5 r e m * e ( i e x p o n e n t a r r a y ( 2 t x )1 7 0 :1 8 p r i n t " # k e y s " , " s k e y " , " 2 n k e y "1 8 1 9 f o l o o p t s t e p2 0 g o s u b 3 7 0 : r e m * r e a d k e y b o a r d2 1 p r i n t o , k ( 0 ) , k ( 1 )2 2 n e x t l o o p2 3 0 e n d2 5 0 :2 6 r e m *

R O

( 2 5 4 )( 2 5 3 )

2 ( 2 5 1 )( 2 4 7 )( 2 3 9 )( 2 2 3 )

6 ( 1 9 1 )7 ( 1 2 7 )

C o l u m n ( b i t i l o c a t i o n 5 6 3 2 1 )

D E r t r n F F F

H O M E r . s h fC T R L S P A C E

F

S T O P

d I . s h f t

N o t e s :1 T h s h i f t l o c k k e i c o n n e c t e d w i t h t h e l e f t s h i f t k e y .2 T h R E S T O R E k e i n o p a r t o f t h k e y b o a r d m a t r i x , b u i d i r e c t l y

w i r e d t g e n e r a t e a N M ( N o n M a s k a b l e I n t e r r u p t ) w h e n s t r u c k .

S c a n n i n g t h b u i l t - i n k e y b o a r d i n o m o r e d i f f i c u l t t h a n s c a n n i n go u c u s t o m - m a d e 1 k e e x a m p l e . I m i g h t b s o m e t i m e s d e s i r -

2 7 r e m * k e y b o a r d s c a n s u b r o u t i n e2 8 r e m * s e u e ( b e f o r e c a l l i n g .2 9 r e m * i n p u t v a r i a b l e s :3 0 r e m * S E L " : r o s e l e c t r e g i s t e r3 1 r e m * I N P " : k e y b o a r d i n p u t r e 3 2 r e m * o u t p u t v a r i a b l e s :3 3 r e m * " : o k e y s d o w n ( 0 - 2 )3 4 r e m * K ( 0 ) " : s k e d o w n o 6 3 5 r e m * " K ( 1 ) " : 2 n k e d o w n o 6 3 6 r e m * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *3 7 0 r e m - t h i s i t h e e n t r y p o i n t3 8 0 :3 9 0 p o k e 5 6 3 3 4 , p e e k ( 5 6 3 3 4 ) a n d 2 5 44 0 r e m * t u r n i n t e r r u p t s o f 4 1 0 :4 2 0 r e k e y s p r e s s e d ( 0 - 2 )4 3 k ( 0 ) 6 4 k ( 1 ) 6 4 : r e m * 6 n k e 4 4 0 p o k e s e l , 04 5 r e m * t e s t f o n k e y s p r e s s e d4 6 i p e e k ( i n p ) = 2 5 5 t h e n r e t u r n4 7 0 :4 8 f o r o t 4 9 0 p o k e s e l , 2 5 5 - e ( r o w )5 0 k e y s p e e k ( i n p ) : i f k e y s 2 5 5 g o t o 5 5 05 1 0 f o r c o l 0 t o 75 2 i f ( k e y s a n e ( c o l ) ) a n c < t h e n

k ( c ) r o w * 8 c o l : + 5 3 0 :5 4 n e x t c o 5 5 n e x t r o w : r e m — e n d i f —5 6 0 :5 7 p o k e 5 6 3 3 4 , p e e k ( 5 6 3 3 4 ) o r 15 8 r e m * t u r n i n t e r r u p t s b a c k o 5 9 r e t u r n

T h T r a n s a c t o r 3 V o l u m e 5 I s s u e 0

Page 40: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 40/88

T h C 6 4 ' s I / p o r t s T h P E T / C B M k e y b o a r d m a t r i x

T h s c a n n i n g p r o c e d u r e i p r e t t y s t r a i g h t f o r w a r d , b u y o m a h a v e n o t i c e d s o m e t h i n g l i t t l e w i e r d . L o c a t i o n 5 6 3 2 0 i u s e d a a o u t p u t , s i n c e w P O K E i w i t h a v a l u e t s e l e c t k e y b o a r d r o w . B u tw c a a l s o P E E K t h v e r y s a m e l o c a t i o n , a n i w i l l g i v e t h c u r r e n t s t a t u s o f t h j o y s t i c k p l u g g e d i n t o p o r t # 2 . A l l t h i s w i t h o u te v e r t o u c h i n g a d a t a - d i r e c t i o n r e g i s t e r . W h a t ' s g o i n g o h e r e ?W e l l , t h m a g i c i d u t t h w a t h 6 5 2 6 I / c h i p w o r k s . I l i n ei s e a a o u t p u t ( t h r o u g h t h e d a t a d i r e c t i o n r e g i s t e r ) a n i s e h i g h v i a t h e d a t a r e g i s t e r , y o u w o u l d e x p e c t P E E K o t h e l o c a t i o nt s h o w t h a t l i n e a b e i n g h i g h , n m a t t e r w h a t . T h a t ' s n o n e c e s s a r i l y t h c a s e w i t h t h 6 5 2 6 : w h e n t h e p o r t i r e a d w i t hP E E K , t h v a l u e o b t a i n e d i n o t t h e c o n t e n t s o t h I / r e g i s t e r , i i t h e a c t u a l s t a t e o f t h I / p i n s . T h u s , i l i n e i b e i n g p u l l e d l o ( i t h c a s e o t h C 6 4 , b t h j o y s t i c k ) , e v e n i i i a o u t p u t a n s e h i g h i w i l l r e a d a a z e r o . T h i s i h o l i n e c a n b e u s e d f o i n p u t o o u t p u t w i t h o u t c h a n g i n g t h e d a t a d i r e c t i o n r e g i s t e r .

P o r t o t h 6 5 2 6 h a w h a t ' s k n o w n a " p a s s i v e p u l l - u p " I / l i n e s . S u c h l i n e s h a v e a n i n t e r n a l p u l l - u p r e s i s t o r , w h i c h p u l l s t h l i n e h i g h w h e n s e a a i n p u t o w h e n s e a a o u t p u t a n h i g h .p a s s i v e p u l l - u p l i n e c a b p u l l e d l o e x t e r n a l l y w i t h o u t d a m a gi n g t h e I / c h i p , e v e n i i t ' s s u p p o s e d t b a o u t p u t . T h a t ' s w h i t ' s n o a a w f u l a i s o u n d s t u s t h j o y s t i c k t f o r c e o u t p u t l i n e sl o w .

W h i l e w e ' r e o t h e s u b j e c t o I / l i n e p u l l - u p , t h e r e a r e a l s o t h o s eo t h " a c t i v e p u l l - u p " v a r i e t y ( a y o m i g h t h a v e g u e s s e d ) . A a c t i v e p u l l - u p l i n e i p u l l e d h i g h b a a c t i v e c i r c u i t e l e m e n t l i k et r a n s i s t o r w h e n i t ' s s e a a o u t p u t a n h i g h . A c t i v e p u l l - u p l i n e sc a n ' t b p u l l e d l o e x t e r n a l l y l i k e p a s s i v e p u l l - u p l i n e s c a n . N o u n l e s s y o u w a n t t b l o w y o u r I / O c h i p ! S o m e c h i p s h a v e I / O l i n e sw i t h b o t h a c t i v e a n p a s s i v e p u l l - u p s . T h e s e l i n e s g i v e t h e b e s t o b o t h w o r l d s , s i n c e t h e y c a s i n k a l o o c u r r e n t w h e n i t h h i g hs t a t e a s o u t p u t s , a n t h e y w i l l " f l o a t " h i g h w h e n s e t a s i n p u t s .

T h k e y b o a r d m a t r i x o P E T / C B M m a c h i n e s h a 1 r o w s b c o l u m n s , a n w o r k s i b a s i c a l l y t h s a m e w a a s t h e 6 4 ' s . T h m a i n d i f f e r e n c e i t h a t t h r o s e l e c t r e g i s t e r u s e s d e c o d e r c h i pt s a v e I / l i n e s . T h d e c o d e r w i l l b r i n g g i v e n l i n e l o w , g i v e n t h b i n a r y v a l u e o f t h a t l i n e o i t ' s i n p u t s . F o r u s s o f t w a r e f o l k s o t h o u t s i d e o t h m a c h i n e , t h a t m e a n s t h a t w j u s t s t o r e n u m b e rf r o m t i t h r o s e l e c t r e g i s t e r t o s e l e c t o n o t e l i n e s . W d o n ' t h a v e t c a l c u l a t e t h p r o p e r v a l u e t o a f f e c t c e r t a i n l i n e .

S p e c i f i c a l l y , t h r o s e l e c t r e g i s t e r o P E T s i f o u n d i t h l o w e rb i t s o l o c a t i o n 5 9 4 0 8 , a n t h c o l u m n i n p u t s a r e r e a d f r o ml o c a t i o n 5 9 4 1 0 . T h s c a n n i n g p r o c e s s f o r t h i s k e y b o a r d i i d e n t i c a lt t h a t f o t h 6 4 ' s e x c e p t f o t h P O K E w h i c h s e l e c t s t h r o w . T h a d v a n t a g e t t h P E T ' s l a y o u t i t h a t i u s e s f e w e r I / l i n e s . T h a d v a n t a g e t t h 6 4 ' s s c h e m e i t h a t q u i c k c h e c k c a n b e m a d e t s e i A N k e i p r e s s e d , w i t h o u t c h e c k i n g e a c h r o i t u r n( s t o r i n g a z e r o i t h r o s e l e c t r e g i s t e r a l l o w s y o t r e a d t h e s t a t eo A L k e y s a o n c e ) . S t h P E T ' s k e y b o a r d t a k e s l o n g e r t s c a nw h e n n k e y s a r b e i n g p r e s s e d .

W r a p p i n g u

T h t o p i c o i n p u t i g e n e r a l c o u l d c o v e r m a n y m o r e p a g e s , b u t t h ea b o v e w a j u s t c o l l e c t i o n o f e w s i m p l e a n d a d v a n c e d c o n c e p t s .I n p u t t t h c o m p u t e r i n o u s u a l l y d i s c u s s e d o t h l o w e s th a r d w a r e l e v e l , b u s e r i o u s c o m p u t e r i s t s s h o u l d k n o w w h a t ' sg o i n g o i t h e r e . R e a d i n g d e v i c e s s u c h a t h k e y b o a r d d i r e c t l yw i t h y o u r o w s o f t w a r e g i v e s y o j u s t l i t t l e b i m o r e c o n t r o l o v e ry o u r m a c h i n e . P o w e r ! T h n e x t H a r d w a r e C o r n e r ( w h i c h w i l lh o p e f u l l y a p p e a r i t h N E X T i s s u e t h i s t i m e ) w i l l p r e s e n t c o u p l eo c o n s t r u c t i o n p r o j e c t s : A R S - 2 3 2 i n t e r f a c e , a n d i r e c t c o n n e ct i o n o f p a r a l l e l p r i n t e r t t h e u s e r p o r t .

5 5

P B P u l l - u p r e s i s t o r

P B P u l l - u p a n s e r i e s d a m p i n g r e s i s t o r

P B 2 « - • N r e s i s t o r s ; p u l l - u p r e s i s t o r i n s i d e c h i p

4 7 P B 3 » W ■ • * * - •S e r i e s d a m p i n g r e s i s t o r o n l y

F i g u r e 1 P u l l - u p a n s e r i e s d a m p i n g r e s i s t o r c o n n e c t i o n s

R o O u t p u t s

P B

P B

P B

P B 1 1

1

1

1

1

C o l u m nI n p u t s : p b p b P B P B

F i g u r e 2 b k e y b o a r d m a t r i x .N o t e h o o n a d d i t i o n a l I / l i n e a l l o w s m o r e k e y s .

f h e T r 3 V o l u m e 5 I s s u e 0

Page 41: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 41/88

T h C o m m o d o r e 6 K e y b o a r d P a r t 1 T h K E R N E L R o u t i n e s

A u b r e y S t a n l e yM i s s i s s a u g a , O n t a r i o

I t a m a z i n g h o s o m e t h i n g a o r d i n a r y a k e y b o a r d c a n t u r n y o o f w h a t m u s t b t h g r e a t e s t P f o i t p r i c e o t h m a r k e t t o d a y .w o r k i s o f t w a r e d e v e l o p m e n t , w h i c h m e a n s t h a t u s e t h e k e b o a r d l o t . I ' u s e d t k e y b o a r d s t h a t r e s p o n d t k e y s a t h e y a r e n t e r e d , n m a t t e r h o w m a n y p r e v i o u s k e y s a r e p r e s s e d . T h i s i k n o w n a n - K E Y R O L L O V E R i c o m p u t e r j a r g o n . f o u n d t h o n e - k e y - a t - a - t i m e a p p r o a c h v e r y f r u s t r a t i n g . T c o m p o u n d t h s i t u a t i o n , m f i v e - y e a r - o l d d a u g h t e r , C h a r m a i n e , w h o m w a t e a c h i n g t o t y p e , d e c i d e d t e n h e r e l a t i o n s h i p w i t h t h C o m m od o r e b e c a u s e " i c o u l d n ' t s p e l l " .

W h i l e i n v e s t i g a t i n g h e p r o b l e m s s o o n d i s c o v e r e d t h a t a l h e c o m p l a i n t s o r i g i n a t e d i t h i s o n e - k e y - a t - a - t i m e m e t h o d o l o g yt h a t C o m m o d o r e u s e s t d r i v e t h 6 k e y b o a r d . I w a t r u l yl e s s o n t s e h e r e f u s e t a c c e p t s i t u a t i o n w h i c h I a c o n d i t i o n e d a d u l t , h a b e c o m e r e s i g n e d t o Y e s , t h e c o m p u t e rc a n n o t s p e l l ! I t w k e y s a r d o w n a t h s a m e t i m e , c h a n c e s a r e v e n t h a t t h s e c o n d k e p r e s s e d w i l l n o d i s p l a y u n t i l t h f i r s t k e i r e l e a s e d . T h i s c a n s l o w a n a v e r a g e t y p i s t d o w n b 5 0 o m o r e .I t h e c a s e w h e r e t h s e c o n d k e y d o e s d i s p l a y , i t h s e c o n d k e y i r e l e a s e d b e f o r e t h f i r s t k e y , t h e n t h f i r s t k e w i l l b d i s p l a y e da g a i n . A n i f p e r c h a n c e , t h e r e a r e t h r e e k e y s d o w n s i m u l t a n eo u s l y ( y o u ' r e s u p e r t y p i s t o r c h i l d ) , t h e n i t ' s l i k e l y t h a t t h t h i r dk e w i l l d i s p l a y i n c o r r e c t l y t r ' G H J ' f o i n s t a n c e .

d e c i d e d h a t d o s o m e t h i n g t r e s t o r e m c h i l d ' s f a i t h i nc o m p u t e r s . T h P R O G R A M M E R S R E F E R E N C E G U I D E h a p r c i o u s l i t t l e t s a o t h k e y b o a r d . E v e n t h g o o d o l T R A N S A CT O m a g s w e r e d e c i d e d l y m u t e o t h s u b j e c t . S a r m e d w i t hn e w l y p u r c h a s e d M o n i t o r , t o o k p l u n g e i n t o t h m u r k y w a t e r s o t h e K e r n e l R O M . M i n v e s t i g a t i o n s f o r m t h b a s i s o f t h i s f i r s ta r t i c l e o t h C o m m o d o r e 6 k e y b o a r d . I l l u s t r a t e d h e r e i t h s o f t w a r e i n t e r f a c e , t h e a s s o c i a t e d K e r n e l r o u t i n e s a n s o m e i n t e re s t i n g f a c t s t h a t h a v e b e e n l e f t o u o o f f i c i a l C o m m o d o r e p u b l i c at i o n s . T h s e c o n d a r t i c l e w i l l b u i l d u p o n t h i s k n o w l e d g e b d e v e l o p i n g a a l t e r n a t i v e s o f t w a r e d r i v e r w i t h n - K e y R o l l o v e rc a p a b i l i t y a n t h a b i l i t y t e a s i l y r e d e f i n e t h s t a n d a r d a r r a n g em e n t o t h k e y b o a r d . A r t i c l e t h r e e w i l l d e m o n s t r a t e f u r t h e rr o u t i n e s t h a t r u a e x t e n s i o n s o t h i s k e y b o a r d d r i v e r a n d e nh a n c e t h c a p a b i l i t i e s o t h s t a n d a r d S c r e e n E d i t o r . Y o w i l l b a b l e t d e f i n e a n k e t g e n e r a t e a ' i n s t a n t k e y w o r d ' o y o u rc h o i c e - e . g . t y p e s h i f t e d ' G a n g e ' G O S U B ' . O e r a s e t t h e n d -o f - l i n e . O r e v e n l i n k i y o u r o w r o u t i n e t p e r f o r m a e d i t i n gt a s k y o s o r e l y m i s s i t h s t a n d a r d e d i t o r .

H o K e y s A r e R e a d

I m a g i n e e a c h k e y a s w i t c h w h i c h t u r n s a i n d i v i d u a l b i i m e m o r y t ' 0 w h e n p r e s s e d . I t h k e i r e l e a s e d , t h m e m o r y b i r e v e r t s t T N o s i n c e t h e r e a r e 6 k e y s ( R E S T O R E e x c e p t e d ) ,t h k e y b o a r d m a b t h o u g h t o a o c c u p y i n g 6 b i t s , o b y t e s , o fm e m o r y , e a c h b i o w h i c h r e p r e s e n t s p a r t i c u l a r k e y . I t ' s t h

p h y s i c a l p o s i t i o n o t h k e t h a t a t a l k i n g a b o u t , n o t t h e s y m b o le t c h e d o i t I t ' s i m p o r t a n t t u n d e r s t a n d t h i s . A n o n b y t e o t h i sp s e u d o m e m o r y i a v a i l a b l e t t h s o f t w a r e a l o c a t i o n $ D C 0 1 .W h i c h b y t e t h s o f t w a r e r e a d s i d e c i d e d b y w r i t i n g a b i p a t t e r n t l o c a t i o n $ D C 0 0 b e f o r e p e r f o r m i n g t h r e a d * . T h b i p a t t e r nc o n s i s t s o s e v e n b i t s a n d o n e ' 0 b i t . J u s t w h e r e t h ' 0 ' i sp o s i t i o n e d w i l l d e t e r m i n e t h s e o e i g h t k e y s t h a t w i l l b r e a df r o m $ D C 0 1 . T a b l e i l l u s t r a t e s t h i s p r o c e s s u s i n g t h e d e s i g n a t i o n so t h s t a n d a r d k e y b o a r d . B u a g a i n , r e m e m b e r t h a t t h l e t t e r o t h k e i o n l y t h e s y m b o l , i t t h e p h y s i c a l p o s i t i o n o t h k e t h a td e t e r m i n e s w h i c h p a r t i c u l a r b i i s e o r e s e t i $ D C 0 1 .

E d i t o r ' s N o t e : S D C 0 0 a n d S D C 0 1 a r h a r d w a r e r e g i s t e r s i o n o t h I / c h i p s , a n c o n t r o l t h e I / p o r t s t w h i c h t h k e y b o a r ds w i t c h e s a r e c o n n e c t e d . S e ' H a r d w a r e C o r n e r ' i n t h i s i s s u e f o rm o r e o t h i s .

T a b l e 1 K e y b o a r d S w i t c h M a t r i x

R O $ F $ F $ F $ F $ E $ D $ B $ 7

d l . s h f t

S T O P

F

f f

C o l u m n ( b i t i l o c a t i o n 5 6 3 2 1 )

F F

r . s h fS P A C E

F

H O M E

r

C T R L

r t r n D E

I n d e x O K e

T h K e r n e l d e t e r m i n e s t h i n d e x o k e y b y e f f e c t i v e l y a d d i n g i t c o l u m n p o s i t i o n t i t r o p o s i t i o n m u l t i p l i e d b 8 T h u s t h k e ' B w i l l h a v e a n i n d e x o 4 ( 3 * 8 ) 2 o $ 1 C . T h i n d e x i u s e d t a c c e s s t a b l e f r o m w h i c h i f e t c h e d t h e A S C I I o C H R $ v a l u e o t h k e y . F o t h ' B k e t h i s w o u l d n o r m a l l y b e 6 6 o r $ 4 2 . C e r t a i n k e y sa r g i v e n s p e c i a l C H R $ v a l u e s i t h t a b l e . T h e s e a r ' 1 f o S h i f tK e y , ' 2 f o t h C o m m o d o r e K e a n ' 4 f o t h C o n t r o l K e y .

R E P L A C I N G T H K E R N E L ' S D E C O D E T A B L E S I O N W A O R E - C O N F I G U R I N G T H E K E Y B O A R D .

I n t e r r u p t E n t r y

T h K e r n e l , w h e n i i n i t i a l i z e s t h s y s t e m , s e t s u o n o t h t i m e r st i n t e r r u p t a l / 6 0 t h s e c o n d i n t e r v a l s . E a c h t i m e t h i s i n t e r r u p to c c u r s , t h h a r d w a r e a u t o m a t i c a l l y s a v e s t h P r o g r a m C o u n t e r o t h e c u r r e n t t a s k t o g e t h e r w i t h t h e s t a t u s r e g i s t e r , a n d j u m p s t t h v e c t o r s t o r e d i $ F F F E - $ F F F F . T h i s v e c t o r p o i n t s t $ F F 4 8 w h e r et h K e r n e l s a v e s t h r e g i s t e r s a n t h e n d o e s a i n d i r e c t j u m pt h r o u g h l o c a t i o n $ 3 1 4 — $ 3 1 5 . T h i s v e c t o r p o i n t s t $ E A 3 1 , t h b e g i n n i n g o t h e r o u t i n e s t h a t i n c r e m e n t t h r e a l t i m e c l o c k , f l a s ht h e c u r s o r , h a n d l e t h e t a p e m o t o r a n f i n a l l y , s c a n t h e k e y b o a r d .

T h T r a n s a c t o r 3 V o l u m e 5 I s s u e 0

Page 42: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 42/88

I t ' s t h k e y b o a r d s c a n n i n g r o u t i n e t h a t w e ' r e c o n c e r n e d w i t h h e r e .d e t a i l e d e x p l a n a t i o n o f t h i s r o u t i n e f o l l o w s .

K E R N E L K e y b o a r d V a r i a b l e s

T h K e r n e l u s e s l o m e m o r y t s t o r e i t v a r i a b l e s . T h u s o e a c ho t h e s e v a r i a b l e s w i l l b e c o m e c l e a r i t h e d e s c r i p t i o n s w h i c hf o l l o w .

; l n d e x o L a s t K e P r e s s e d; N u m b e r o C h a r a c t e r s i K e y b o a r d B u f f e r; l n d e x o C u r r e n t K e P r e s s e d; K e y b o a r d D e c o d e T a b l e P o i n t e r

K e y b o a r d B u f f e r S t a r t; M a x . C h a r a c t e r s A l l o w e d i K e y b o a r d B u f f e r; F l a g t E n a b l e / D i s a b l e R e p e a t s; R e p e a t S p e e d C o u n t; D e l a y t R e p e a t N e K e P r e s s; C u r r e n t S t a t e o S h i f t , C C o n t r o l K e y s; L a s t S t a t e o S h i f t , C a n C o n t r o l K e y s; V e c t o r f o K e y b o a r d T a b l e S e t u p; F l a g t E n a b l e / D i s a b l e C h a r a c t e r S e S w i t c h; V e c t o r f o H a r d w a r e I R Q I n t e r r u p t

K e y b o a r d D r i v e r E n t r y

T h K E Y B O A R D B U F F E R R o u t i n e

L S T XN D S F D XK E Y T A BK E Y DX M A XR P T F L GK O U N TD E L A YS H F L A GL S T S H FK E Y L O GM O D EC I N V

$ C $ C $ C $ F $ 2 7 7$ 2 8 9$ 2 8 A$ 2 8 B$ 2 8 C$ 2 8 D$ 2 8 E$ 2 8 F$ 2 9 1$ 3 1 4

E N T R Y

# 0 - S H F L A G# $ 4 0 - S F D X# O - $ D C 0 0$ D C 0 1 - . X

T h K e y b o a r d r o u t i n e s a r e e n t e r e d a $ E A 8 7 v i a a s u b r o u t i n e c a l lf r o m l o c a t i o n $ E A 7 B . T h i s i u n f o r t u n a t e , b e c a u s e t h l a c k o v e c t o r h e r e m e a n s t h a t a n y o n e w i s h i n g t r e p l a c e t h e s t a n d a r dd r i v e r m u s t t a k e o v e r t h e n t i r e i n t e r r u p t r o u t i n e , p e r f o r m i n g a l t h e o t h e r h o u s e k e e p i n g t a s k s a s w e l l .

F i r s t S H F L A G i c l e a r e d t 0 S H F L A G h o l d s t h r u n - t i m e s t a t e o ft h S h i f t , C o m m o d o r e a n C o n t r o l k e y s . v a l u e o $ 4 i t h e nw r i t t e n t S F D X . S F D X h o l d s t h c u r r e n t i n d e x o t h k e y f o u n d t b p r e s s e d d u r i n g t h s c a n n i n g o p e r a t i o n . $ 4 ( d e c i m a l 6 4 i t h i n d e x w h e n n k e y s a r e p r e s s e d . N e x t a v a l u e o $ 0 i w r i t t e n t l o c a t i o n $ D C 0 0 . L o c a t i o n $ D C 0 1 i t h e n r e a d . I t h i s p r o d u c e s a $ F r e s u l t , t h e n i m e a n s t h a t n k e y s a r p r e s s e d . A n o t h e r v a l u es i g n i f i e s t h a t a l e a s t o n k e i p r e s s e d . I n k e y s a r e p r e s s e d , t h d r i v e r e n t e r s t h K E Y B O A R D B U F F E R r o u t i n e , o t h e r w i s e t h S C A N N I N G r o u t i n e i e n t e r e d .

$ 0 I S P E C I A L B I P A T T E R N W R I T T E N T L O C A T I O N $ D C 0 0 T D E T E R M I N E I A N

( I D O E S N ' T M A T T E R W H I C H ) K E Y S A R P R E S S E D .

K E Y B O A R DB U F F E R

S F D X - L S T XS H F L A G ^ L S T S H F

. X - . AN D X ^ . X

Y E

A ^ K E Y D . X. X + 1 - . X. X - N D X

R e t u r n

T h i s r o u t i n e i e n t e r e d a $ E B 2 6 . H e r e L S T S H F a n L S T X a r u p d a t e d t r e f l e c t t h n e s t a t e o f t h k e y b o a r d . L S T S H F s t o r e s t h s t a t e s o f t h S h i f t , C o m m o d o r e a n C o n t r o l k e y s ( i n b i t s 0 , a n r e s p e c t i v e l y ) f r o m t h l a s t a c t i v a t i o n o t h e i n t e r r u p t r o u t i n e . I t h b i i s ' 0 ' t h e n t h i s m e a n s t h a t t h c o r r e s p o n d i n g k e y i N O p r e s s e d . L S T X h o l d s t h i n d e x o t h k e y - p r e s s ( e x c l u d i n g t h S h i f t , C o m m o d o r e a n C o n t r o l k e y s ) f r o m t h l a s t a c t i v a t i o n o t h i n t e r r u p t r o u t i n e . R e m e m b e r a g a i n t h a t t h i n d e x g i v e s t h e p h y s ic a p o s i t i o n o t h k e y . ( a c c o r d i n g t i t p o s i t i o n i T a b l e 1

S H F L A G i c o p i e d t L S T S H F a n S F D X t L S T X . A t h i s p o i n tr e g i s t e r ' X w i l l h o l d t h C H R $ v a l u e ( t a k i n g i n t o a c c o u n t t h s t a t eo t h S h i f t , C o m m o d o r e a n C o n t r o l k e y s ) o t h k e t h a t w a f o u n d t b p r e s s e d d u r i n g t h S C A N N I N G r o u t i n e . I n o k e y w a p r e s s e d t h e n ' X w i l l c o n t a i n t h e v a l u e $ F F . N o t h i n g i p u i n t o t h k e y b o a r d b u f f e r i t h v a l u e o ' X i $ F o i N D h a r e a c h e dX M A X , t h l a t t e r c o n d i t i o n i n d i c a t i n g t h a t t h k e y b o a r d b u f f e r i f u l l . O t h e r w i s e t h C H R $ v a l u e i i n s e r t e d i n t o K E Y D , t h k e b o a r d b u f f e r , a t h l o c a t i o n o f f s e t b N D X , a n N D i i n c r em e n t e d . F i n a l l y , t h K E Y B O A R D B U F F E R r o u t i n e e x i t s t t h R E T U R N r o u t i n e .

' L S T S H F ' A N ' L S T X ' M A B E X A M I N E D T S E J U S T W H I C H K E Y S A R C U R R E N T L Y P R E S S E D .

' K E Y D ' I T H Q U E U E T H A T T H K E R N E L U S E ST F E E D K E Y S T B A S I C A N O T H E R P R O G R A M S .

T h T r a n s a c t o r 4 V o l u m e 5 I s s u e 0

Page 43: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 43/88

T h R E T U R N R o u t i n e

R E T U R N

# $ 7 F - * $ D C 0 0

E n

T h R E T U R N r o u t i n e i e n t e r e d a $ E B 4 2 . I w r i t e s $ 7 t l o c a t i o n$ D C 0 0 a n t h e n d o e s R e t u r n F r o m S u b r o u t i n e w h i c h e n d s t h K e y b o a r d s e r v i c i n g p o r t i o n o t h e i n t e r r u p t r o u t i n e . R e t u r n i t l o c a t i o n $ E A 7 E w h e r e t h K e r n e l r e a d s t h C I I n t e r r u p t C o n t r o lR e g i s t e r ( f r o m $ D C 0 D ) , r e s t o r e s t h C P r e g i s t e r s a n e x i t s t h i n t e r r u p t w i t h a R T i n s t r u c t i o n .

T h b i p a t t e r n o $ 7 w r i t t e n t l o c a t i o n $ D C 0 0 a l l o w s B A S I C o a n o t h e r p r o g r a m t r e a d d i r e c t l y ( f r o m $ D C 0 1 ) , t h s e o e i g h tk e y s w h i c h i n c l u d e s t h C O N T R O L a n S T O P k e y s .

I I W O R T H M E N T I O N I N G H E R E T H A T T H ES C R E E N S C R O L L I N G R O U T I N E R E S E T S $ D C O O t $ 7 F .

T h S C A N N I N G R o u t i n e

T h S C A N N I N G r o u t i n e i e n t e r e d a $ E A 9 A . F i r s t K E Y T A B i s e u t p o i n t t t h D e c o d e T a b l e a $ E B 8 1 . T h i s t a b l e g i v e s t h C H R $ v a l u e s f o n o r m a l ( u n s h i f t e d ) k e y s . T h k e y s a r s c a n n e d i s e q u e n c e b e g i n n i n g a i n d e x ' 0 a n e n d i n g a i n d e x ' 6 3 '( $ 3 F ) . T h i s i a c h i e v e d i e i g h t a c t i v a t i o n s o a o u t e r l o o p , e a c h o w h i c h w r i t e s t h e a p p r o p r i a t e b i p a t t e r n t l o c a t i o n $ D C 0 0 a n t h e n e n t e r s a i n n e r l o o p w h e r e t h c o r r e s p o n d i n g s e o e i g h tk e y s a r r e a d f r o m l o c a t i o n $ D C 0 1 a n d e x a m i n e d o n e b y o n e .

I t h i n n e r l o o p , i t h e v a l u e o t h k e b i ' 0 ' ( i . e . t h k e i p r e s s e d ) , t h e n i t i n d e x i u s e d t f e t c h t h C H R $ v a l u e f r o m t h d e c o d e t a b l e w h o s e p o i n t e r h a d b e e n s e u i K E Y T A B . I t h C H R $ v a l u e i s 1 ' ' 2 o ' 4 ( S h i f t , C o m m o d o r e o C o n t r o l ) , t h e n t h i sv a l u e i O R ' d i n t o S H F L A G w h i c h m a i n t a i n s t h v a l u e s o t h e s ek e y s . O t h e r w i s e t h i n d e x i i t s e l f w r i t t e n t S F D X , o v e r w r i t i n ga n p r e v i o u s i n d e x t h a t m a h a v e b e e n s t o r e d t h e r e d u r i n g t h s c a n n i n g p r o c e s s . T H I S F A C T O R E X P L A I N S T H O N E - K E Y - A T -A - T I M E F E A T U R E O T H C O M M O D O R E K E Y B O A R D A N I T H R O O T C A U S E O A L T H A N O M O L I E S . A f t e r t h e s c a n i c o m p l e t e d , S F D X w i l l c o n t a i n t h i n d e x o t h p r e s s e d k e w i t h t h h i g h e s t i n d e x , w h i l e S H F L A G w i l l h o l d t h s t a t e s o t h S h i f t ,C o m m o d o r e a n C o n t r o l k e y s i t h l e a s t t h r e e s i g n i f i c a n t b i t s .

N o c o m e s t h p a r t t h a t s o m e r e a d e r s m a n o b a w a r e o f A f t e rt h s c a n i c o m p l e t e d , j u m p i m a d e t t h v e c t o r c o n t a i n e d i K E Y L O G . N o r m a l l y K E Y L O G c o n t a i n s $ E B 4 8 w h i c h i t h s t a r t o t h k e y b o a r d D E C O D E R r o u t i n e .

' S F D X ' A N ' S H F L A G ' A R P A S S E D T O T H E R O T I N E W H O S E A D D R E S S I C O N T A I N E D I ' K E Y -L O G ' . T H I S M A K E S I E A S Y T R E C O N F I G U R E T H K E Y B O A R D S H O U L D Y O W I S H T D S O O E V E N T I N T E R C E P T A N A C T O N A N P A R T I C UL A K E Y , P R O V I D E D Y O O B E Y T H E R U L E S .

C h a n g e t h v e c t o r t p o i n t t y o u r o w r o u t i n e . W h e n y o u rr o u t i n e h a c o m p l e t e d , j u m p b a c k t t h K e r n e l a t h a p p r o p r i a t ep o i n t w h i c h w i l l d e p e n d o e x a c t l y w h a t y o u r r o u t i n e i d o i n g .Y o u r r o u t i n e m u s t s t a y i n v i s i b l e t t h e K e r n e l , i . e . y o m u s t

p r e s e r v e t h i n t e r f a c e . T h d e t a i l e d f l o w c h a r t s , t h D E C O D E Rr o u t i n e d e s c r i b e d b e l o w a n d d i s a s s e m b l e d l i s t i n g o t h K e r n e lK e y b o a r d r o u t i n e s s h o u l d p r o v i d e y o w i t h a l t h e i n f o r m a t i o ny o n e e d . A s a n e x a m p l e , h a v e i n c l u d e d P r o g r a m i n t h i s a r t i c l et s h o w h o y o m a g e c l i c k o u o e a c h k e y p r e s s e d .

S C A N N I N G

. A - S T A C K$ D C 0 1 - . A

s > Y E ( k e y n o t p r e s s e d )

. A - S T A C K( K E Y T A B ) . Y - .

< . A < # 5 ? ^

. A - # 3 ? ^

. O S H F L A G- S H F L

S T A C K - » . A

. - ,

N w

Y E ( s t o p k e y )

. Y - * S . F D X

N ( a l l d o n e ). Y

. X - 1 - . S T A C K - . AJ U M P ( K E Y T A B )

N ( n e x t k e y )

D e c o d e r

Y E ( n e x t s e t ) S E C A R R YS T A C K - . AR O T A T E . L E F T. A - S D C O O

T h T r a n s a c t o r 4 V o l u m e 5 I s s u e 0

Page 44: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 44/88

T h D E C O D E R R o u t i n e

D E C O D E R

S H F L A G ^ . A

S H I F T . L E F T

$ D 0 1 8 E O R # 2 ^ $ D 0 A 8

S F D X - . ( K E Y T A B ) . Y - . A

. A - * . X

$ E B 7 9 , X - K E Y T A B$ E B 7 A , X ~ K E Y T A B + 1

R e p e a t s

T h i s r o u t i n e i e n t e r e d a $ E B 4 8 . S H F L A G a n S F D X a r u s e d t c o m p u t e v a l u e i ' X w h i c h i t u r n i u s e d t f e t c h a t a b l e p o i n t e rf r o m t h t a b l e o a d d r e s s e s s t a r t i n g a l o c a t i o n $ E B 7 9 . T h p o i n t e ri s t o r e d i K E Y T A B a n w i l l p o i n t t o n o f o u r t a b l e s d e p e n d i n go t h v a l u e o S H F L A G . T h e i n d e x i S F D X i t h e n u s e d t f e t c ht h e a c t u a l C H R $ v a l u e o t h p r e s s e d k e f r o m t h t a b l e p o i n t e d a b K E Y T A B .

T h f o u r t a b l e s u s e d a r e :

1 N O R M A L l o c a t i o n $ E B 8 12 S H I F T l o c a t i o n $ E B C 23 C O M M O D O R E l o c a t i o n $ E C 0 34 C O N T R O L l o c a t i o n $ E C 7 8

E a c h t a b l e i 6 b y t e s i l e n g t h . T h l a s t b y t e i a l w a y s $ F F , j u s ti c a s e n k e y s w e r e f o u n d t b p r e s s e d ( a p a r t f r o m t h o s e i S H F L A G ) . I n t h i s c a s e S F D X w i l l s t i l l c o n t a i n i t i n i t i a l v a l u e o $ 4 0 .$ F i a l s o s t o r e d i a l l o c a t i o n s w h e r e n a c t i o n i e x p e c t e d f r o m

k e y . F o e x a m p l e t h C H R $ v a l u e f o ' * i t h C O N T R O L t a b l e i $ F F . T h i s i w h y o g e n a c t i o n w h e n y o p r e s s C o n t r o l - * .

A l s o p e r f o r m e d i n t h i s r o u t i n e i t h e s w i t c h o c h a r a c t e r s e t s i S H F L A G i f o u n d t c o n t a i n t h v a l u e ' $ 0 3 ' ( i . e . S h i f t a n C o m m od o r e p r e s s e d t o g e t h e r ) . I n t h i s c a s e , L S T S H F i e x a m i n e d t s e i f i ta l s o c o n t a i n s ' $ 0 3 ' . A L S T S H F h o l d s t h v a l u e o S H F L A G f r o mt h e p r e v i o u s a c t i v a t i o n o t h e i n t e r r u p t r o u t i n e , t h i s w i l l m e a n t h a tt h e s w i t c h h a a l r e a d y b e e n m a d e . N f u r t h e r a c t i o n i t a k e n a n j u m p i m a d e d i r e c t l y t o t h R E T U R N r o u t i n e . I L S T S H F i n o t t h es a m e a S H F L A G , t h e n t h v a r i a b l e , M O D E , i e x a m i n e d . I t h m o s t s i g n i f i c a n t b i i s e h e r e , t h e n t h c h a r a c t e r s e i s w i t c h e d -l o w e r t u p p e r c a s e o r v i c e v e r s a . T h i s i d o n e b y X O R ' i n g l o c a t i o n$ D 0 1 8 w i t h t h e v a l u e $ 0 2 .

T h C H R $ v a l u e f e t c h e d f r o m t h e a p p r o p r i a t e d e c o d e t a b l e i s t o r e d i n r e g i s t e r ' X ' . j u m p i t h e n m a d e t t h R E P E A T S r o u t i n e .

$ F I T H D E C O D E T A B L E S I G N I F I E S N U L L - K E YW H I C H M U S T N O T B I N S E R T E D I N T O T H K E Y B O A R D

B U F F E R .

M O D E ' C A B M O D I F I E D T D I S A B L E O E N A B L ET H S W I T C H I N G O C H A R A C T E R S E T S .

T h T r a n s a c t o r 4 V o l u m e 5 I s s u e 0

Page 45: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 45/88

T h R E P E A T S R o u t i n e

r e p e a t s )F o n e k e y - p r e s s , a j u m p i m a d e t t h K E Y B O A R D B U F F E Rr o u t i n e . O t h e r w i s e R P T F L G i e x a m i n e d . I t h m o s t s i g n i f i c a n t b i ( b i t 7 ' i s e t , t h e n a l k e y s w i l l b r e p e a t e d . I n o t , t h e n i b i ' 6 ' i ss e t , a l r e p e a t s a r e d i s a b l e d a n j u m p i m a d e t t h R E T U R Nr o u t i n e . F o a l o t h e r v a l u e s o R P T F L G , o n l y t h n o r m a l l y r e p e a ti n k e y s a r e r e p e a t e d , i . e . S P A C E , I N S T / D E L e t c .

k e i r e p e a t e d o n l y w h e n b o t h D E L A Y a n K O U N T h a v e b e e nd e c r e m e n t e d t z e r o . D E L A Y i a l w a y s s e t $ 1 w h e n k e i i n i t i a l l y p r e s s e d . I i d e c r e m e n t e d o n c e p e i n t e r r u p t a c t i v a t i o nu n t i l i h a r e a c h e d z e r o . T h e n t h s a m e p r o c e s s i r e p e a t e d f o K O U N T . W h e n K O U N T h a r e a c h e d z e r o , t h e n i i t i m e t r e p e a tt h e k e y . K O U N T i r e i n i t i a l i z e d t v a l u e o a n j u m p i m a d et t h K E Y B O A R D B U F F E R r o u t i n e i t h e r e a r n k e y s c u r r e n t l yi t h k e y b o a r d b u f f e r , i . e . i N D ' 0 ' . F o a l o t h e r c a s e s , t h R E P E A T S r o u t i n e j u m p s d i r e c t l y t t h R E T U R N r o u t i n e .

R P T F L G M A B E M O D I F I E D T T U R NO O O F F T H E R E P E A T P R O C E S S .

G e C l i c k O u O Y o u r K e y b o a r d :T h i s i a e x a m p l e o w a t p l u g y o u r o w r o u t i n e i n t o t h i n t e r r u p t c o d e . T h r o u t i n e r u n s i t h c a s s e t t e b u f f e r a n i i n i t i a l i z e d b d o i n g S Y t l o c a t i o n 8 2 ( $ 0 3 3 C ) .

B a s i c L o a d e r :

1 r e g e c l i c k o u o t h k e y b o a r d1 r e t h i s i d o n e b c h a n g i n g t h t a b l e s e t u p v e c t o r2 0 r e m k e y l o g a l o c a t i o n 6 5 ( $ 2 8 f ) t e n t e r t h e c l i c k3 r e r o u t i n e s i t u a t e d i t h e c a s s e t t e b u f f e r , i n e 4 0 r e m k e p r e s s i d e t e c t e d , w p r o d s i t c l i c k h i h e e l s .6 f o 8 2 t 8 6 r e a d p o k e i , n e x t7 s y 8 2 1 0 d a t a 1 2 1 1 d a t a1 1 d a t a 4

T h i s r o u t i n e i e n t e r e d a l o c a t i o n S E A E O . S F D X i c o m p a r e d w i t hL S T X . L S T X h o l d s t h v a l u e o S F D X f r o m t h p r e v i o u s a c t i v a t i o no t h e i n t e r r u p t r o u t i n e . T h e r e f o r e i S F D X i d i f f e r e n t t L S T X , i w i l l m e a n t h a t t h i s i n e k e y - p r e s s . I n t h i s c a s e , v a l u e o $ 1 i w r i t t e n t D E L A Y . D E L A Y i c o u n t o t h n u m b e r o a c t i v a t i o n so t h i n t e r r u p t d r i v e r b e f o r e w h i c h n e k e y - p r e s s m a b r e p e a t e d . T h i s a c c o u n t s f o t h n o t i c e a b l e d e l a y b e f o r e w h i c hk e s t a r t s t r e p e a t . I t h e r e w a n d e l a y i w o u l d b i m p o s s i b l e t u s t h k e y b o a r d .

1 2 d a t a

1 6 9 ,8 8

1 6 9 ,0 1 4 1 ,

7 3 , 1 4 1 ,9 6 , 1 6 5 ,1 5 1 4 1 ,2 4 , 2 1 2 ,

1 4 3 , 2 , 1 6 9 , 3 , 1 4 1 , 1 4 42 0 3 , 1 9 7 , 1 9 7 , 2 4 0 , 1 5 , 1 6 2

2 4 , 2 1 2 , 2 0 2 , 2 0 8 , 2 5 3 , 1 6 97 6 7 2 , 2 3 5 , 0 -

A s s e m b l e r C o d e :$ 3 3 C

s e I d # < c l i c ks t $ 2 8 fI d # > c l i c ks t $ 2 9 0c l r t

c l i c k I d $ c c m $ c b e c l e n dI d # 4 I d # 1 s t 5 4 2 9 6

c l o o p d e b n c l o o pI d # s t 5 4 2 9 6

c l e n d j m p $ e b 4 8

C o n c l u s i o n

; C a s s e t t e B u f f e r; D i s a b l e I n t e r r u p t s; C h a n g e K E Y L O G

t p o i n t t t h C l i c k r o u t i n e

; E n a b l e i n t e r r u p t s; R e t u r n t o B a s i c; D o n ' t c l i c k

i f S F D Xe q u a l s L S T X

; C l i c k C o u n t e r; T h a n k s J E F F G O E B E L

f o t h C l i c k P o k e; T i m e o u t

o c l i c k c o u n t; T u r n C l i c k

o f ; R e t u r n t i n t e r r u p t

T h i s c o m p l e t e s t h e d e s c r i p t i o n o t h K e r n e l K e y b o a r d D r i v e r .h o p e i h a p r o v e d i n s t r u c t i v e a n p r o v i d e d e n o u g h i n f o r m a t i o nf o t h o s e o y o w h w i s h t m a n i p u l a t e t h e d r i v e r t o s u i t y o u r o w p a r t i c u l a r n e e d s . I P a r t 2 w w i l l d e v e l o p o u o w d r i v e r , b a s e do k e y - c h a n g e s r a t h e r t h a n k e y - p r e s s e s . T h i s w i l l t r u l y b v e r s at i l e e n o u g h t s u i t e a n y b o d y ' s n e e d s , w h i l e s t i l l p r e s e r v i n g t h s t a n d a r d i n t e r f a c e t B A S I C a n o t h e r a p p l i c a t i o n s t h a t c u r r e n t l yu s t h K e r n e l D r i v e r f o t h e i r k e y b o a r d h a n d l i n g .

T h T r a n s a c t o r 4 V o l u m e 5 I s s u e 0

Page 46: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 46/88

F i x i n gC o m m o d o r e K e y b o a r d s

H a r o l d A n d e r s o nO a k v i l l e , O n t .

R e p a i r y o u r f a i l i n g k e y b o a r d y o u r s e l f

M o s t p e o p l e w h h a v e a a g i n g P E h a v e b n o e n c o u n t e r e dp r o b l e m s w i t h t h k e y b o a r d . T h p r o b l e m s u s u a l l y s t a r t w i t hd o u b l e o t r i p l e l e t t e r s b e i n g g e n e r a t e d e v e r y t i m e a k e i s h i t .E v e n t u a l l y t h s i t u a t i o n d e t e r i o r a t e s t t h e p o i n t w h e r e t h k e d o e s n o g e n e r a t e r e s p o n s e a a l l . T h k e y s t h a t g f i r s t a r u s u a l l y t h o s e m o s t c o m m o n l y u s e d , s u c h a s t h e s h i f t , s p a c e , a n r e t u r n k e y s . I y o h a v e k i d s p l a y i n g g a m e s o y o u r c o m p u t e r , t h k e y s u s e d i t h g a m e w i l l s o o n g i v e t r o u b l e . T h l e t t e r ' A s e e m st g v e r y q u i c k l y , s i n c e i i t h " g u n " i l o o g a m e s .

L e m e x p l a i n w h a t i h a p p e n i n g h e r e . T h k e y b o a r d o f v i r t u a l l ya n c o m p u t e r i r e a l l y c o l l e c t i o n o s w i t c h e s , o n f o e a c h k e y .O t h P E a n C o m m o d o r e 6 4 t h c o m p u t e r l o o k s a t h e s es w i t c h e s 6 0 t i m e s s e c o n d t s e i t h e y a r e c l o s e d . A s o o n a s t h ec o m p u t e r s e e s t h a t s w i t c h i c l o s e d , i p r i n t s l e t t e r . T h l e t t e rw i l l n o b p r i n t e d a g a i n u n l e s s t h s w i t c h i o p e n e d a n d r e c l o s e d .( E x c e p t i o n s a r e t h e s p a c e a n c u r s o r - c o n t r o l k e y s , w h i c h h a v e a a u t o - r e p e a t f e a t u r e . )

I t h c o n n e c t i o n m a d e b t h k e y s w i t c h i i n t e r m i t t e n t , t h c o m p u t e r w i l l t h i n k t h a t i h a b e e n o p e n e d a n c l o s e d s e v e r a lt i m e s e v e n t h o u g h y o h a v e o n l y p u s h e d i o n c e .

T h e r e a r e s e v e r a l d i f f e r e n t t y p e s o s w i t c h e s u s e d i c o m p u t e rk e y b o a r d s . T h t y p e t h a t C o m m o d o r e u s e s a r m a d e w i t h e l e c t r ic a l l y c o n d u c t i n g r u b b e r . F i g u r e o n s h o e s p a r t o d i s a s s e m b l e dP E k e y b o a r d . T h b o t t o m o t h p i c t u r e s h o w s t h c o n t a c t b o a r dw h i c h h a b e e n r e m o v e d f r o m t h u n d e r s i d e o t h k e y b o a r da s s e m b l y . Y o w i l l n o t i c e t h a t i i c o v e r e d w i t h p a t t e r n s t h a t l o o kl i k e i n t e r l o c k i n g f i n g e r s . T h e s e f i n g e r s a r m a d e o g o l d - p l a t e dc o p p e r a n f o r m t h t w p o l e s o t h s w i t c h . T h t o o t h e p i c t u r es h o w s c o l l e c t i o n o f w h i t e c i r c l e s w i t h b l a c k d o t s a t h c e n t e r .T h w h i t e c i r c l e s a r t h b o t t o m e n d s o t h k e p l u n g e r s a n t h b l a c k d o t s a r c o n d u c t i n g r u b b e r p a d s . W h e n t h k e y b o a r d i

a s s e m b l e d , t h e c o n t a c t b o a r d i t u r n e d o v e r a n s c r e w e d t t h u n d e r s i d e o t h k e y b o a r d a s s e m b l y s t h a t t h r u b b e r p a d s s i a b o u t 1 / o a i n c h a w a y f r o m t h g o l d - p l a t e d f i n g e r s . W h e nk e i p r e s s e d , t h e c o n d u c t i n g r u b b e r p a m o v e s d o w n t t o u c ht h e g o l d f i n g e r s a n s h o r t - c i r c u i t s t h e m t o g e t h e r , t h u s c l o s i n g t h es w i t c h .

T h k e y b o a r d o C o m m o d o r e 6 w o r k s o n t h s a m e p r i n c i p l ee x c e p t t h a t t w g o l d - p l a t e d " c o n t a c t s " a b o u t 1 / 4 o a i n c h a p a r ta r u s e d i n s t e a d o i n t e r l o c k i n g f i n g e r s . T h p i e c e o r u b b e r w h i c hs h o r t c i r c u i t s t h e g o l d c o n t a c t s i s h a p e d b i l i k e d o b o n e a n dt h e n d s o t h b o n e p r e s s o t h e c o n t a c t s w h e n t h k e i p r e s s e d .T h i s m o d i f i e d d e s i g n h a b e e n u s e d b e c a u s e i a l l o w s c o n d u c t o r st o t h e r k e s w i t c h e s o t h e c o n t a c t b o a r d t r u b e t w e e n t h t w c o n t a c t s . T h i s s i m p l i f i e s t h f a b r i c a t i o n o t h c o n t a c t b o a r d .

W h e n t h k e y b o a r d s t a r t s t g i v e t r o u b l e , t w t h i n g s a r e h a p p e ni n g . T h f i r s t i s t h a t t h r u b b e r p a a n t h g o l d - p l a t e d s u r f a c e sa r e g e t t i n g c o v e r e d w i t h d u s t w h i c h i n s u l a t e s t h s u r f a c e s . T h o t h e r p r o b l e m i t h a t a f t e r l o n g u s e , t h s u r f a c e o t h r u b b e r i t s e l fs e e m s t l o s e i t a b i l i t y t c o n d u c t e l e c t r i c i t y . B o t h o t h e s ep r o b l e m s a r e a s y t f i o n c e t h k e y b o a r d i o p e n e d u p

B e f o r e y o c a s e r v i c e t h k e y b o a r d , y o u h a v e t g e a i t S t a r t b u n p l u g g i n g t h c o m p u t e r . O P E T s t h w h o l e t o o t h c o m p u t e rc a n b e s w u n g u p T h s c r e w s t h a t h o l d t h e t o p d o w n a r a e a c he n o t h k e y b o a r d u n d e r t h l i o t h w h i t e u p p e r c o v e r f o t h c o m p u t e r . O t h C o m m o d o r e 6 t h e r e a r e t h r e e s c r e w s a l o n g t h u n d e r s i d e o t h f r o n t e d g e o t h c o m p u t e r . I b o t h c a s e s t h e f r o n to t h c o m p u t e r c a n b e l i f t e d u w h e n t h e s e s c r e w s a r r e m o v e d .O t h C o m m o d o r e 6 i w i l l b n e c e s s a r y t u n p l u g t h w i r e s t t h e r e d p i l o t l i g h t a s o o n a t h c o v e r i l i f t e d . T h p l u g i j u s tb e l o w t h f l a p o t h m e t a l i z e d c a r d b o a r d s h i e l d t h a t c o v e r s t h m a i n c i r c u i t b o a r d . N o t i c e w h i c h w a a r o u n d t h i s p l u g g o e s s t h a t

T h T r a n s a c t o r 4 V o l u m e 5 I s s u e 0

Page 47: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 47/88

y o c a p u i b a c k p r o p e r l y .

W h e n y o l o o k a t h b o t t o m o t h k e y b o a r d y o w i l l s e t h a t t h c o n t a c t b o a r d i h e l d t t h b o t t o m b y a b o u t 2 t i n y s c r e w s . B e f o r et a k i n g t h e s c r e w s o u t , y o w i l l h a v e t r e m o v e t h t w w i r e s t h a tg t t h s h i f t l o c k s w i t c h ( r i g h t b e l o w t h s h i f t l o c k k e y ) . Y o w i l ln e e d s o l d e r i n g i r o n t d t h i s . I s o l d e r i n g i r o n i h a r d i t e m t c o m e b y w o u l d s u g g e s t t h a t y o e x t e n d t h w i r e s o t h s w i t c hs t h a t i f u t u r e t h e c o n t a c t b o a r d c a n b e r e m o v e d w i t h o u tu n s o l d e r i n g t h w i r e s .

W i t h t h b o t t o m o t h k e y b o a r d o f f , y o c a c l e a n o f t h o f f e n d i n g c o m p o n e n t s . T h p a d s a n g o l d s u r f a c e s c a u s u a l l y b c l e a n e d b b r u s h i n g t h e m w i t h a c l e a n , d r y p a i n t b r u s h . I y o s m o k e l o t , y o m a h a v e f i l m o f t a o v e r t h s u r f a c e s . w o u l ds u g g e s t t h a t y o u r e m o v e i w i t h m e t h a l a l c o h o l o a c l e a n r a g .

I t h k e y b o a r d s t i l l g i v e s t r o u b l e , t h e s u r f a c e o t h r u b b e r p a c a b r e n e w e d b u s i n g V E R Y f i n e s a n d p a p e r o t h e m . ( 4 0 0 g r i ts a n d p a p e r o t h e t y p e u s e d f o w e s a n d i n g i b o d y s h o p s s e e m s t w o r k w e l l . ) S a n d t h e m j u s t e n o u g h t m a k e t h s u r f a c e o t h r u b b e r d u l l . I n o r d e r t s a n d t h e m y o w i l l f i n d i e a s i e r t p o t h p a d s o u t , a s h o w n i f i g u r e 2 a n s t i c k t h e m o v e r t h s q u a r e ,u n s h a r p e n e d e n o p e n c i l . I w o u l d b f a i r l y t e d i o u s t d t h i s t oa l o t h k e y s s s u g g e s t t h a t y o u d o i o n l y t t h k e y s g i v i n gt r o u b l e . I y o c a n ' t g e t t h s a n d p a p e r , s w a p t h p a d s o t h e n d so t h k e y p l u n g e r s s t h a t t h t r o u b l e s o m e p a d s a r o s e l d o m -u s e d k e y s l i k e a n X T h p a d s c a n a l s o b e p u r c h a s e d a s p a r ep a r t f o a b o u t d o l l a r e a c h .

A l t h o u g h t h i s s o u n d s c o m p l i c a t e d , a k e y b o a r d c a n b e r e p a i r e d i a b o u t 1 / 2 a h o u r , w h i c h d e f i n i t e l y b e a t s l i v i n g w i t h o n t h a tg i v e s t r o u b l e .

L i f e W i t h t h 1 5 4 1 M i c h a e l Q u i g l e yV a n c o u v e r , B . C .

D y o h a t e y o u r 1 5 4 1 d i s k d r i v e w i t h p a s s i o n ? m e a n d o y o ul e a v e i s i t t i n g i t h f r o n t s e a t o f y o u r c a w i t h t h w i n d o w s o p e n ,t h d o o r s u n l o c k e d a n l a r g e s i g n a t t a c h e d r e a d i n g " S T E A LM E " ? I s o w e l c o m e t t h c l u b . I ' M s u r e i B e n j a m i n F r a n k l i nw e r e a l i v e t o d a y , h e ' d r e v i s e o n o h i m o s t f a m o u s q u o t e s t r e a d : " I n t h i s w o r l d , n o t h i n g i c e r t a i n b u d e a t h a n t a x e s . a n t h 1 5 4 1 d e v e l o p i n g p r o b l e m s . "

P r o b a b l y t h b i g g e s t p r o b l e m o t h 1 5 4 1 i " g o i n g o u o a l i g nm e n t " . W h a t t h i s m e a n s i t h a t t h r e a d / w r i t e h e a d i u n a b l e t c o r r e c t l y f i n d i n f o r m a t i o n o t h d i s k . m a j o r i n d i c a t i o n o t r o u b l e i t h r e L E o t h f r o n t o t h e d r i v e f l i c k e r i n g w h e na t t e m p t i n g t r e a d d i s k s , p a r t i c u l a r l y t h o s e n o t f o r m a t t e d o y o u ro w d r i v e , o r d i s k s w h i c h y o u m a d e s e v e r a l m o n t h s a g o .

T h c a u s e o a l t h i s i r e l a t i v e l y s i m p l e . T h d r i v e c o n t a i n ss t e p p e r m o t o r w h i c h a d v a n c e s t h h e a d f r o m o n t r a c k t t h n e x t ;n e a s y t a s k , s i n c e t h e t r a c k s a r e a f r a c t i o n o a i n c h a p a r t . T h s t e p p e r m o t o r s h a f t g o e s u t h r o u g h p u l l e y w h i c h i c o n n e c t e d t

m e t a l b a n d , w h i c h i t u r n i a t t a c h e d t t h r e a d / w r i t e h e a d .W h e n e v e r n e d i s k i f o r m a t t e d o - w o r s e y e t , a e r r o r i d e t e c t e d o " c o p y p r o t e c t e d " d i s k t h e p u l l e y k n o c k s u a g a i n s t

h e a d s t o p w h i c h i a t h e h y p o t h e t i c a l t r a c k z e r o . T h i s i t h s o u r c e o t h r a t t l i n g n o i s e w h i c h o c c u r s w h e n a d i s k i " N E W e d " .

A f t e r X n u m b e r o k n o c k s a g a i n s t t h e h e a d s t o p , t h s h a f t i n t h m i d d l e o t h p u l l e y b e g i n s t s l i p e v e r s s l i g h t l y , s i n c e t h e t w a r n o p e r m a n e n t l y a t t a c h e d t e a c h o t h e r . T h r e s u l t i t h a t t h r e a d / w r i t e h e a d s l i p s o u o p o s i t i o n a w e l l . T h e r e i t h e o r y t h a tt h h e a t p r o d u c e d b y t h e d r i v e ( w h i c h i c o n s i d e r a b l e ) m a a l s oc o n t r i b u t e t t h i s m i s a l i g n m e n t .

T h c u r e s f o r t h i s m a l a d y a s i d e f r o m u s i n g t h e d r i v e a s p e e db u m p i t h a l l e y b e h i n d y o u r h o u s e a r v a r i e d . A a l i g n m e n td i s k a n o s c i l l o s c o p e a r n e c e s s a r y f o p r e c i s i o n . I s o m e c a s e s ,

m o v i n g t h e s t e p p e r m o t o r s l i g h t l y a f t e r l o o s e n i n g t h s c r e w sw h i c h h o l d i t t h b o t t o m o t h e d r i v e m a b s u f f i c i e n t . I n m o r ee x t r e m e c a s e s , n o t c h h a s t b c a r v e d i t h e t o p o t h e s t e p p e rm o t o r s h a f t t s e r v e a s c r e w - l i k e s l o t w h e r e t h e p u l l e y i m a n u a l l y m o v e d b a c k t i t c o r r e c t l o c a t i o n .

O t h e r s o l u t i o n s o p e r m a n e n t n a t u r e ( a f t e r a l i g n i n g t h e d i s k , o fc o u r s e ) i n c l u d e u s i n g K r a z y G l u e o s o m e s u c h e p o x y s u b s t a n c e t h o l d t h e p u l l e y t t h s h a f t . T h i s m a b d o n e i c o m b i n a t i o n w i t hd r i l l i n g h o l e t h r o u g h t h p u l l e y t t h c e n t r a l s h a f t a n i n s e r t i n g

p i n . ( S u c h a p r e c i s i o n j o m u s t b d o n e w i t h c a r e , b e c a u s e p i e c e so m e t a l c a f i n d t h e i r w a d o w n t t h i n s i d e o t h s t e p p e r m o t o r ,r e n d e r i n g i t o t a l l y u s e l e s s . ) I s h o u l d b p o i n t e d o u t h a t a n o t h e s e a c t i o n s w i l l v o i d y o u r w a r r a n t y , i i t ' s s t i l l i e f f e c t .

E d i t o r ' s n o t e : W h i l e t h 1 5 4 1 d o e s h a v e t h b u o o c c a s i o n a l l yg o i n g b i o u o a l i g n m e n t , o t h w h o l e i h a f e a t u r e s t h a t c a i fb e f o u n d o m u c h m o r e e x p e n s i v e d r i v e s . I t ' s n o t h f a s t e s t t h i n gi t h e w o r l d , b u t i t ' s e x t e n s i v e R O c o d e m a k e s i f a i r l y " s m a r t " ,a n g i v e s i l o t s o f e a t u r e s a n f l e x i b i l i t y . I t ' s i r o n i c , p e r h a p s , t s t a t e t h i s a f t e r t h a b o v e a r t i c l e , b u t h 1 5 4 1 d r i v e m a b o n o t h e b e s t d e a l s f o r t h e m o n e y i t h m i c r o c o m p u t i n g m a r k e t . - T E d

T h T r a n s a c t o r 4 V o l u m e 5 I s s u e 0

Page 48: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 48/88

L e a r n i n g T h L a n g u a g e O D O R i c h a r d T E v e r s , E d i t o r

I t h i s w o r l d t h e r e a r e m a n y g r e a t m y s t e r i e s , o n o w h i c h i t h C o m m o d o r e D i s k O p e r a t i n g S y s t e m ( D O S ) . d i s k d r i v e i f o m o s ta m a g i c a l c o n t a i n e r i w h i c h d i s k e t t e s a r e i n s e r t e d t s t o r e v a s tq u a n t i t i e s o f d a t a , a n r e t r i e v e t h s a m e w i t h u n e r r i n g a c c u r a c y .T h e r e a r b u f e b e i n g s w o r l d w i d e w h f u l l y u n d e r s t a n d t h t e a c h i n g s o D O S , b u a l a s , f e w h a v e t h p o w e r o w r i t t e n c o m u n i c a t i o n s a t h e i r a c c e s s . T o d a y , w w i l l e m b a r k o a j o u r n e yi n t o t h d e e p r e c e s s e s o D O S , t g r a d u a l l y b r i n g a b o u t a u n d e r s t a n d i n g o h o i w o r k s , a n w h i i s u p e r i o r t o t h e r s .

C o m m o d o r e D O d o e s n o t r e q u i r e ' b o o t i n g u p b e f o r e a c c e s s t t h e d r i v e c a b e g i n . U n l i k e o t h e r m a n u f a c t u r e r s ' c o m p u t e r s y t e m s , C o m m o d o r e D O i h e l d i R O M , a n i a l w a y s w i t h u s O n c e p o w e r e d u p D O c o m e s a l i v e , a n w i t h i n u m e r o u sa v e n u e s o d i s k d r i v e p o w e r a r e x p o s e d . W i t h i n t h d r i v e ,k n o w l e d g e i f o u n d . C o m m o d o r e h a t h m e n t a l f o r t i t u d e t i n c o r p o r a t e ' i n t e l l i g e n c e ' i n t o t h e i r d r i v e s , t h e r e f o r e t h e y c o m ec o m p l e t e w i t h m i c r o p r o c e s s o r ( s ) , v a r i o u s I C ' s , f a i r q u a n t i t y o R A M , a n l a r g e c h u n k o R O M .

B e f o r e d e l v i n g i n t o t h i n n e r c o m m a n d s r e q u i r e d t h e l p y o c o m m u n i c a t e w i t h D O S , l e t ' s g e t i n t o a b i o t h e o r y .

B i O T h e o r y

A l D O c o m m u n i c a t i o n s o c c u r t h r o u g h t h C o m m a n d c h a n n e l ;c h a n n e l 1 5 T r e c a p , t h e i n c a n t a t i o n r e q u i r e d t o i n c i t e c h a n n e l 1 i s

O P E N L F , U A , 1 5

w h e r e L F r e p r e s e n t s t h l o g i c a l f i l e a d d r e s s ( 1 - 1 2 7 ) , U r e p r e s e n t st h e u n i t a d d r e s s o t h d r i v e , u s u a l l y 8 a n f i n a l l y , 1 i t h s e c o n d a r y a d d r e s s , w h i c h i m a n d a t o r y .

O n c e t h i s c o m m u n i c a t i o n s l i n e h a b e e n s e u p f u l l d u p l e xc o m m u n i c a t i o n s c a b e g i n . I t h s u b - s e c t i o n s s o o n t f o l l o w , a l t h s p e c i a l d i s k c o m m a n d s w i l l b c o v e r e d c o r r e c t l y , s y o c a l e a r n t s p e a k D O S , t h e r e f o r e b r i n g i n g y o c l o s e r t y o u r D O S . T i l lt h e n , m o r e t h e o r y i r e q u i r e d .

M o r e T h e o r y

O n c e t h e 1 5 t h c h a n n e l h a b e e n O P E N e d , c o m m u n i c a t i o n s c a b e g i n , a h a v e s t a t e d i t h p r e c e d i n g p a r a g r a p h . A m o n g D O s l e u t h s , t h C o m m a n d c h a n n e l i o f t e n r e f e r r e d a t h C o m m a n dB u f f e r , C M D B U F . F o t h 1 5 4 1 a n 2 0 3 1 L P , t h i s i h e l d a $ 0 2 0 0 -

$ 0 2 2 9 i R A M . T h e 4 0 4 0 , 8 0 5 0 , a n 8 2 5 0 h a v e i t u c k e d a w a y a $ 4 3 0 0 - $ 4 3 3 A . T h c o m m a n d b u f f e r t t h D O i l i k e t h e i n p u tb u f f e r t y o u r c o m p u t e r . E v e r y t h i n g o i m p o r t a n c e g o e s t h r o u g ht h i s a r e a , i d e c i p h e r e d , t h e n a c t e d u p o n . A l c o m m a n d s , f i l e n am e s , a n s p e c i a l c h a r a c t e r s , o r s i m p l y , w h a t e v e r i t a k e s t m a k et h D O s t a n d u p a n d l i s t e n .

W h e n e v e r a e r r o r h a o c c u r r e d w i t h t h d r i v e , i a g a i n i c o t r o l l e d t h r o u g h t h 1 5 t h c h a n n e l . T h i s e r r o r c a n b e r e a d f r o m t h d r i v e v i I N P U T * o G E T * s t a t e m e n t s , b u t i c a a l s o b P E E K e d ,v i a d i s k e q u i v a l e n t , f r o m R A M . T h e r r o r b u f f e r i t h 1 5 4 1 /2 0 3 1 L P i a $ 0 2 D 6 - $ 0 2 F 8 , a n d c a n b e f o u n d a l o c a t i o n s $ 4 3 D C -$ 4 3 F F f o t h 4 0 4 0 / 8 0 5 0 / 8 2 5 0 d u a l u n i t s .

O n c e t h D O r e c e i v e s y o u r c o m m a n d i n p u t , i b r e a k s i d o w ni n t o s i m p l e t e r m s t h a t c a n b e r e a d i l y a c t e d u p o n . I y o u w a n t e d t d R E A D f r o m d i s k , a l t h n e c e s s a r y R A l o c a t i o n s w o u l d b s e u f i r s t b t h I n t e r f a c e P r o c e s s o r ( I P ) , t h e n t h v a l u e o $ 8 w o u l db p u i t h J O Q U E . F r o m t h i s p o i n t t h e s y s t e m w o u l d w a i t f o t h F l o p p y D i s k C o n t r o l l e r ( F D C ) t c o m e a l o n g a n d i s c o v e r t h j o w a i t i n g o t h J O Q U E . O n c e d i s c o v e r e d , t h e F D w o u l d k i c ki a n d R E A D . I t h i s w a y , w h a t e v e r y o t e l l y o u r d r i v e t d c a b e h a n d l e d q u i c k l y a n s m o o t h l y w i t h c o - o p e r a t i o n w i t h i n .

T h J O Q U E , a d e s c r i b e d a b o v e , i t h s p e c i a l s p o t w i t h i n t h d r i v e t h a t i n f o r m s t h F D w h a t t d o I p a s t , C o m m o d o r e p u c o u p l e o m i c r o p r o c e s s o r s i t h e i r d r i v e u n i t s , n a m e l y t h 4 0 4 0 ,8 0 5 0 , a n 8 2 5 0 , f o t h p u r p o s e o h a n d l i n g d i f f e r e n t f u n c t i o n s .T h f i r s t p r o c e s s o r , t h e I n t e r f a c e P r o c e s s o r ( I P ) , i r e s p o n s i b l e f o a c c e p t i n g c o m m a n d s v i a t h e 1 5 t h c h a n n e l , a n d e c i p h e r i n g w h a tt h e y a c t u a l l y m e a n . F r o m h e r e , t h I s e t s u a l t h n e c e s s a r yc o n d i t i o n s f o t h F l o p p y D i s k C o n t r o l l e r ( F D C ) , a n s t o r e s t h a p p r o p r i a t e j o c o d e o t h J O Q U E . E v e r y 1 m s t h J O Q U i s c a n n e d b t h F D C , j u s t t s e i a n a c t i o n i r e q u i r e d . I n o t ,t h F D g o e s b a c k t h r o u g h i t r o u n d s d o i n g a n h o u s e k e e p i n gc h o r e s r e q u i r e d . I C o m m o d o r e l i n g o , t h i s i r e f e r r e d t a g o i n gi n t o t h I D L E l o o p , w a i t i n g f o s o m e t h i n g t d o

I j o i e n c o u n t e r e d o t h J O Q U E , t h F D t a k e s i a n a c t su p o n i t O n c e t h j o h a b e e n c o m p l e t e d , c o r r e c t l y o i n c o r r e c t l y ,t h F D f i n d s t h a p p r o p r i a t e e r r o r c o d e t d e s c r i b e t h e a c t i o np e r f o r m e d , a n s t o r e s t h a t o v e r t o o t h o r i g i n a l j o c o d e i t h J O Q U E . I n t h i s w a t h F D c a l e t h I k n o w t h a t t h e j o b h a b e e n c o m p l e t e d , o h a r u i n t o f e s n a g s a l o n g t h w a y . F r o mh e r e , t h I t a k e s t h e e r r o r c o d e a n s t o r e s t h c o r r e s p o n d i n gd e s c r i p t i o n i t h e e r r o r b u f f e r . c l e a n a n n e a t s o l u t i o n .

T h T r a n s a c t o r 4 V o l u m e s , I s s u e 0 4

Page 49: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 49/88

A s t a t e d i n i t i a l l y , C o m m o d o r e a o n t i m e p u f e m i c r o p r o c e ss o r s i t h e i r d r i v e u n i t s . T h 4 0 4 0 h a o n 6 5 0 2 a n d o n e 6 5 0 4 .B o t h t h 8 0 5 0 a n 8 2 5 0 h a v e t w i n 6 5 0 2 ' s . B u t h e n c a m e t h d a y so t h e 1 5 4 1 a n 2 0 3 1 L P a n t h m i c r o p r o c e s s o r c o u n t w e n t d o w nt o n e , a s i n g l e 6 5 0 2 . C o m m o d o r e f o u n d t h a t w i t h t h e c o r r e c tc o d i n g , o n s e v e r e l y o v e r w o r k e d p r o c e s s o r c o u l d d t h e j o b o t w o . q u e s t i o n r e m a i n s f o m o s t : W h o v e r w o r k a n t h e r e f o r es l o w d o w n t h s y s t e m w i t h o n p r o c e s s o r , w h e n t w h a b e e np r o v e n i p a s t ? T h e r e i C o m m o d o r e l o g i c w o r k i n g h e r e .

I o r d e r t b r i n g t h e p r i c e o t h u n i t s d o w n t r e a s o n a b l e l e v e l ,C o m m o d o r e g o t s m a r t . T h l a r g e r d r i v e s w e r e , a n s t i l l a r e , v e r ye x p e n s i v e , i y o c a f i n d t h e m . T h n e w e r d r i v e s w e r e m a d e t b a f f o r d a b l e . S p e c i f i c a l l y , t h 1 5 4 1 w a m a d e t b a f f o r d a b l e . N l o n g e r d o e s i h o s t t h e e x p e n s i v e , b u r e l i a b l e , I E E E p o r t . I t ' s b e e nr e p l a c e d b t h S e r i a l P o r t . T h o u g h t h i s d o e s s l o w d o w n a c c e s s t t h d r i v e c o n s i d e r a b l y , ( 6 s e c o n d s t L O A D 1 0 b l o c k p r o g r a mf r o m 1 5 4 1 i n t o C 6 v s 1 s e c o n d s f o t h s a m e f r o m a n 8 2 5 0i n t o a 8 0 3 2 ) , i d o e s h e l p k e e p t h p r i c e l o w .

A n o t h e r m e t h o d u s e d t d r o p t h e p r i c e t a g w a t d e c r e a s e t h q u a l i t y o t h s t e p p e r m o t o r a n d s t o p m e c h a n i s m . F o t h i s r e a s o n ,y o w i l l f i n d t h a t t h 1 5 4 1 s a n 2 0 3 1 s r e q u i r e s e r v i c e m o r e o f t e nd u t t h e s t o p m e c h a n i s m k n o c k i n g t h a l i g n m e n t o u t . E v e r h e a rt h a t f a m i l i a r G R I N D G L I C K c o m i n g f r o m y o u r 1 5 4 1 , a n w o n d e r e dw h a t w a s h a p p e n i n g ? I t ' s t h d r i v e t r y i n g t c o m p e n s a t e f o b a d i s k e t t e o s t e p p e r m o t o r t h a t i s l i g h t l y o u o w h a c k b t h r o w i n g B U M P c o m m a n d o t h J O Q U a n t e l l i n g t h F D t B U M P t h h e a d a g a i n s t t h b a c k s t o p . T h i s i h o D O d e a l sw i t h t h p o s s i b i l i t y t h a t t h h e a d c a r r i a g e h a j u m p e d o u o t h g r o o v e i t h h e a d p o s i t i o n i n g m e c h a n i s m . T h s t e p p e r m o t o rs w i n g s i n t o a c t i o n t h u s s l a m - d a n c i n g i t s e l f u a g a i n s t t h s t o pm e c h a n i s m n u m e r o u s t i m e s , c r e a t i n g t h e h o r r i b l e n o i s e . W h e ne v e r t h i s n o i s e o c c u r s , t h e r e i c h a n c e t h a t y o u r d r i v e i n o t s og e n t l y b e i n g t h r o w n o u o w h a c k . R e m e m b e r t h a t t h n e x t t i m ey o c o n s i d e r a d i s k p r o t e c t e d p a c k a g e . D u t t h i n h e r e n t R E A De r r o r s t b e e n c o u n t e r e d o t h d i s k e t t e s u r f a c e , t h B U M Pc o m m a n d w i l l b e u s e d a l o t . T h a t d i s k p r o t e c t e d p a c k a g e y o j u s tb o u g h t c o u l d c o s t y o i t h l o n g r u a t h r e p a i r s h o p .

F o t h o s e o y o w h a r i n t e r e s t e d , t h J O Q U i l o c a t e d a $ 1 0 0 3 - $ 1 0 0 F f o t h 4 0 4 0 / 8 0 5 0 / 8 2 5 0 d r i v e u n i t s , a n d $ 0 0 0 0 -$ 0 0 0 5 f o t h 1 5 4 1 / 2 0 3 1 L P . B e l o w i a c h a r t d e s c r i b i n g t h a p p r o p r i a t e j o n u m b e r a n i t r e l a t i v e d e s c r i p t i o n . P l e a s e e x e rc i s e c a u t i o n b e f o r e u s i n g t h J O Q U t h o u g h . R A p o i n t e r sn e c e s s a r y f o t h c o r r e c t e x e c u t i o n o y o u r w i s h e s s h o u l d b s e u C O R R E C T L Y b e f o r e p l a c i n g a n j o n u m b e r o t h J O B Q U E .W h e n u s i n g t h J O Q U E , y o a r l i t e r a l l y b y p a s s i n g t h d r i v e ' sb u i l t i p r o t e c t i v e m e c h a n i s m s . T h e r e f o r e , o n w r o n g m o v e a n y o m a f i n d y o u r s e l f t r y i n g t p r t h h e a d a w a y f r o m t h i n s i d eo t h e d r i v e c a s i n g .

F D E r r o r N u m b e r R e t u r n e d O T h J o Q u

C o d e O p e r a t i o n$ 8 $ 9 $ A $ B $ C

F D R E A DF D C W R I T EF D V E R I F YF D S E E KF D B U M P

$ D F D C J U M P$ E F D C E X E C U T E

F D J o b C o d e sD e s c r i p t i o n

- r e a d d a t a f r o m d i s k e t t ew r i t e d a t a t d i s k e t t ev e r i f y w r i t t e n d a t al o o k f o a s p e c i f i c s e c t o rb u m p t h h e a d f o c o r r e c t i o nj u m p t m a c h i n e l a n g u a g e r o u t i n e

- e x e c u t e m a c h i n e l a n g u a g e r o u t i n e

C o d e$ 0 $ 0 $ 0 $ 0 $ 0 $ 0 $ 0 $ 0 $ 0 $ 0 $ 0

E r r o rO R E A D E R R O RR E A D E R R O RR E A D E R R O RR E A D E R R O RR E A D E R R O RW R I T E E R R O RW R I T E P R O T E C T O R E A D E R R O RR E A D E R R O RR E A D E R R O R

D e s c r i p t i o n

c a n ' t f i n d b l o c k h e a d e rn s y n c c h a r a c t e rd a t a b l o c k n o t p r e s e n tc h e c k s u m e r r o r i d a t a b l o c k

- b y t e d e c o d i n g e r r o rw r i t e / v e r i f y e r r o rw r i t e w i t h w r i t e p r o t e c t o c h e c k s u m e r r o r i h e a d e r b l o c kd a t a e x t e n d s i n t o n e x t b l o c kd i s k I m i s m a t c h

W i t h t h a t c h a r t c o m p l e t e , i t ' s t i m e t m o v e o n d e e p e r i n t o t h c o m m a n d s t h a t w i l l a l l o w y o t c o m m u n i c a t e w i t h y o u r D O S .T h i n f o r m a t i o n j u s t c o v e r e d i r a t h e r h i g h l e v e l . T h e r e f o r e , t h f o l l o w i n g c o m m a n d s s h o u l d b m a s t e r e d b e f o r e c o n s i d e r i n g w o r ki n d i r e c t l y w i t h t h e F D C .

C o n v e n t i o n s

f e s h o r t f o r m s w i l l b e u s e d w h e n d e s c r i b i n g a c c e s s t t h D O S .T h e s e s h o r t f o r m s a r r e a l l y d e s c r i p t i o n s f o n u m e r i c v a l u e sn e c e s s a r y f o t h e c o r r e c t e x e c u t i o n o t h c o m m a n d b D O

A A C D L N

S

U

= m e m o r y a d d r e s s h i g h b y t e 0 - 2 5 5m e m o r y a d d r e s s l o b y t e 0 - 2 5 5c h a n n e l u s e d i l i e u o L t p r e v e n t c o n f u s i o n l a t e rd r i v e n u m b e rl o g i c a l f i l e n u m b e rn u m b e r o c h a r a c t e r sd e s i r e d p o s i t i o n w i t h i n b u f f e rf i l e s e c o n d a r y a d d r e s s n u m b e rs e c t o rt r a c kd r i v e u n i t a d d r e s s

O o r l1 - 1 2 71 - 2 5 50 - 2 5 52 - 1 4 , 1 C m C h a n0 - m a x1 - m a xU s u a l l y 8

I w i l l a l s o b a s s u m e d , a s t a t e d e a r l i e r , t h a t t h c o m m a n dc h a n n e l i O P E N b e f o r e a t t e m p t i n g t s e n d c o m m a n d s o v e r t h b u s .

B - A : B l o c k - A l l o c a t e

O y o u r d i s k e t t e l i e s a i m p o r t a n t b l o c k o f d a t a . T h i s i t h B l o c kA v a i l a b i l i t y M a p , o s i m p l y s t a t e d , t h B A M . T h B A i r e s p o n s ib l f o m a n a g i n g t h w h e r e a b o u t s o a l y o u r f i l e s , a n m a k i n gs u r e t h a t y o u d o n o w r i t e o v e r t h s a m e b l o c k o i n f o r m a t i o nt w i c e . T h B A i b i m a o e a c h a n e v e r y t r a c k a n s e c t o r o y o u r d i s k e t t e a n d , w i t h t h e p r o p e r a m o u n t o k n o w l e d g e , a l l o w sf o c o m p l e t e b r e a k d o w n o h o t h d i s k e t t e h a b e e n a l l o c a t e d .T i m e f o a e x p l a n a t i o n .

O a p o r t i o n o t r a c k 1 8 s e c t o r f o t h 1 5 4 1 , 2 0 3 1 , a n d 4 0 4 0d r i v e s , l i e s t h B A M . D u t t h l i m i t e d c a p a c i t y o t h e s e d r i v e s ,t h B A i s m a l l . T h 8 0 5 0 h a B A t h a t c o n s u m e s c o m p l e t eb l o c k s , t r a c k 3 s e c t o r s a n 3 w h e r e t h 8 2 5 0 h a B A o b l o c k l e n g t h , t r a c k 3 s e c t o r s 0 , 3 , 6 , a n 9 F o e a c h , t h e c o n c e p to B A i s i m i l a r .

T h 1 5 4 1 / 2 0 3 1 / 4 0 4 0 d r i v e s u s b y t e s p e r t r a c k i t h B A M . T h l a r g e r d r i v e s h a v e f i v e b y t e s . T h f i r s t b y t e o e a c h c a r r i e s t h

T h T r a n s a c t o r 4 V o l u m e 5 I s s u e 0

Page 50: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 50/88

c u r r e n t c o u n t o b l o c k s f r e e o t h a t t r a c k . T h n e x t o r 4 b y t e sc a r r y a b i m a o t h t r a c k . T a k e f o e x a m p l e t h e f o l l o w i n g 4 b y t e so d a t a :

1 5 F F F F 1 F

T h i s h a s b e e n t a k e n f r o m t h B A o f r e s h l y N E W e d 1 5 4 1d i s k e t t e . P l e a s e r e m e m b e r t h a t t h e s e f i g u r e s a r i h e x a d e c i m a l .T h 1 5 r e p r e s e n t s t h e n u m b e r o b l o c k s f r e e o t h a t t r a c k , w h i c h i o t r a c k i n t h i s c a s e . H e x a d e c i m a l 1 2 d e c i m a l , t h e r e f o r et h e r e a r e 2 1 b l o c k s f r e e o t h i s t r a c k . T h n e x t 3 b y t e s ( b y t e s i t a k e n f r o m a n 8 0 5 0 o 8 2 5 0 d i s k e t t e ) r e p r e s e n t b i m a o t h a l l o c a t i o n s t a t e o f t h e s e c t o r s o t h i s t r a c k . T f i g u r e t h i s o u t , y o h a v e t t h i n k o e v e r y t h i n g i b i n a r y .

F 1 1 1 1 1 1 1 1 F 1 1 1 1 1 1 1 1 1 0 0 0 1 1 1 1 1

N o w , s i n c e C o m m o d o r e h a a l w a y s a d a p t e d l o b y t e / h i g h b y t es t r a t e g y o e v e r y t h i n g t h e y d o t h B A i l a i d o u t t h e s a m e w a y .T h e r e f o r e ,

F F F Fs h o u l d r e a l l y b r e a d a

1 F F F F Fo i b i n a r y ,

0 0 0 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1

b i O ( 1 r e p r e s e n t s f r e e s e c t o r , b i O F ( 0 r e p r e s e n t so n t h a t h a b e e n a l l o c a t e d . I t h i s c a s e , t h e r e a r m a x i m u mo 2 1 s e c t o r s a v a i l a b l e o t r a c k o 1 5 4 1 / 2 0 3 1 / 4 0 4 0 d i s k e t t et h e r e f o r e , t h l a s t b i t s h a v e t s h o w a a l l o c a t e d . T h e y d o n ' te x i s t a n d c a n n e v e r b e w r i t t e n t o

T h r e a s o n t h l a r g e r d r i v e s h a v e f o u r b y t e b i m a i n s t e a d o t h r e e i b e c a u s e t h e y a r d o u b l e d e n s i t y , d o u b l e t r a c k i n gd r i v e s , a n a l l o w f o g r e a t e r n u m b e r o t r a c k s p e d i s k e t t e ,a n g r e a t e r n u m b e r o s e c t o r s p e t r a c k . T h m a x i m u mn u m b e r o s e c t o r s p e t r a c k f o t h e s e d r i v e s i 2 9 t h e r e f o r e i c a n n o t b e r e p r e s e n t e d w i t h o n l y t h r e e b y t e s ( 2 b i t s ) . F o u rb y t e s e q u a l 3 b i t s , w h i c h i j u s t p e r f e c t f o t h l a r g e r d r i v e s . T b e t t e r u n d e r s t a n d t h p h y s i c a l s e c t o r p e t r a c k d i s t r i b u t i o n o t h e v a r i o u s d i s k e t t e s u r f a c e s , c h e c k t h e c h a r t b e l o w :

T r a c k0 1 - 1 71 8 - 2 42 5 - 3 03 1 - 3 5

N o 1 5 4 1

2 1 1 1

o S e c t o r s2 0 3 1

2 1 1 1

4 0 4 02 1 1 1

T r a c k1 3

4 0 - 5 35 4 - 6 46 5 7 7 8 - 1 1 6

1 1 7 - 1 3 01 3 1 - 1 4 11 4 2 - 1 5 4

N o o S e c t o r s8 0 5 0

2 2 2 2 n n n n

8 2 5 02 2 2 2 2 2 2 2

W i t h t h a t e x p l a i n e d , w c a g e b a c k o n t r a c k a n e x p l a i n t h B l o c k - A l l o c a t e c o m m a n d .

A t h n a m e i m p l i e s , y o u c a n t e l l t h D O t a l l o c a t e s p e c i f i cb l o c k w h e n e v e r y o u c h o o s e . T h f o r m a t i s

. t h e n :

p r i n t # L F , " b - a : " D R ; T ; S

c l o s e L

T h i s w i l l a u t o m a t i c a l l y u p d a t e t h B A M , b u w i l l a l s o C L O S Ee v e r y o t h e r f i l e c u r r e n t l y O P E N d u t t h e c l o s i n g o t h c o m m a n d c h a n n e l .

W i t h s o m e d r i v e s , i e 1 5 4 1 , 2 0 3 1 L P , a n f e o t h e o l d e ro n e s , B l o c k - A l l o c a t e d o e s n o w o r k c o r r e c t l y . I r e a l l y i b e s t i y o r e a d t h B A i n t o R A ( d i s k o r c o m p u t e r ) , u p d a t e i m a n u a l l y , t h e n B l o c k - W r i t e i b a c k a g a i n . T h i s w i l l s a v e m a n yp r o b l e m s , a n a l s o a l l o w y o t d s w i t h o u t c l o s i n g d o w n t h 1 5 t h c h a n n e l . M o r e o B l o c k - W r i t e l a t e r .

B - F : B l o c k - F r e e

F o r e v e r y a c t i o n t h e r e i a e q u a l a n o p p o s i t e r e - a c t i o n j u s tw a i t i n g f o i t c h a n c e . B l o c k - F r e e i l i k e B l o c k - A l l o c a t e i r v e r s e . I h a s t h e s a m e f o r m a t , b u w i l l d e - a l l o c a t e a n b l o c k y o c h o o s e , p r o v i d e d t h b l o c k w a a l l o c a t e d b e f o r e . A b e f o r e , t h i sc o m m a n d h a b e e n f o u n d t b t e r m i n a l l y i l i f e o t h d r i v e s ,a m e n t i o n e d a b o v e , a n c a n n o t b e t r u s t e d . B l o c k - R e a d t h B A i n t o d i s k R A M , m o d i f y i t h e r e o r m o v e i i n t o t h c o m p u t e r sm e m o r y f o m o d i f i c a t i o n , t h e n B l o c k - W r i t e i b a c k i a g a i n .B e f o r e d o i n g s o t h o u g h , p l e a s e r e a d a l a b o u t B l o c k - R e a d a n B l o c k - W r i t e . T h e y t o o a r e t e r m i n a l l y i l l , t h e r e f o r e t h e i r e q u i v a l e n tc o u n t e r p a r t s a r b e s t u s e d . M o r e o t h a t n o w .

B - o U l : B l o c k - R e a d

Y o a l r e a d y k n o w t h a t B l o c k - R e a d a n B l o c k - W r i t e a r v e r yu n r e l i a b l e . I n s t e a d , t h U a n U c o m m a n d s s h o u l d a l w a y s b s u b s t i t u t e d .

U 1 , a l o n g w i t h t h r e s t o t h U s e r f a m i l y , a r t e r r i f i c t w o r k w i t h ,a n w i l l n o t g i v e y o p r o b l e m s . U w i l l r e a d s p e c i f i c b l o c k o y o u r c h o o s i n g f r o m t h e d i s k s u r f a c e i n t o d i s k R A M . I s e u c o r r e c t l y f i r s t , y o c a e v e n m a k e s u r e t h a t i i r e a d i n t o t h R A o y o u r c h o o s i n g .

O n c e t h d a t a h a b e e n m o v e d i n t o R A M , y o c a s e t h e B u f f e r -P o i n t e r t p o i n t a t h e s p o t i t h b u f f e r y o u w a n t t s t a r t r e a d i n gf r o m , t h e n b e g i n t h r e t r i e v e p r o c e s s . T h d e f a u l t o t h e B u f f e r -P o i n t e r i t o s t a r t y o a t h b e g i n n i n g o t h b l o c k .

t e c h n i q u e m a n y e m p l o y w h e n r e a d i n g , u p d a t i n g , a n w r i t i n gd a t a d i r e c t l y t o d i s k , i t u p d a t e d i s k R A M , i n s t e a d o b r i n g i n g i i n t o c o m p u t e r R A f o u p d a t e . I i f a s t e r , a n l e s s p r o n e t o e r r o r .I i a l s o e a s i e r t u p d a t e a s i n g l e c h a r a c t e r o d a t a t h i s w a t h a na n o t h e r .

T h e l p y o o u i n t h i s d e p a r t m e n t , h a v e p r e p a r e d a c h a r t o a l t h R A b u f f e r s w i t h i n t h d r i v e u n i t s , s y o k n o w w h i c h b u f f e rO P E N e d c o r r e s p o n d s t w h i c h a d d r e s s i R A ( t o p o f n e x t p a g e ) .

F r o m t h c h a r t , y o c a n o d e d u c e t h a t t h c o m m a n d :

o p e n C H . U A . S A , " # 0 "

. w o u l d a l l o w y o t r e a d d a t a d i r e c t l y i n t o e i t h e r $ ( ) 3 0 0 - $ 0 3 F Fw i t h t h e s i n g l e d r i v e s , o $ 1 1 0 0 - S 1 I F w i t h t h d u a l u n i t s .A s s i g n i n g a n a c t u a l n u m b e r a f t e r t h ' # i t h s t a t e m e n t a l l o w sy o t p i c k a n c h o o s e e x a c t l y w h i c h b u f f e r y o w a n t . n i c eo p t i o n . P l e a s e n o t e t h u s o C ( c h a n n e l ) i n s t e a d o L ( l o g i c a lf i l e ) i n t h i s e x a m p l e . T h e y a r e t h e s a m e , b u w i l l h e l p a v o i dc o n f u s i o n l a t e r .

T h T r a n s a c t o r 4 V o l u m e 5 I s s u e 0

Page 51: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 51/88

1 5 4 1 / 2 0 3 1 L P R A B u f f e r L a y o u t

$ 0 3 0 0 - $ 0 3 F F : B u f f e r * $ 0 4 0 0 - $ 0 4 F F : B u f f e r * 1$ 0 5 0 0 - $ 0 5 F F B u f f e r * $ 0 6 0 0 - $ 0 6 F F : B u f f e r *

4 0 4 0 / 8 0 5 0 / 8 2 5 0 R A B u f f e r L a y o u t

$ 1 1 0 0 -$ 1 2 0 0 -$ 1 3 0 0 -$ 2 0 0 0 -$ 2 1 0 0 -$ 2 2 0 0 -$ 2 3 0 0 -$ 3 0 0 0 -$ 3 1 0 0 -$ 3 2 0 0 -$ 3 3 0 0 -$ 4 0 0 0 -

$ 1 1 F F :$ 1 2 F F :$ 1 3 F F :$ 2 0 F F :$ I F F :$ 2 2 F F :

■ S 2 3 F F :$ 3 0 F F :$ 3 F $ 3 2 F F :$ 3 3 F F :$ 4 0 F F :

B u f f e r # B u f f e r * 1B u f f e r * B u f f e r * B u f f e r * B u f f e r * B u f f e r # B u f f e r * B u f f e r * B u f f e r * B u f f e r * 1 B u f f e r # 1

T h f o r m a t o B l o c k R e a d , U s e r s t y l e , i s

p r i n t # 1 5 , " u 1 : " ; C H ; D R ; T ; S

W h e n t h i s c o m m a n d i e x e c u t e d , t h e t r a c k a n s e c t o r f r o m t h d r i v e n u m b e r s p e c i f i e d w i l l b r e a d i n t o b u f f e r * 0 . F r o m h e r e , y o a r f r e e t d a y o p l e a s e .

B - o U B l o c k - W r i t e

B - i e v e n m o r e u n t r u s t w o r t h y t h a n B - i t h 1 5 4 1 , 2 0 3 1 L Pa n d 4 0 4 0 D O S , a n t h U c o m m a n d i t h e a s i e s t w a t c i r c u m v e n t p r o b l e m s . D e v e r y o n e f a v o u r a n f o r g e t t h a t B l o c k -W r i t e ( b - w ) e x i s t s , a n s t i c k w i t h t h e p r o v e n c o n t e n d e r . Y o u rp r o g r a m s w i l l b h a p p i e r .

A w i t h B l o c k - R e a d , B l o c k - W r i t e i t h f l i p s i d e o t h c o i n . S e u i e x a c t l y t h s a m e f o r m a t a i t ' s b r o t h e r U l , U w i l l w r i t e t d i s k e t t e t h c o n t e n t s o t h b u f f e r t h a t y o s p e c i f y . Y o c a p r i n t t t h a t b u f f e r , t h e n w r i t e i w i t h U 2 o y o c a m a n u a l l y w h i z a b o u tw i t h i n t h e R A w i t h t h M e m o r y c o m m a n d s l e a d i n g t h w a y .Y o u r c h o i c e . T h f o r m a t i s

p r i n t # 1 5 , " u 2 : " ; C H ; D R ; T ; S

B u f f e r - P o i n t e r :

T h i s o n e ' s n o t d i s e a s e d . B u f f e r - P o i n t e r a l l o w s y o t p o i n t e x a c t l yw h e r e y o u w a n t t s t a r t r e a d i n g f r o m , o r w r i t i n g t o w i t h i ns p e c i f i c b u f f e r o R A M . T h d e f a u l t o t h i s o n i s e b D O S , a n i a t h s t a r t o t h b u f f e r . Y o c a n c h o o s e w h e r e v e r y o u w a n tt h o u g h , f r o m l o c a t i o n 1 t h s t a r t , t l o c a t i o n 2 5 5 , t h e n d .t e r r i f i c a n i m a l t h a v e i y o k n o w w h a t w i l l b l o c a t e d i t h b u f f e r p r i o r t r e a d i n g i i n T h f o r m a t i s

p r i n t # 1 5 , " b - p : " C H ; P

B - E : B i o c k - E x e c u t e

c o m m a n d t h a t h a f o u n d l i m i t e d u s t d a t e , b u s h o u l d b c o v e r e d f o r t h i s i s s u e , a t l e a s t o c u r s o r y l e v e l .

B l o c k - E x e c u t e w i l l a l l o w y o t p i c k s p e c i f i c t r a c k a n s e c t o rf r o m d i s k , d o w n l o a d i f r o m d i s k e t t e i n t o d i s k R A M , t h e n e x e c u t ei w h e r e i s i t s . T h r e a s o n f o i t l i m i t e d a p p e a l i b e c a u s e u n t i ll a t e l y , l i t t l e h a s e v e r b e e n p u b l i c l y r e l e a s e d a b o u t t h D O s o n o tt o m a n y i n n e r - d i s k p r o g r a m s h a v e b e e n w r i t t e n . C o m m o d o r e , f o w h a t e v e r o b t u s e r e a s o n t h e y h a v e , h a n e v e r r e a l l y t o l d a n y o n ea b o u t t h i n n e r w o r k i n g s o f t h e i r d r i v e s . S u r e , e v e r y o n e c a f i n di n f o o t h d i s k e t t e l a y o u t s , a n c a a l s o f i n d l i s t o c o m m a n d s ,b u a f a a R O r o u t i n e s g o , f o r g e t i t F o a n y o n e w h i i n t e r e s t e d , w w i l l b r e l e a s i n g o u R e f e r e n c e B o o k s o o n , a n h e l dw i t h i n i t m a n y p a g e s w i l l b R A M / R O M m a p s f o m o s t o t h d r i v e u n i t s . T h 1 5 4 1 Z e r o P a g e R A M a a t h e n o t h i s a r t i c l ei j u s t s a m p l e o w h a t y o u ' l l f i n d .

T h f o r m a t f o B l o c k - E x e c u t e i s

p r i n t # L F , " b - e : " ; C H ; D R ; T ; S

T h M e m o r y C o m m a n d s

T h t r u e s p i r i t o d i s k p r o g r a m m i n g c o m e s i n t o p l a y w h e n d e a l i n gw i t h t h m e m o r y c o m m a n d s . W i t h t h e s e c o m m a n d s , y o u h a v e a y o u r a c c e s s t o t a l c o n t r o l o y o u r d r i v e . A y o u r s l i g h t e s t w h i m , y o c a d e c i d e t h f a t e o y o u r d r i v e , b i t d e s t r o y i t s e l f t r y i n g t f o l l o w y o u r w i s h e s s e n s e l e s s l y , o t e x e c u t e a w e l l r e s e a r c h e ds t r i n g o c o m m a n d s t h a t w i l l b r i n g a b o u t f a b u l o u s r e s u l t s . C a r e f u lu s o t h M e m o r y c o m m a n d s c a n u n l e a s h t h e t r u e p o w e r o t h D O S .

M - R : M e m o r y - R e a d

S i m i l a r t t h P E E K c o m m a n d i B A S I C , M e m o r y - R e a d w i l l a l l o wy o t r e a d d a t a f r o m a n y w h e r e w i t h i n t h d r i v e . Y o s p e c i f y t h a d d r e s s t r e a d f r o m , a n t h d r i v e g e t s t h i n f o f o y o u . T e r r i f i c .T h f o r m a t i s

p r i n t # 1 5 , " m - r " c h r $ ( A L ) c h r $ ( A H ) c h r $ ( N C ) ;

t h e n . . . g e t # 1 5 , a $

T h N C n u m b e r o c h a r a c t e r s , i a o p t i o n a l p a r a m e t e r , a n d o e sn o h a v e t b u s e d . I i i s y o c a s p e c i f y e x a c t l y h o m a n yc h a r a c t e r s y o w o u l d l i k e t r e a d i n s t e a d o a s e p a r a t e M - f o e a c h s i n g l e b y t e .

M e m o r y - R e a d c a n b e u s e d a s s u b s t i t u t e f o B l o c k - R e a d i y o k n o w t h a d d r e s s o t h b u f f e r t h a t c o n t a i n s t h d e s i r e d d a t a . Y o c a s p e c i f y e x a c t l y w h e r e y o u w o u l d l i k e t o r e a d d a t a f r o m a n s t a r t r e a d i n g . I t ' s l i k e m a n u a l l y e x e c u t e d B u f f e r - P o i n t e r . T h e nG E T * t h r o u g h c h a n n e l 1 w i l l r e t r i e v e t h d a t a .

O n f i n a l u s f o M e m o r y - R e a d i t d i s c o v e r w h a t m a k e s y o u rd i s k u n i t t i c k . T w r i t e a r o u t i n e t r e a d t h r o u g h d i s k m e m o r y a n r e t u r n t h r e s u l t s t t h s c r e e n t a k e s l i t t l e e f f o r t , a d e m o n s t r a t e db e l o w

1 h x 0 1 2 3 4 5 6 7 8 9 a b c d e f " : z c h r $ ( 0 ) : f l a g1 5 o p e n 1 5 , 8 , 1 52 i n p u t " s t a r t , e n d " ; s , e2 f o I = s t o e s t e p 83 a h ° / o l p / 2 5 6 a l p - a h % * 2 5 63 f l a g v a h g o s u b 5 5 p r i n t h t $ ; : v a

g o s u b 5 5 p r i n t h t S " " ; : f l a g

T h T r a n s a c t o r 4 V o l u m e 5 I s s u e 0

Page 52: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 52/88

4 p r i n t # 1 5 , " m - r " c h r $ ( a l ) c h r $ ( a h ° / o ) c h r $ ( 8 )4 f o i t 5 g e t # 1 5 , a $ v a s c ( a $ z $ ) : v v c h r $ ( v a o 6 4 5 h v a / 1 6 : v a - h % * 1 6 h t m i d $ ( h x $ , h ° / o + 1 , 1 ) m i d $ ( h x $ , l 1 , 1 )

i f l a g t h e n r e t u r n6 p r i n t h t $ " " 7 n e x t i 7 p r i n t v v " 8 n e x t8 g o t o 2

c l e a n a n n e a t m e t h o d t s c o o t a b o u t w i t h i n y o u r d r i v e a n d i s c o v e r a l t h a t l i e s i w a i t f o y o u . O c o u r s e , t h r o u t i n e a b o v ec a n b e m a d e m o r e u s e f u l . F o l a r g e r v e r s i o n o t h s a m e , c h e c kt h a r t i c l e ' D r i v e P e e k e r ' i t h i s i s s u e . I t ' s l i t t l e m o r e v e r s a t i l e f o t h u s e r .

M - W : M e m o r y - W r i t e

T h h e r o o t h m e m o r y c o m m a n d s , a n d o n e i w h i c h t h e s e r i o u sd i s k p r o g r a m m e r w i l l u s f a m o r e t h a n a n y t h i n g e l s e . T h i s s i n g l ec o m m a n d a l l o w s y o t p l a c e y o u r o w t h o u g h t s a n y w h e r e y o p l e a s e i t h d r i v e , R A p e r m i t t i n g , f o t h p u r p o s e o f u t u r ee x e c u t i o n , o r f o t h s i m p l e p u r p o s e o c h a n g i n g t h e d r i v e sc h a r a c t e r i s t i c s . I n o r d e r t m a n u a l l y b y p a s s t h n o r m a l o p e r a t i n gs y s t e m o t h d r i v e , a n t e l l t h F D t s p r i n g t l i f e , M e m o r y -W r i t e i t h c o m m a n d o c h o i c e .

A s t a t e d a b o v e , m a n y c h a r a c t e r i s t i c s o y o u r d r i v e c a b a l t e r e db f e w e l l p l a c e d w r i t e s t h u n i t a d d r e s s c a b a l t e r e d , t h J O Q U c a n b e l o a d e d , a n w i t h t h p r o p e r a m o u n t o r e s e a r c h ,m o s t o t h e d r i v e f o r m a t t i n g c h a r a c t e r i s t i c s c a n b e m o d i f i e d f o a o r i g i n a l l y d e s i g n e d d i s k e t t e . T h d e s i g n e r d i s k e t t e , n o v e l i d e a f o t h i l l u s t r i o u s p r o g r a m m e r . I t h i s t i c k l e s y o u r f a n c y , w a i t f o o u R e f e r e n c e B o o k . I w i l l b e w o r t h t h w a i t .

T h f o r m a t o M e m o r y - W r i t e i s

p r i n t # 1 5 , " m - w " c h r $ ( A L ) c h r $ ( A H ) c h r $ ( N C ) ; c h r $ ( d a t a )

M - E : M e m o r y - E x e c u t e

A f i n a l c o m p l i m e n t t M e m o r y - W r i t e , M e m o r y - E x e c u t e w i l le x e c u t e w h a t e v e r c o d e y o w a n t w i t h i n t h d r i v e . P o i n t i y o u ro w c o d e a n w a t c h i t u r n y o u r t h o u g h t s i n t o r e a l i t i e s . P o i n t a C o m m o d o r e s c o d e , a n s e i t h e y w i l l w o r k f o y o u . W h a t e v e ry o c a r e t d o i t ' s a v a i l a b l e a n w i l l i n g t o g o .

S o m e p e o p l e a r g u e t h a t t h e r e i n ' s a f e ' r o o m i n s i d e o d r i v e .T h i s i t r u e , i y o u ' r e n o i c o n t r o l o y o u r d r i v e . W h e n p l a c i n gc o d e i d i s k R A M , p i c k b u f f e r t h a t w o u l d b t h l a s t o n u s e d , i e t h e h i g h e s t b u f f e r n u m b e r . F o e v e r y o n e o u t h e r e w i t h t h s i n g l ed r i v e s , t h i s m a b t a l l o r d e r . T h e r e a r o n l y f e b u f f e r s , a n i w i l l b h a r d t m a k e s u r e y o u r c o d e d o e s n ' t g e s t e p p e d o n R e m e m b e r t a l l o w a f e f i l e s o p e n a t h s a m e t i m e a p o s s i b l e ,a n y o u r c o d e m a b s a f e . O t h e r w i s e , t h e r e a r e a f e s p o t s h e l dd e e p w i t h i n R A t h a t c o u l d b e u s e d a s t e m p o r a r y h i d i n g p l a c e ,p r o v i d i n g y o u r c o d e i s m a l l .

T h e s e l o c a t i o n s a r a l a v a i l a b l e f o u s e , a l o n g a y o u ' r e n o t u s i n gR E L a t i v e f i l e s w i t h y o u r p a r t i c u l a r a p p l i c a t i o n . T h e r e a r e q u i t e af e s i n g l e b y t e a r e a s , a n a g a i n , q u i t e f e b l o c k s o R A t u c k e d

a w a y , b u u n l e s s t h e e x a c t s i t u a t i o n i k n o w n t h a t i w i l l b e u s e dw i t h , i m i g h t b b e s t t l e a v e t h e m a l o n e .

S i n g l e0 0 B 5 - 0 0 B A0 0 B B - 0 0 C 00 0 C 1 - 0 0 C 60 0 C 7 - 0 0 C C0 0 C D - 0 0 D 20 1 0 4 - 0 I F F

D u a l L a b e l0 0 5 9 - 0 0 6 0 R E C L0 0 6 1 - 0 0 6 8 R E C H0 0 6 9 - 0 0 7 0 N 0 0 7 1 - 0 0 7 8 R S0 0 7 9 - 0 0 8 0 S 0 1 0 0 - 0 I F F

D e s c r i p t i o nL o R e c # T F i n d R e F i l eH i g h R e c # T o F i n d R e F i l eN e x t R e l a t i v e R e c o r d T a b l eR e l a t i v e R e c o r d S i z e T a b l eS i d e S e c t o r T a b l eT h S t a c k ( u s e c a u t i o u s l y )

T g e b a c k o t r a c k , t h f o r m a t o M e m o r y - E x e c u t e i s

p r i n t # 1 5 , " m - e " c h r $ ( A L ) c h r $ ( A H )

T h U s e r C o m m a n d s

T h U s e r s e r i e s o c o m m a n d s f a l l i n t o t h r e e c a t e g o r i e s . T h f i r s t ,U l a n d U 2 c o m e u n d e r t h h e a d i n g o f d i s k e t t e a c c e s s . T h s e c o n dc a t e g o r y , d r i v e h o u s e k e e p i n g , e n c o m p a s s e s t h U 0 , U 9 , a n U c o m m a n d s . T h e y t a k e c a r e o f i n t e r n a l d r i v e s t u f f t h a t k e e p t h d r i v e c o n t e n t . T h t h i r d a n f i n a l c a t e g o r y i d r i v e a c c e s s c o m a n d s , U 2 - U 8 , w h i c h g h a n d i h a n d w i t h t h M e m o r y c o m a n d s d i s c u s s e d e a r l i e r . T a k e l o o k b e l o w f o t a b l e o a l t h U s e r c o m m a n d s .

F u n c t i o n

R e s e t o U S J u m p V e c t o r I D i s k R A B l o c k - R e a d R e p l a c e m e n tB l o c k - W r i t e R e p l a c e m e n tJ u m p T $ 1 3 0 0 ( d u a l ) o r $ 0 5 0 0 ( s i n g l e )J u m p T $ 1 3 0 3 ( d u a l ) o r $ 0 5 0 3 ( s i n g l e )J u m p T $ 1 3 0 6 ( d u a l ) o r $ 0 5 O 6 ( s i n g l e )J u m p T $ 1 3 0 9 ( d u a l ) o r $ 0 5 0 9 ( s i n g l e )J u m p T $ 1 3 0 C ( d u a l ) o r $ 0 5 0 C ( s i n g l e )J u m p T $ 1 3 0 F ( d u a l ) o $ 0 5 0 F ( s i n g l e )J u m p T N M I : $ 1 0 F 0 ( d u a l ) o $ F F 0 1 ( s i n g l e )P o w e r U V e c t o r ( s y s t e m r e s e t )

T h e r e a r b u g s i m o s t o t h e s e c o m m a n d s i t h 1 5 4 1 / 2 0 3 1 L Pd r i v e s . T h a l t e r n a t e s y n t a x o e a c h U s e r c o m m a n d c a g i v eu n e x p e c t e d r e s u l t s - a v o i d t h e m l i k e t h e p l a g u e . U s U 0 - U : f o y o u r w o r k , a n d y o u s h o u l d r u i n t o f e d i f f i c u l t i e s . A n n o w ,q u i c k e x p l a n a t i o n f o e a c h c o m m a n d .

U i c o m m a n d t h a t h a b e e n p o o r l y d o c u m e n t e d b C o m m od o r e i p a s t . T h e y h a v e p r e p a r e d c h a r t s o t h U s e r c o m m a n d s ,a l w a y s f o r g e t t i n g t i n c l u d e d t h i s o n e o n i t O n s i n g l e s e n t e n c ew a d o n a t e d o n c e i a o l d d i s k m a n u a l . I

p r i n t # L F , " u O

. . i e x e c u t e d , t h U S E R J U M P v e c t o r i d i s k z e r o p a g e w i l l b r e s e t t o n o r m a l . N o t e r r i b l y u s e f u l f e a t u r e , b u o n t h a t w i l l c o m ei h a n d y i y o u c h a n g e t h v e c t o r f o s o m e t h i n g a n n e e d q u i c kw a t r e t u r n i b a c k t n o r m a l .

U a n U 2 a m e n t i o n e d p r e v i o u s l y , a r e r e p l a c e m e n t s f o B l o c k -R e a d a n B l o c k - W r i t e .

U t h r o u g h U a r c o m m a n d s i m p l e m e n t e d t a l l o w f o s t r u ct u r e d m e t h o d o d i s k a c c e s s a d a p t a b l e f o a l m a c h i n e s . T u s

S t a n d a r dS y n t a x

U U U U U U U U U U U

A l t e r n a t eS y n t a x

U U u U U U U U U U

T h T r a n s a c t o r 5 V o l u m e 5 I s s u e 0

Page 53: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 53/88

t h e s e c o m m a n d s , y o u h a v e t o s e t u t h R A j u m p v e c t o r s f i r s t .E a c h v e c t o r i t h r e e b y t e s a p a r t , t h e r e f o r e , y o a r e x p e c t e d t w r i t e i J M ( $ 4 C ) , t h e n t h e l o / h i a d d r e s s o t h c o d e y o i n t e n dt e x e c u t e . T h e r e a f t e r , y o w i l l b a b l e t a c c e s s y o u r r o u t i n e b s i n g l e e x e c u t i o n o t h U s e r c o m m a n d . f a i r l y h a n d y s y s t e m t h a th a s s e e n l i t t l e u s i t h p a s t . T h f o r m a t f o e x e c u t i o n i s

p r i n t # L F , " u X

. w h e r e i t h n u m b e r o y o u r c h o o s i n g .

U i o d d , b u t p o s s i b l y u s e f u l . I j u m p s t t h N M v e c t o r , w h i c h i t u r n i l i k e s y s t e m r e s e t , w i t h o u t t h e f l a s h i n g L E D s ( p o w e r o d i a g n o s t i c s ) . T h f o r m a t i t h s a m e a b e f o r e , 9

U ( U c o l o n ) i " p o w e r - o n " s y s t e m r e s e t h a n d y f o r e s e t i n g t h d r i v e w i t h o u t p h y s i c a l l y p o w e r i n g d o w n . I y o u w a n t t m a k es p e c i a l i n t e r n a l c o d e d i s a p p e a r , U i t h a n s w e r . I y o u h a v em e s s e d u b a d l y i n s i d e o t h u n i t , U : a g a i n . S o m e t i m e s , a h a v ef o u n d f e t i m e s i t h p a s t , y o c a m e s s u p R A s b a i n s i d e

o y o u r d r i v e t h a t e v e n s y s t e m r e s e t w o n ' t w o r k . T h e n t h s w i t c ha t h b a c k i t h o n l y a l t e r n a t i v e . H o p e f u l l y , U : w i l l b s u f f i c i e n tf o y o u r n e e d s .

T h a t ' s A l

A n s e n d s t h i s r a t h e r l o n g b u t p o s s i b l y i n f o r m a t i v e a r t i c l e o t h i n n e r w o r l d o D O S . W i t h l i t t l e b e l l i g e r e n c e a n p r a c t i c e y o c a p e r f o r m t r i c k s i n s i d e D O t h a t w i l l n e v e r b e i m p l e m e n t e d a s B A S I C c o m m a n d . I i f o r t h i s r e a s o n t h a t s u g g e s t y o d o n ' ti n c l u d e t h e s e t r i c k s i " t r a n s p o r t a b l e " s o f t w a r e . F u t u r e C o m m od o r e D i s k O p e r a t i n g S y s t e m s m a n o t r e c o g n i z e o l d t r i c k s , h o e v e r t r i e d a n t r u e .

T h e r e i s s t i l l q u i t e b i t b l e a r n e d a b o u t D O S , f o i i v e r yc o m p l e x s y s t e m . W a T h T r a n s a c t o r a r l e a r n i n g n e f a c t sa l m o s t d a i l y , e v e n t h o u g h t h 4 0 4 0 h a b e e n w i t h u n o f o w e l lo v e r y e a r s . A w l e a r n m o r e , y o w i l l t o o . S o u n t i l w m e e ta g a i n . .

1 5 4 1 R A M e m o r y M a p w i t h Z e r o P a g e C o n t e n t s a P o w e r U r e f e r e n c e s t D r i v e a r m o s t l y u n u s e d l o c a t i o n sH e x L o c M t o n

0 0 - 0 5 0 00 0 0 0 0

0 6 - 1 1 0 0 0 O

0 0 O O O F O 1 I

1 2 - 1 5 1 21 1 1

I 6 - 1 A 1 1 1 1

I I B I B1 C - 1 D 1

1 E - I F I I

2 2 2 1 2 12 2 - 2 3 2 2

2 2 4 - J D 2

2 2 f 2 2 2

2 2 2 2

2 E - 2 F 2 E

3 0 - 3 1 3 3

3 2 - 3 3 3 23

; t

■ '

■ i

■ i

3 3 3 3 3 3 ! 3 3 3 3 3 F 3 4 4 4

4 4

4 6 4 64 7 4 74 8 4 84 9 4 94 A 4 A4 4 4 4 4 D 4 D4 < 4 F 4 FS O 5 05 5

5 5

C o n . e n

0 0 0 0 o 0 0 0 o 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0

1 0 0 0 0 0 0 0 0 0 I X o 0 0 0 0 0

I 0 0 0 0 0 0 0 o 0 0 o 0 0 F 0 0 0 0 o 0 0 0 0 0 3 0 0 0 0 0 0 0 F

0 0

C B L - . N -

w a

H D R S

D S K I D

H E A D E R

A C T J O Bw p s w

L W P T

D R V S T

D R V T R K

S T A B

S A V P N T

B I J r T N T

H D R P N T

G C R P N TG C R E R RB Y T C N TB I T C N TR I H B I DC H K S U MH I N I BB Y T ED R I V EC D R I V EJ O B NT R A C CN X T J O BN X T R K

S F . r T RW O R KJ O C T R A C KD B I DA C L T T MS A V S PS T E P ST M C S E C TN E X T 5N X T B FN X T P N TG C R F l . GF T N U M

F u n c t i o nJ o h Q u e B u l l e t *

B u f f e r • B u f f e r » B u l l e r ' B u f f e r ' B u H e r *

J o H e a d e r s : C h i l l e rB u i r r rB u f f e rB u f f e rB u f f e rB u f f e rB u l l e rB u f f e rB u f f e rB u f f e rS u f f e rB u l l e r

M d x l e r C o p y O t D i s

• 0 - L o w•

• • * " *

• •

H i g hU H i g h

H i g hL o H i g hL o H i g h

H : s hI D D r i v e 0

D r i v eN o U w D r i v eN o U s e d D r i v eI m a g e O l a s t H e a d e r : I D B v l e

I B y l e 2T r a c kS e c t o rC h e c k s u m

C o n t r o l l e r s A c l i v e J o W r i t e P r o t e c t C h a n g e F l a g . D r i v e

L a s t S t a t e O W S w i t c h ; D r i v eD r i v e l

D r i v e s C u r r e n t S t a t u s ; D r i v eS p e e d T i m i n g F l a gD r i v e T r a c k N u m b e r : D r i v e

D r i v e lS t o r a g e T a W e F o G C C o n v e r s i o n

T e m p o r a r y S a v e P o i n l e r L o c a t i o n

A c l i v e B u f l e r P o i n l e r

H e a d e r P o i n t e r ; T r a c kS e e l o r

G C P o i n t e rI n d i c a t e s G C D e c o d e E r r o rB y t e C o u n t e r F o G C R / B i n a r y C o n v

D a t a B l o c k I DH e a d e r B l o c k I C h e c k s u m

n o u s e d d i r e c t l yn o u s i - d d i r e i i l v

D r i v e N u m b e rC u r r e n l A c l i v e D r i v e N u m b e rC u r r e n l J o N u m b e rT r a c k - I n t e r n a l S t o r a g e L o c a t i o nN e x t J o bN e x t T r a c kS e c t o r P e T r i c k F u F o r m a t t i n gW o r k i n g S t o r a g e L o c a t i o nJ o T y p e

n o u s e d d i r e c t l yD a t a B l o c k I A c c e l T i m e D e l a yS a v e S t a c k P o i n t e rS l e p s T D e s i r e d T r a c kT e m p o r a r y S t o r a g e L o c u t i o nC u r r e n l S e c t o rN e x t S e c l o rP o i n t e r T N e x l G C S n u t c e B u l l e rP t T N e x t B y l e L m a i l o n I B u f f e rG C R / B i n a r y R a I A c l i v e B u f f e tC u r r e m F o r m a t T r a c k

5 5 6 - 5 D 5

5 5 5

5 S 5 5

5 E 5 ES F 5 F6 f i 6 1 6 )6 2 - 6 3 f i l

6 6 4 C I6 5 - 6 6 f i S

6 6 7 6 76 8 6 86 9 6 96 A 6 A6 B - - 6 C 6

6 f i l ^ - f i E 6

6 6 F - 7 4 6

7 7 7 7 7

7 5 - 7 6 7 7

7 7 7 77 8 7 87 9 7 97 A 7 A7 7 7 7 7 7 7 7 7 F 7 FB 0 B 08 1 8 18 2 8 28 8 8 8 8 8 8 6 8 68 8 8 8 S 38 9 « 98 8 8 B - 8 E S B

B 8 8

8 F - 9 3 H 9 9 9 9

9 4 - 9 5 9 9

9 6 9 69 7 9 79 9 9 9 - A 6 9

9 f f 9 9 9 9 A A A A A A A

A 7 - A D A

A A A

0 0 0 0 0 0 0 0 0 0 0 o 0 0 F C 2 E 0 0 0 O E F 0 0 6 0 0 F 0 0 0 0 1 t 0 0 0 0 o 0 0 0 0 0 O 6 3 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 D 0 F

F F 0

G T A B

A A A C L S T PR S T E P SN X T S T

M I N S T PV N M i

N M I F L GA U T O F GS E C I N CR E V C N TU S R J M P

B M P N T

T E M P : T OT T T T

I

L S N A D RT L K A D RL 5 N A C TT L K A C TA D R S E DA T N P N DA T N M O DP R C T R KD R V N U MT R A C KS E C T O RI J N D XS O K G S AD A T An R R R R R E S U L T

A C C U M

D I R B U F

I C M DM V P AC N B U F T A B

B U F O

G C T a b l e : G C r V B i n a r y W o r k A r e a

N u m b e r O S t e p s T A c c e l W i i h H e a dA c c e l e r a t i o n F a c t o rS t e p j T G B e f o r e C o m r > k t -N u m b e r O R u S t e p sP o i n t e r T S t e p p i n g R l n 1 F A 0 5

M i n i m u m S t e p s R e q u i r e d T A c c e lI n d i r e c t F o N M 1 - J E B 2 2

N M I l n P r o g r e s i F l a gA u t o D r i v e I n i t i a l i z a t i o n R a S e c l o r I n c r e m e n t F o i S e q u e n t i a lE r r o r R e c o v e r y C o u n tU s e r J u m p T a b l e P o i n t e r I F F E A

B i M a P o i n l e r

T e m p o r a r y W o r k S p a c e

I n d i r e c t P o i n t e r V a r i a b l e

L i s t e n A d d r e s s . D e v i c e * 1 2 0T a l k e r A d d r e s s : D e v i c e ■ 1 4 A c t i v e L i s t e n e r H a A c t i v e T a l k e r F l a gA d d r e s s e d F l a gA t t e n t i o n P e n d i n g F l a gI A T M o d eL u i P r o g r a m A c c e s s e dC u r r e n l D r i v e N u m b e rC u r r e n l T r a c kC u r r e n t S e c t o rL o g i c a l I n d e xC u r r e n t S e c o n d a r y A n d r e wO r i g i n a l S e c o n d a r y A d d r e wT e m p o r a r y D a t a B y t eT e m p W o r k A r e aT e m p W o r k A r e aT e m p W o r k A r e aT e m p W o r k A r e aT e m p W o r k A r e aR e s u l t O M u l t i p l y / D i v i d e R i n s

R e m a i n d e r O I M u l t i p l y / D i v i d e R l n s

P o i n l e r T D i r e c t o r y B u f f e r

I E E E C o m m a n d I n N o U s e dM P F l a g . N o t U s e dS e r i a l B i C o u n t e rB u f f e r B y t e P i r s . B u f f e r ' l a

B u f f e r ' H i g hB u f f e r ' ! L o B u f f e r * H i g hB u f f e r ' 2 L o B u f f e r ' H i g hB u f f e r # L o B u f f e r * H i g hB u f f e r ' l a B u f f e r ' H i g h

: C M D B u f f e r L o H i g h

E r r o r B u f l L o H i g h

I n a c t i v e F l a p F o r B u f f e r s

A C A

A E - B 4 A A B B B B 0

B 5 B 5B 5 - B A B

B B R B

S B O BB B - C 0 B B

B R B B C l

C 1 - C 6 C C c C C C

C 7 - C CC C C C C

C D - D 2 C C C D D D

D D D D S D SD D f D 7 D 7D 8 - D C D

D U D

D D - E I D D D E E

E 2 - F . 6 E E E F . B f

E 7 - F . B E 7E f E F F .

F . C - F 1 E E E E F t F

F 2 - F 7 F F F F F F

F F F K F A - F E F

F F F F

F F - 1 0 0 F F1 0

0 F F F F F F F F 0 < > 0 n 0 0 0 0 0 0 o o m 0 0 D 0 0 0 0 0 0 0 0 0 0 F F F F F F 0 n ( H 0 0 0 0 0 0 o 0 0 n 0 0 0 0 0 o o D o 0 0 o 0 0 o 0 0 ( n 0 0 n n n R 8 0 0 0 0 0 0 0 B

B U F 1

N B K LR B C L

N B K HR E C H

N

R

s

F 1 P T RR F . C P T RS 5 N L I MS S I N DR E L P T RE N T S E C

F . N T l N n

F I L D R V

P A T T Y P

F I L T Y P

C H N R D Y

R O I F U )J O B N U M1 . R U T B I

N O D R V

A c t i v e F l a g s F o B u f f e r s

N t t m b r r O f B l o c k s L o L o R e c o r d T F i n d R e l a t i v e F i l f

N u m b e r O B l o c k s H i g hH i g h R e c o r d T F i n d R e l a t i v e H i

N e x t R e c o r d T a b l e

R e l a t i v e R e c o r d S i r e T a b l e

S i d e S e c t o f T a b l e

F i l e S l e a m l P o i n t e rl * B y t e W a n t e d F r o m R e l a t i v e R e c o r d

S i d e S e c l o r N u m b e t O R e l a t i v e F i l eI n d e x I n t o S i d e S e c t o rP l r T o 1 s B y t e W a n i r d I R e F i l eS e c t o r O D i r e c t o r y E n t r i e s

I n d e x O f D i r e c t o r y E n t r i e s

D e f a u l t F l a g , D r i v e N u m b e r

P a t i e r n . R e p l a c e . O o v d - F l o g i . T y p e

C h a n n e l F i l e T y p e

C h a n n e l S t a t u s

T e m p o r a r y E O 1C u r r e n t J o b N u m b e rL e a s t R e c e n t l y U s e d B u f f e r T a b l e

N D r i v e F l a g : D r i v eD r i v e N a I

T h T r a n s a c t o r 5 V o l u m e 5 I s s u e 0

Page 54: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 54/88

I n s i d e t h C o m m o d o r e 6 C h r i s Z a m a r a , T e c h n i c a l E d i t o r

W h a t m a k e s i t i c k ?

M o s t o w h a t y o u l e a r n a b o u t y o u r c o m p u t e r i n v o l v e s s o f t w a r et e c h n i q u e s o s o m e k i n d . T h i s a r t i c l e i f o h a r d w a r e f a n s , e x p e r im e n t e r s , o r t h e m e r e l y c u r i o u s ; s i n c e t h i s i t h " H a r d w a r e a n dP e r i p h e r a l s " i s s u e , i t ' s o n l y f a i r t h a t w g i v e y o s o m e i n s i g h t i n t ol i f e i n s i d e t h e p l a s t i c c a s e .

T h d i a g r a m o y o u r r i g h t i l a y o u t o t h C 6 4 ' s c i r c u i t b o a r d ;t h i s i w h a t y o u ' d s e i y o o p e n e d u t h t o o t h c a s e . T h e r ea r s l i g h t d i f f e r e n c e s a m o n g m a c h i n e s , s i n c e C o m m o d o r e o c c as i o n a l l y c h a n g e s t h b o a r d d e s i g n t m a k e p r o d u c t i o n m o r ee f f i c i e n t , b u o v e r a l l t h e y s h o u l d a l b p r e t t y s i m i l a r t t h i sd i a g r a m .

E a c h m a j o r s e c t i o n o t h b o a r d ( a n d f e w n o t - s o - m a j o r s e c t i o n s )a r l a b e l l e d i t h d i a g r a m , a n d e s c r i b e d b e l o w . B e s i d e s d e s c r i pt i o n s o f t h p a r t s , t h e r e a r e a l s o u s a g e t i p s a n b i o l i t t l e - k n o w nt r i v i a t h r o w n i h e r e a n t h e r e . T h i s i b y n o m e a n s a e x h a u s t i v ed e s c r i p t i o n o t h 6 4 ' s c i r c u i t r y t h a t c o u l d t a k e u t h e n t i r em a g a z i n e . B u w h e n y o r e a d t h s p e c s f o s o m e e x o t i c n e s p o r t sc a r , d y o r e a l l y c a r e w h a t t h s p a r k p l u g g a s e t t i n g i s

T h s e c t i o n s a r d i v i d e d i n t o f o u r m a i n c a t e g o r i e s : C P a n M e m o r y , I / O , V i d e o , a n P o w e r . L e t h e t o u r b e g i n .

C P U , M e m o r y , a n C o n t r o l1 T h e 6 5 1 0 C P

T h 6 5 1 0 C P ( C e n t r a l P r o c e s s i n g U n i t , a . k . a M i c r o p r o c e s s o r ) h a st g e t h a w a r d f o t h s i n g l e m o s t i m p o r t a n t c h i p o t h e b o a r d ,s i n c e i i r e s p o n s i b l e f o e x e c u t i n g a l p r o g r a m i n s t r u c t i o n s . T h o t h e r c h i p s a r e j u s t s l a v e s t t h m a s t e r C P U , w h i c h c o n t r o l s t h e ma t h w i l l o t h s o f t w a r e , e i t h e r f r o m t h R O ( o p e r a t i n g s y s t e m )o R A ( u s e r ) . T h b a s i c c a p a b i l i t i e s o t h C P a r m e m o r y l o a da n s t o r e c o m m a n d s , a r i t h m e t i c a n b i t - m a n i p u l a t i o n f u n c t i o n s ,a n t w k i n d s o f i n t e r r u p t s . A d d i t i o n a l l y , t h e c h i p h a s a I / p o r tb u i l t i n ( a c c e s s e d w i t h l o c a t i o n s a n 1 w h i c h c o n t r o l s m e m o r yb a n k s e l e c t i o n a n t h c a s s e t t e u n i t .

2 T h P A C h i p

T h P A o P L ( P r o g r a m m a b l e L o g i c A r r a y ) i o n o t h e g r e a tm y s t e r i e s o t h 6 4 s i n c e i i c u s t o m d e v i c e u n i q u e t t h i sc o m p u t e r m u c h l i k e R O M . T h P A c h i p r e p l a c e s m a n yd i s c r e t e g a t e s , m u l t i p l e x e r s , e t c . a n i u s e d t s u p p l y t h l o g i cr e q u i r e d t m a n a g e t h 6 4 ' s c o m p l e x m e m o r y a r c h i t e c t u r e . C o s i d e r t h f a c t t h a t e i t h e r R A M , R O M , o I / m a e x i s t i t h s a m ea d d r e s s s p a c e d e p e n d i n g o t h w h i m s o t h e V I C — I I v i d e o c h i p ,t h m e m o r y r e f r e s h i n g c i r c u i t r y , t h e c a r t r i d g e o t h e x p a n s i o np o r t , a n t h p r o g r a m m e r h i m s e l f . A l t h r e q u i r e d l o g i c t o h a n d l ee v e r y p o s s i b l e c o m b i n a t i o n o e v e n t s l i v e s i t h P A c h i p , w h i c hw o r k s l i k e R O i n t h a t i c a n b e c u s t o m - p r o g r a m m e d f o g i v e na p p l i c a t i o n . P A L s , t h o u g h , a r f a s t e r t h a n R O M s , a n c a b u s e d

f o h a r d w a r e a p p l i c a t i o n s s u c h a s t h e s e ( t h e y ' r e s m a l l e r , t o o ) .I n c i d e n t a l l y , P A L s a r a l s o m o r e d i f f i c u l t t d u p l i c a t e o r c o p y t h a nR O M s , a n t h P A i t h 6 i o n f a c t o r w h i c h m a k e s i d i f f i c u l tt c r e a t e 6 4 " c l o n e s " - p r o b l e m w h i c h p l a g u e d t h A p p l e I I

3 8 B A S I C R O

T h i s i t h R O w h i c h o c c u p i e s a d r e s s e s $ A 0 0 0 t $ B F F F ( h e x ) . I c o n t a i n s m o s t o t h B A S I C i n t e r p r e t e r ; s p e c i f i c a l l y , t h o s e p a r t sw h i c h a r c o m m o n t a l m a c h i n e s . N m a c h i n e - s p e c i f i c c o d e i i n t h i s R O M , s t h a t i c a ( t h e o r e t i c a l l y ) b u s e d u n c h a n g e d i f u t u r e C o m m o d o r e m a c h i n e s , o c a s u r v i v e h a r d w a r e a d d i t i o n s ,s u c h a I E E E o 8 0 - c o l u m n c a r d s .

4 8 K e r n a l R O T h K e r n a l R O r e s i d e s i l o c a t i o n s $ E 0 0 0 t $ F F F F , a n c o n t a i n s - y o g u e s s e d i a l t h m a c h i n e - s p e c i f i c c o d e . A n r o u t i n e s w h i c h d e a l d i r e c t l y w i t h t h e v i d e o , s o u n d , o I / c h i p sa r f o u n d i t h i s R O M . L O A D , S A V E , a n d V E R I F Y f u n c t i o n s f r o mB A S I C a r a l s o h e r e . A l s o , p r o b a b l y d u t l a c k o s p a c e i t h B A S I C R O M , t h e S Y S , C O S , S I N , a n T A r o u t i n e s a r e h e r e . M u c ho t h s p a c e i t a k e n u b s c r e e n , k e y b o a r d , R S - 2 3 2 , a n s e r i a lp o r t h a n d l i n g r o u t i n e s .

5 4 C h a r a c t e r G e n e r a t o r R O T h i s R O i u s e d b t h V I C — I I v i d e o c h i p t s u p p l y t h m a t r i xd a t a r e q u i r e d t f o r m a l 5 1 c h a r a c t e r s : u p p e r a n l o w e r c a s el e t t e r s , g r a p h i c s s y m b o l s , a n a l o t h a b o v e i r e v e r s e - f i e l d . T h i n f o r m a t i o n d e s c r i b i n g t h s h a p e o e a c h d i s p l a y a b l e c h a r a c t e ro c c u p i e s 8 b y t e s i t h c h a r a c t e r g e n e r a t o r R O M . T h a d d r e s ss p a c e o c c u p i e d b t h R O i t h s a m e a s t h a t o f t h e I / O : S D O O O t $ D F F F . T h c h i p c a b r e a d b u s e r p r o g r a m , b c l e a r i n g b i i l o c a t i o n t " s w i t c h o u t " t h e I / O . W h e n d o i n g t h i s , c a r e m u s tb t a k e n t s t o p a c c e s s i n g t h u s u a l I / l o c a t i o n s ; t h n o r m a l I R h a n d l e r m u s t b d i s a b l e d .

6 6 4 D y n a m i c R A C h i p s

T h i s i t h 6 4 o R A f r o m w h i c h t h 6 g e t s i t ' s n a m e . E a c h c h i ps t o r e s 6 4 b i t s , s e i g h t c h i p s a r r e q u i r e d t p r o v i d e c o m p l e t eb y t e s o f d a t a . A i n t e r e s t i n g u s a g e c h a r a c t e r i s t i c o f t h e s e R A c h i p s i t h w a t h a t 6 4 o m e m o r y i a d d r e s s e d . R a t h e r t h a np r o v i d i n g 1 6 p i n s o e a c h c h i p a n c o n n e c t i n g a l 1 a d d r e s s l i n e sd i r e c t l y ( a l l 1 l i n e s a r r e q u i r e d t a c c e s s 6 4 K ) , t h e r e a r e j u s ta d d r e s s l i n e s , a n t w s e l e c t l i n e s . T h l o a n h i g h 8 a d d r e s s b i t sa r p l a c e d o t h c h i p ' s a d d r e s s l i n e s a l t e r n a t e l y , a n t h s e l e c tl i n e s a r u s e d t t e l l t h c h i p w h i c h a r w h i c h .

T h R A i d y n a m i c , m e a n i n g t h a t i o n l y s t o r e s i t ' s i n f o r m a t i o nt e m p o r a r i l y a n d m u s t b c o n t i n u a l l y " r e f r e s h e d " s t h a t i d o e s n ' tf o r g e t . T h r e f r e s h i n g i d o n e a u t o m a t i c a l l y b t h e V I C — I I v i d e oc h i p , a b o u t e v e r y m i l l i s e c o n d s .

T h T r a n s a c t o r 5 V o l u m e 5 I s s u e 0

Page 55: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 55/88

P u l l - u p R e s i s t o r s ( C I A ) U 2

S e r i a l P o r t B u f f e r ( i ? )

& N M I G e n e r a t o r h e

6 4 K R A M ( (

R A M u l t i p l e x e r

P r o g r a m m a b l e / T L o g i c A r r a y

A n a l o g I n p u tM u l t i p l e x e r

6 5 8 1 S I D C h i p (

6 5 6 7 V I C - I I V i d e o C h i p V 2 C J .

V i d e o S e c t i o n ( 2

V o l t a g e R e g u l a t o r ( 2 8 }C o l o u r I n t e n s i t y

A d j u s t m e n t

C l o c k F r e q u e n c yA d j u s t m e n t

V o l t a g e S t e p - u pC i r c u i t r y

V o l t a g e R e g u l a t o r ( 2 9 J

L E C o n n e c t o r ( 3 0 )

C o m m o d o r e 6 C i r c u i t B o a r d L a y o u t

1 5 K e y b o a r d C o n n e c t o r

6 5 2 6 C I AS e r i a l P o r tP u l l - u p R e s i s t o r s6 5 2 6 C I A

3 ) B A S I C R O

K e r n a l R O

C h a r a c t e rG e n e r a t o r R O

C o l o u r M e m o r y

6 5 1 0 C P

( 2 4 ) R M o d u l a t o r

( 1 7 ) C a s s e t t e M o t o r C o n t r o l

E x p a n s i o n P o r tC o n n e c t o r

F u s e

J o y s t i c k / P a d d l eC o n n e c t o r s

( 2 5 ) P o w e r C o n n e c t o r

T h T r a n s a c t o r 5 V o l u m e 5 I s s u e 0

Page 56: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 56/88

7 I C o l o u r M e m o r y N y b b l e s

C o l o u r m e m o r y i s t o r e d i t h i s I b b i c h i p , w h i c h r e s i d e sf r o m $ D 8 0 0 t $ D B F F . T h a t g i v e s 1 0 2 4 b y t e s w h o s e l o w e s t f o u rb i t s ( n y b b l e ) c a n b e m o d i f i e d . S i n c e t h V I c h i p s u p p o r t s 1 c o l o u r s , o n l y f o u r b i t s a r r e q u i r e d t r e p r e s e n t a l p o s s i b l ec o l o u r s . E a c h o t h 1 0 0 0 c h a r a c t e r s o t h s c r e e n ( 2 r o w s b y 4 c o l u m n s ) i r e p r e s e n t e d b n y b b l e i t h c o l o u r m e m o r y c h i p .T h 2 4 n y b b l e s l e f t o v e r a r w a s t e d d o n ' t f o r g e t a b o u t t h e m i y o u w a n t t h i d e p a s s w o r d o s o m e t h i n g s o m e w h e r e i m e m o r y( s o r r y i b l e w a n y o n e ' s s e c u r i t y s c h e m e ) .

8 M u l t i p l e x e r s f o R A T h m u l t i p l e x e r s a r e r e q u i r e d b e c a u s e o t h w a t h 6 4 R A c h i p s a r a d d r e s s e d : s e i t e m a b o v e . T h e s e c h i p s t r a n s l a t e 1 d a t a l i n e s i n t o 8 d a t a l i n e s a n t w s e l e c t l i n e s .

I / 9 T h 6 5 8 1 S I S o u n d I n t e r f a c e D e v i c e

O n o t h b i g , i m p o r t a n t c h i p s i t h s y s t e m , t h S I i t h h i g h l y - a c c l a i m e d " s y n t h e s i z e r c h i p " . w o n ' t g e t i n t o a l o t h i sc h i p ' s d e t a i l s ; t h a t ' s t h t o p i c o f q u i t e a f e a r t i c l e s . b r i e fs u m m a r y o i t s o u n d g e n e r a t i o n c a p a b i l i t i e s : t h r e e v o i c e s , p r g r a m m a b l e w a v e f o r m , f r e q u e n c y , a t t a c k / d e c a y / s u s t a i n / r e l e a s e ,p u l s e - w i d t h , h i g h - p a s s b a n d - p a s s a n l o w - p a s s f i l t e r s , a n m a t e v o l u m e ( q u i t e a m o u t h f u l ! ) .

B u t h S I D d o e s m o r e t h a n j u s t s o u n d g e n e r a t i o n . I a l s o c o n t a i n st w a n a l o g t o d i g i t a l c o n v e r t e r s , w h i c h a r u s e d f o t h g a m ep a d d l e s . T h e r e i r e g i s t e r w h i c h i n d i c a t e s t h e c u r r e n t o u t p u t o v o i c e 3 a n c a b u s e d t g e n e r a t e r a n d o m n u m b e r s . A n t h e r ei a e x t e r n a l a u d i o i n p u t , w h i c h i m i x e d w i t h t h o u t p u t o t h c h i p a n c a n b e c o n t r o l l e d w i t h t h b u i l t i f i l t e r s . T h S I D ' sr e g i s t e r s a r a c c e s s e d f r o m l o c a t i o n s $ D 4 0 0 t $ D 4 1 C .

1 0 6 5 2 6 C I A 1 C o m p l e x I n t e r f a c e A d a p t e r

T h 6 5 2 6 C I ( n r e l a t i o n t t h a g e n c y o t h s a m e n a m e ) i a 1 c h i p c o n t a i n i n g l o t s o f g o o d i e s . I t ' s g o 1 I / l i n e s , t w l i n k a b l e

t i m e r s , 2 4 - h o u r t i m e o d a c l o c k w i t h p r o g r a m m a b l e a l a r m , a n a b i s h i f t r e g i s t e r f o r s e r i a l I / O . N o w , u n f o r t u n a t e l y , n o a l o t h e s e g o o d i e s a r e f f e c t i v e l y u s e d b t h K e r n a l . F o e x a m p l e , t h " I r e s e r v e d v a r i a b l e i k e p t i t i m e ( n o t v e r y w e l l ) b s o f t w a r e ,a n t h t i m e o d a c l o c k i t h 6 5 2 6 i s n ' t e v e n u s e d . T h s e r i a la n d R S - 2 3 2 r o u t i n e s d o n ' t u s t h s h i f t r e g i s t e r , w h i c h w o u l da l l o w f a s t e r d a t a t r a n s f e r r a t e s . B u m u c h o f t h i s C I i u s e d b t h s y s t e m , i t h e f o l l o w i n g w a y s .

C I A 1 i a c c e s s e d f r o m l o c a t i o n s $ D C 0 0 t $ D C 0 F i m e m o r y . T h I / l i n e s a r u s e d f o t h d u a l f u n c t i o n s o k e y b o a r d a n j o y s t i c kr e a d i n g . P o r t A , a $ D C 0 0 , i u s e d a t h k e y b o a r d m a t r i x r o s e l e c t , a n r e a d s j o y s t i c k 2 o r t h e p a d d l e f i r e b u t t o n s . B i t s a n o t h i s p o r t a r e a l s o u s e d t s e l e c t w h i c h a n a l o g i n p u t s ( p a d d l e s e t )a r r e a d f r o m t h S I c h i p . P o r t a $ D C 0 1 r e a d s t h k e y b o a r dm a t r i x c o l u m n a n j o y s t i c k 1

T h t w t i m e r s i n t h i s c h i p a r u s e d t o g e t h e r a s i n g l e 1 6 - b i tt i m e r . W h e n t h t i m e r c o u n t s d o w n t i t p r o g r a m m e d v a l u e ( s e tt 1 / 6 0 o s e c o n d b y t h o p e r a t i n g s y s t e m ) , i g e n e r a t e s a I R ( I n t e r r u p t R e Q u e s t ) . T h c o u n t d o w n v a l u e f o t h t i m e r s c a b

c h a n g e d s i m p l y b y s t o r i n g n e v a l u e s i t h t i m e r l o c a t i o n s a $ D C 0 4 a n $ D C 0 5 ( l o w , h i g h ) . P O K E i n g a b o u t h e r e w i l l c h a n g et h f r e q u e n c y a w h i c h t h I R Q s o c c u r , a n c a p r o d u c e s o m ei n t e r e s t i n g r e s u l t s . A l s o , t h t i m e r c a n b e t u r n e d o f b c l e a r i n g b i

a $ D C 0 E ; a e a s y w a t d i s a b l e t h i n t e r r u p t s j u s t r e s e t t h b i t r e - e n a b l e .

r e a d i l y a v a i l a b l e s o u r c e o i n f o r m a t i o n o t h 6 5 2 6 i t s e l f ( n o tn e c e s s a r i l y o t h w a i i i m p l e m e n t e d i t h e 6 4 ) i t h C o m m od o r e 6 4 P r o g r a m m e r ' s r e f e r e n c e m a n u a l . Y o c a a l s o f i n d s p e c si t h A p p e n d i c e s o t h 6 5 1 0 ( C P U ) , 6 5 6 7 ( V I C - 1 I ) , a n 6 5 8 1( S I D ) .

1 1 ) 6 5 2 6 C I A 2

T h s e c o n d 6 5 2 6 i u s e d p r i m a r i l y f o R S - 2 3 2 a n d s e r i a l c o m m u ni c a t i o n s , a n t b a n k - s e l e c t t h V I c h i p . I t ' s r e g i s t e r s l i a $ D D 0 0i t h C 6 m e m o r y m a p .

B i t s t h r o u g h o p o r t a r u s e d f o v a r i o u s s e r i a l a n R S - 2 3 2 1 l i n e s ( r e f e r e n c e : T r a n s a c t o r V o l . I s s u e 5 p g 4 7 ) . T h f i r s t t w

b i t s o t h i s p o r t s e l e c t w h i c h 1 6 K b a n k t h V I C - U v i d e o c h i pa d d r e s s e s . T h e s e l i n e s a r n o r m a l l y b o t h h i g h , s e l e c t i n g t h l o w e s tb a n k t a l l o w s c r e e n m e m o r y t r e s i d e a $ 0 4 0 0 . T h I / l i n e s o fp o r t a r u s e d a v a r i o u s R S - 2 3 2 c o n t r o l l i n e s .

T h t i m e r s i n t h i s c h i p a r u s e d b y t h R S - 2 3 2 r o u t i n e s a n g e n e r a t e a N M ( N o n M a s k a b l e I n t e r r u p t ) w h e n t h e y c o u n t d o w n .I y o u ' r e n o u s i n g R S - 2 3 2 , y o c a u s t h e t i m e r s t g e n e r a t eN M I s f o y o u r o w r o u t i n e s . T h i s i h a n d y w h e n y o n e e d t w ol e v e l s o i n t e r r u p t s , s i n c e a N M o v e r r i d e s a I R Q .

1 2 R 2 8 - R 3 0 a n R P 3 , P u l l - u p R e s i s t o r s

R 2 8 , R 2 9 , a n d R 3 0 a r u s e d t " p u l l u p s o m e l i n e s o t h 6 5 2 6w h i c h h a v e n i n t e r n a l p u l l - u p r e s i s t o r s ( a l l b u t h p a r a l l e l p o r tl i n e s ) . T h r e s i s t o r p a c k R P i u s e d f o t h s e r i a l p o r t . P u l l - u pr e s i s t o r s o c o m m u n i c a t i o n s l i n e s r e d u c e n o i s e , b u a l s o d r a wc u r r e n t . T h a t l e a d s t t h n e x t c o m p o n e n t , t h s e r i a l p o r t b u f f e r .

1 3 S e r i a l P o r t B u f f e r

T h i s b u f f e r c h i p g i v e s t h e s e r i a l l i n e s m o r e d r i v e c u r r e n t .

1 4 A n a l o g I n p u t M u l t i p l e x e r

W h e n g a m e p a d d l e s a r e u s e d , t h e y p l u g i n t o t h j o y s t i c k p o r t s ,s e o t w i n t o e a c h p o r t . I n t h S I c h i p , t h e r e a r e t w r e g i s t e r s ( a 5 4 2 9 7 a n d 5 4 2 9 8 ) f r o m w h i c h t h v a l u e s o a n a l o g i n p u t s ' x a n

c a n b e r e a d . S i n c e t h e r e a r e f o u r p a d d l e s a n o n l y t w a n a l o gi n p u t s , o n o r t h e o t h e r m u s t b s e l e c t e d , o " m u l t i p l e x e d " i n t oo n e . T h a t i t h f u n c t i o n o f t h i s c h i p . I h a t w a n a l o g i n p u t s a n f o u r o u t p u t s . O n o t h t w i n p u t s e t s a r r o u t e d t t h e o u t p u t s ,d e p e n d i n g o t h s t a t e o f t w d i g i t a l i n p u t l i n e s . T h e s e s e l e c t l i n e sa r c o n n e c t e d t o b i t s a n 7 o p o r t o C I A 1 ( s e e 1 a b o v e ) .B e f o r e g i v e n p a d d l e s e c a n b e r e a d , t h e s e b i t s m u s t b s e a c c o r d i n g l y :

C I A 1 , P o r t P a d d l e s e r e a d f r o mB i B i S I A n a l o g i n p u t s

N o n eJ o y s t i c k p o r tJ o y s t i c k p o r tB o t h

T h T r a n s a c t o r 5 V o l u m e 5 I s s u e 0

Page 57: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 57/88

T h r e f e r e n c e m a n u a l a d v i s e s g i v i n g t h e l i n e s a b o u t h a l f m i l l is e c o n d t o s e t t l e a f t e r s e l e c t i n g p a d d l e s e b e f o r e r e a d i n g t h a n a l o g v a l u e . I n s t e a d o f o u r p a d d l e s , t w a n a l o g j o y s t i c k s m a b c o n n e c t e d a n r e a d i t h s a m e w a y .

1 5 K e y b o a r d C o n n e c t o r

T h i s c o n n e c t o r a l l o w s t h k e y b o a r d t b e a s i l y u n p l u g g e d f r o mt h P b o a r d a n c o n n e c t s t h k e y b o a r d m a t r i x t t h I / l i n e s i nC I A 1 . I a l s o c o n t a i n s t h e l i n e f r o m t h " R E S T O R E " k e y , w h i c h i n o p a r t o t h k e y b o a r d m a t r i x .

1 6 R e s e t a n N M ( R e s t o r e K e y ) G e n e r a t o r

T h i s I i r e s p o n s i b l e f o g e n e r a t i n g t h r e s e t p u l s e t t h C P w h e n t h c o m p u t e r ' s p o w e r i f i r s t t u r n e d o n

I t ' s o t h e r f u n c t i o n i t g e n e r a t e a N M ( N o n M a s k a b l e I n t e r r u p t )w h e n t h R E S T O R E k e o t h k e y b o a r d i s t r u c k . s a s t r u c k ,a n n o t p r e s s e d , b e c a u s e t h e r e ' s a i n g e n i o u s b i o h a r d w a r e h e r et p r e v e n t a c c i d e n t a l s y s t e m r e s t o r e s . T h e f f e c t m a v a r y s l i g h t l yf r o m m a c h i n e t m a c h i n e , b u t r t h i s : h o l d d o w n t h S T O P k e a y o w o u l d b e f o r e R E S T O R E i n g , a n t h e n p r e s s d o w n o t h R E S T O R E k e y , e v e r s o s l o w l y a n g e n t l y . E v e n w h e n t h k e i t o t a l l y d e p r e s s e d , R E S T O R E w o n ' t o c c u r . T h i s i p o s s i b l e b c a u s e o t h w a t h a t t h k e y s o t h k e y b o a r d " c l o s e " . R a t h e rt h a n m a k e a a b r u p t c l o s u r e a s o m e p o i n t o d e p r e s s i o n , t h e yg r a d u a l l y b e c o m e m o r e a n m o r e c o n d u c t i v e a t h e y a r p r e s s e dd o w n , u n t i l t h e r e s i s t a n c e i l o e n o u g h t b r i n g t h e 6 5 2 6 ' s i n p u tl i n e s l o w . T h a t m a k e s i p o s s i b l e f o h a r d w a r e c i r c u i t t o n l yf u n c t i o n w h e n t h k e i p r e s s e d d o w n r e l a t i v l e y q u i c k l y ; ac a p a c i t o r t a k e s c a r e o f t h a t .

1 7 C a s s e t t e M o t o r C o n t r o l T r a n s i s t o r

T h i s t r a n s i s t o r i c o n t r o l l e d b b i 5 o t h 6 5 1 0 ' s I / p o r t( a c c e s s e d f r o m l o c a t i o n 1 ) a n s u p p l i e s t h c u r r e n t r e q u i r e d t r u t h m o t o r i t h e x t e r n a l c a s s e t t e u n i t . T h o u t p u t o f t h i s t r a n s i s t o ri V o l t s , a n i g o e s t p i o t h c a s s e t t e p o r t . Y o c a n u s e t h i st p o w e r o t h e r d e v i c e s i y o w i s h , f o e x a m p l e V o l t r e l a y .U s i n g r e l a y i n t h i s w a w o u l d l e y o d w i e r d a n w o n d e r f u lt h i n g s l i k e c o n t r o l l i n g t h l i g h t s i n y o u r h o u s e w i t h s o f t w a r e .

1 8 E x p a n s i o n P o r t C o n n e c t o r

T h i s i w h e r e t h p l u g - i n R O c a r t r i d g e s g o C P c o n t r o l l i n e si n c l u d i n g t h a d d r e s s a n d a t a b u c o m e o u o n t o t h e x p a n s i o np o r t . A l s o a v a i l a b l e o t h e p o r t a r e : T h 5 V o l t s u p p l y , I R Q a n dN M i n t e r r u p t l i n e s , t h e 8 . 1 8 M H v i d e o c l o c k , a n t h 6 5 1 0R E S E T l i n e . T h G A M E a n E X R O M i n p u t s a r e u s e d b R O c a r t r i d g e s t s w i t c h t h R O i n t o t h m e m o r y m a i p l a c e o t h u s u a l R A M .

1 9 J o y s t i c k / P a d d l e C o n n e c t o r s

T h j o y s t i c k c o n n e c t o r s a r d e s i g n e d t b u s e d w i t h j o y s t i c k s o p a d d l e s , b u s i n c e t h e y h a v e f i v e I / l i n e s , t w a n a l o g i n p u t s , a n p o w e r a v a i l a b l e o t h e m , t h e y c o u l d b u s e d f o o t h e r a p p p l i c a -t i o n s a s w e l l . A a n a l o g j o y s t i c k , f o e x a m p l e , c o u l d b e c o n n e c t e dt t h a n a l o g i n p u t s . B u s i n g b o t h j o y s t i c k p o r t s , y o u w o u l d h a v et e I / l i n e s a v a i l a b l e , t w h i c h y o u c o u l d c o n n e c t k e y b o a r dm a t r i x f o a e x t e r n a l n u m e r i c k e y p a d .

V i d e o2 O ) V I C - 1 I V i d e o C h i p

H e r e ' s a n o t h e r o n o t h h e a v y w e i g h t c h i p s t h a t m a d e t h 6 f a m o u s . U n l i k e t h 6 5 1 0 a n d S I D , t h V I C — I I s t a y s o u o t h l i m e l i g h t b h i d i n g u n d e r l a r g e m e t a l l i d . T h V I C — I I ( s u c c e s s o rt t h e c h i p u s e d i t h V I C - 2 0 ) h a n d l e s a l t h p r o c e s s i n g w h e n i c o m e s t t h e s c r e e n . I s u p p o r t s t e x t a n d b i t - m a p p e d s c r e e nm o d e s , i n o r m a l o r m u l t i - c o l o u r . T h V I C - I I i a l s o r e s p o n s i b l ef o g e n e r a t i n g t h " s p r i t e s " ( o M O B s M o v a b l e O b j e c t B l o c k s ) ,a n c a n b e p r o g r a m m e d t g e n e r a t e a i n t e r r u p t w h e n s p r i t e" c o l l i d e s " w i t h t e x t , o w i t h a n o t h e r s p r i t e .

T h V I C - I I a c c e s s e s m e m o r y d i r e c t l y , a n s c r e e n m e m o r y c a n b es e u a n y w h e r e , w i t h i n 1 6 b o u n d a r y . S i n c e t h e V I C - I I c a o n l ya d d r e s s u t 1 6 o m e m o r y a a t i m e , t h u p p e r t w b i t s o t h a d d r e s s a r f o r m e d b b i t s a n o p o r t i C I A 2 ( s e e 1 a b o v e ) .

T h V I C - I I ' s v a r i o u s c o n t r o l r e g i s t e r s a r a c c e s s e d f r o m $ D 0 0 0 t $ D 0 2 E i m e m o r y . M o s t o t h e s e a r u s e d t c o n t r o l t h e 8 s p r i t e s ,b u t h e r e a r e a f e a s s i g n e d t m o r e e s o t e r i c f u n c t i o n s . T h r e g i s t e r s a $ D 0 1 3 a n $ D 0 1 4 g i v e t h e c u r r e n t ( x , y ) s c r e e n l o c a t i o no t h l i g h t p e n , i o n i c o n n e c t e d . T h r a s t e r r e g i s t e r ( a $ D 0 1 2 )a l l o w s y o t s e l e c t a n s c r e e n l i n e , a n h a v e t h V I C - I I c h i pg e n e r a t e a i n t e r r u p t w h e n t h r a s t e r b e a m r e a c h e s t h a t l i n e . T h s o u r c e o a i n t e r r u p t c a b e x a m i n e d f r o m r e g i s t e r $ D 0 1 9 ( t h e r ea r e f o u r s o u r c e s ) , a n d a n y o t h e s e s o u r c e s c a b m a s k e d v i l o c a t i o n $ D 0 2 0 . T h f o u r i n t e r r u p t s o u r c e s a r e : T h r a s t e r c o p a r e r e g i s t e r , s p r i t e c o l l i s i o n , t h e t i m e r i C I A 1 , a n t h l i g h t p e i n p u t .

2 1 S h i e l d e d V i d e o S e c t i o n

T h i s s e c t i o n a p p e a r s a s a b i g m e t a l s h i e l d w h i c h d o m i n a t e s t h r i g h t s i d e o t h P b o a r d . T h m e t a l s h i e l d i t h e r e t p r e v e n t t h h i g h f r e q u e n c i e s w h i c h a r p r e s e n t f r o m i n t e r f e r i n g w i t h r a d i o o rt e l e v i s i o n r e c e p t i o n . T h s h i e l d a l s o s e r v e s a h e a t s i n k f o t h V I C - I I c h i p , s o y o s h o u l d n ' t r u t h c o m p u t e r w i t h t h e s h i e l dr e m o v e d .

U n d e r t h l i d , t h c i r c u i t r y i d i v i d e d i n t o t w p a r t s . O t h l e f t i t h V I C - I I v i d e o c h i p a n f e s u p p o r t c o m p o n e n t s . O t h r i g h th a l f i t h e c l o c k c i r c u i t r y f o r t h s y s t e m ( 1 . 0 2 M H z ) , a n f o t h v i d e o ( 8 . 1 8 M H z ) .

T h c l o c k c i r c u i t r y p r o v i d e s t h e b a s i c t i m e u n i t s , o c y c l e s , o w h i c h e v e r y t h i n g o p e r a t e s . T h m a i n s y s t e m c l o c k o 1 . 0 2 M H k e e p s t h C P U , m e m o r y , a n o t h e r d e v i c e s s y n c h r o n i z e d . T h l e n g t h o t i m e t a k e n f o t h C P t e x e c u t e a i n s t r u c t i o n i m e a s u r e d i c l o c k c y c l e s , s i n c e t h C P c a d o o n e s i m p l eo p e r a t i o n ( s u c h a s m e m o r y r e a d o w r i t e ) e v e r y c y c l e .

T h v i d e o c l o c k i 8 . 1 8 M H z , t h r a t e a w h i c h t h e i n d i v u a l p i c t u r ed o t s i t h v i d e o s i g n a l a r s h i f t e d o u t . I i i n t e r e s t i n g t n o t e t h a t4 . M H i t h h i g h e s t f r e q u e n c y a w h i c h t e l e v i s i o n c a r e s o l v e

s i n g l e d o t , w h i c h i w h t w d o t s m u s t b p l a c e d s i d e b s i d eb e f o r e t h e y b e c o m e v i s i b l e . T h a t ' s w h t h e c h a r a c t e r s e t i n t h 6 i d i f f e r e n t f r o m t h P E T ' s : t h e 6 m u s t a l w a y s h a v e t w d o t s s i d eb s i d e , w h i l e t h P E T ' s h i g h e r r e s o l u t i o n v i d e o m o n i t o r c a r e s o l v e s i n g l e d o t . ( 4 c o l u m n P E T s u s a M H v i d e o c l o c k ,a n 8 c o l u m n m a c h i n e s u s 1 M H z . )

T h T r a n s a c t o r 5 V o l u m e 5 I s s u e 0

Page 58: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 58/88

2 2 C o l o u r I n t e n s i t y C o n t r o l

T h i s s m a l l p o t e n t i o m e t e r i l o c a t e d i t h v i d e o s e c t i o n ( u n d e r t h l i d ) a n c o n t r o l s t h c o l o u r s a t u r a t i o n o t h s c r e e n . I o t h e rw o r d s , t u r n i n g t h e c o n t r o l d o w n m a k e s t h p i c t u r e l o o k m o r e l i k eb l a c k a n w h i t e .

2 3 C l o c k F r e q u e n c y A d j u s t m e n t

T h i s a d j u s t m e n t f i n e - t u n e s t h m a i n s y s t e m c l o c k f r e q u e n c y . B u tb e f o r e y o t r y t o t u r n i t m a x i m u m t s o u p u y o u r 6 4 , s t o p : i o n l y c h a n g e s t h f r e q u e n c y v e r y s l i g h t l y , a n i m a k e s m o s tp r o f o u n d i n f l u e n c e o t h e s c r e e n c o l o u r s , s i n c e i a f f e c t s t h v i d e oc l o c k a s w e l l . I n f a c t , i t ' s i n t e n d e d p u r p o s e i a s t i n t c o n t r o l , s t h a t t h c o l o u r c l o c k c a n b e a d j u s t e d t m a k e g r e e n l o o k g r e e n ,b l u e l o o k b l u e , e t c . T h i s i u s u a l l y s e p r o p e r l y b e f o r e t h 6 l e a v e st h f a c t o r y , s w o u l d a d v i s e a g a i n s t p l a y i n g w i t h i t u n l e s s y o d o n ' t m i n d t h e c h a r a c t e r s i y o u r f a v o r i t e v i d e o g a m e s p o r t i n gg r e e n f a c e s !

2 4 R M o d u l a t o r

T h e R F ( R a d i o F r e q u e n c y ) m o d u l a t o r ' s p u r p o s e i l i f e i s t m i t h v i d e o s i g n a l f r o m t h V I C — I I c h i p w i t h h i g h - f r e q u e n c y c a r r i e r s t h a t i c a n b e s e n t t t e l e v i s i o n . I n s o m e c o m p u t e r s , l i k e t h V 1 C -2 0 t h R m o d u l a t o r i e x t e r n a l t t h c o m p u t e r . C o m m o d o r e g o i r i g h t t h i s t i m e a n h i i i t h m a c h i n e w h e r e i b e l o n g s . T h e R Fm o d u l a t o r i a c t u a l l y c o l l e c t i o n o c o m p o n e n t s , l i k e l i t t l e c o i l sa n s u c h . T h w h o l e m e s s i s h i e l d e d u n d e r t h m e t a l l i y o s e t p r o t e c t t h w o r l d f r o m s p u r i o u s R t r a n s m i s s i o n s .

P o w e r2 5 P o w e r S u p p l y C o n n e c t o r

T h i s c o n n e c t o r g o e s t t h e x t e r n a l p o w e r s u p p l y . T w p o w e ri n p u t s f r o m t h s u p p l y a r f e t t h p i n s o t h i s c o n n e c t o r : V o l tD r e g u l a t e d s u p p l y , a n a V o l t A s u p p l y .

T h 5 V o l t s u p p l y i u s e d t p o w e r a l t h d i g i t a l I C o t h b o a r de x c e p t t h e V I C — I I v i d e o c h i p . T h 9 V o l t A s u p p l y i c o n v e r t e d t 1 a n V o l t D r e g u l a t e d v o l t a g e s a n u s e d t p o w e r t h e V I C — I Ic h i p a n c l o c k c i r c u i t r y ( t h e V I C — I I c h i p r e q u i r e s b o t h a n 1 V o l t p o w e r i n p u t s ) .

T h V o l t A s u p p l y h a s a n o t h e r i n t e r e s t i n g u s e : i i t h s o u r c e o t h 6 H s i g n a l u s e d b t h t i m e - o f - d a y ( T O D ) c l o c k i t h 6 5 2 6C I A s . T h V o l t s A i f e t N A N D g a t e i n s i d e U 2 7 , w h e r e i i c o n v e r t e d t V o l t s q u a r e w a v e . T h i s d i g i t a l s i g n a l g o e s t t h T O p i o e a c h 6 5 2 6 , w h e r e i s e r v e s t k e e p s t i m e f o t h T O c l o c k .

S o m e r e l a t e d t r i v i a : o t h S X - 6 4 , s w i t c h i n g p o w e r s u p p l ys y s t e m i u s e d , a n t h e r e ' s n 9 V o l t A s u p p l y a v a i l a b l e . T p r o v i d e 6 H s i g n a l f o r t h T O c l o c k s , a a d d i t i o n a l o s c i l l a t o rc i r c u i t , i n c l u d i n g a n o t h e r c r y s t a l , e x i s t s o t h b o a r d .

2 6 F u s e

T h f u s e i f o t h V o l t A l i n e o n l y , w h i c h m e a n s t h a t y o w o n ' tb l o w i b s h o r t i n g o u t h e 5 V o l t s a v a i l a b l e o t h u s e r p o r ty o u ' l l j u s t s h u t d o w n t h e r e g u l a t o r i t h p o w e r s u p p l y t e m p o r a ri l y . I y o s h o r t o u t t h e 9 V o l t s u p p l y o t h u s e r p o r t , h o w e v e r , t h

f u s e w i l l b l o w . T h p o w e r i n d i c a t o r L E D O E S N O G O O U Tw h e n t h f u s e b l o w s , s i n c e i i n d i c a t e s p o w e r o n t h m a i n V D l i n e . S i y o u r c o m p u t e r d i e s , s u s p e c t t h f u s e e v e n i t h L E i s t i l l o n

2 7 V o l t a g e S t e p - U p C i r c u i t r y

T h e s e c o m p o n e n t s a r n e c e s s a r y f o t h p r o c e s s o c o n v e r t i n g t h V o l t s A f r o m t h p o w e r s u p p l y i n t o 1 2 V o l t s D f o t h V I C - I I

c h i p . f e d i o d e s a n c a p a c i t o r s c r e a t e a v o l t a g e d o u b l e r c i r c u i t ,r e c t i f i e r , a n f i l t e r ; t h i s c o n v e r t s t h e 9 V o l t A s u p p l y i n t o t h 1 V o l t s f i l t e r e d D w h i c h i f e t t h 7 8 1 2 v o l t a g e r e g u l a t o r .

2 8 7 8 1 2 1 V o l t R e g u l a t o r

A f t e r t h e 9 V o l t s A i c o n v e r t e d t 1 V o l t s D C i i f e t t h i sv o l t a g e r e g u l a t o r , w h i c h g i v e s r e g u l a t e d 1 2 V o l t o u t p u t . T h 1 V o l t s i r e q u i r e d f o t h v i d e o c i r c u i t r y , a n c o n n e c t s t t h V I C -l l ' s 1 v o l t i n p u t .

2 9 7 8 0 5 V o l t R e g u l a t o r

T h V o l t s u p p l y i r e c t i f i e d a n f i l t e r e d , t h e n f e t o t h i s I w h i c hp r o d u c e s v o l t r e g u l a t e d o u t p u t . T h r e s u l t i n g V o l t s u p p l yf e e d s t h e V I C - I I v i d e o c h i p a n t h e c l o c k c i r c u i t r y u n d e r t h s t e e ls h i e l d .

T h 7 8 0 5 s h o u l d h a v e h e a t s i n k m o u n t e d o i t b u s o m e o t h e a r l i e s t 6 4 c a m e w i t h o u t o n e . T h r e s u l t w a t h a t t h e s e m a c h i n e sh a p r o b l e m s c o p i n g w i t h w a r m t e m p e r a t u r e s , a n t h 7 8 0 5w o u l d s o m e t i m e s o v e r h e a t a n s h u t i t s e l f o f f . N d a m a g e t t h c o m p u t e r , b u i m a g i n e t h c o m p u t e r d y i n g a f t e r y o u ' v e j u s t t y p e di 2 0 0 0 l i n e p r o g r a m ! A p p a r e n t l y , C o m m o d o r e r e a l i z e d t h a t i w a s n ' t w o r t h s a v i n g t h c e n t s o w h a t e v e r h e a t s i n k c o s t s , a n a l 6 4 n o h a v e i t . I f y o u r 6 4 h a o v e r h e a t i n g p r o b l e m s , s e i f i th a t h h e a t s i n k . I n o t , y o c a p u o n o y o u r s e l f . A l t e r n a t i v e l y ,t h 7 8 0 5 c a b c o a t e d w i t h h e a t - s i n k c o m p u n d a n d p u s h e d u a g a i n s t t h s t e e l R s h i e l d t h e l p s i n k t h h e a t .

3 0 P o w e r I n d i c a t o r L E C o n n e c t o r

T h i s c o n n e c t o r a t t a c h e s t t h l o n g p a i r o f w i r e s w h i c h l e a d t t h p o w e r i n d i c a t o r L E D . T h w i r e m u s t b e u n p l u g g e d f r o m t h c o n n e c t o r w h e n r e m o v i n g t h u p p e r h a l f o f t h c a s e .

A m e n t i o n e d b e f o r e , t h L E d o e s n o g o u w h e n t h f u s eb l o w s . I t ' s p u r p o s e i t i n d i c a t e t h a t t h r e g u l a t e d V o l t s f r o m t h p o w e r s u p p l y i a l i v e , s i n c e t h i s s u p p l y w o u l d a u t o m a t i c a l l y s h u td o w n i o v e r l o a d e d .

W h e r e ' s t h P l u g s ?C o n s i d e r i n g t h c o m p l e x i t y o t h m a i n c h i p s i t h 6 a n t h c o m p u t e r ' s r e l a t i v e l y l o c o s t , t h e r e ' s a s u r p r i s i n g a m o u n t o s t u f fi t h e r e ! O c o u r s e , t h e r e a r e m a n y c o m p o n e n t s a n d c i r c u i t s n o m e n t i o n e d a b o v e , b u t h e y a r e n o t i m p o r t a n t e n o u g h t g i n t od e t a i l a b o u t . U n l e s s , o c o u r s e , y o w i s h t m o d i f y o r s e r v i c e t h m a c h i n e y o u r s e l f ; f o i y o u e n d u p b u y i n g t h a t s p o r t s c a r , y o p r o b a b l y w i l l w a n t t k n o w t h s p a r k p l u g g a s i z e .

T h a n k s g o e s t " H a r d w a r e C o r n e r " A u t h o r D o m e n i c D e F r a n c e s c of o t h e t e c h n i c a l i n f o r m a t i o n w h i c h m a d e t h i s a r t i c l e p o s s i b l e , a n t C o m m o d o r e f o r t h e c i r c u i t b o a r d l a y o u t d i a g r a m .

T h T r a n s a c t o r 5 V o l u m e 5 I s s u e 0

Page 59: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 59/88

A l A b o u t P r i n t e r s :W h a t y o s h o u l d k n o w b e f o r e b u y i n gC h r i s Z a m a r a , T e c h n i c a l E d i t o r

" C h o o s i n g t h ' b e s t ' p r i n t e r i l i k e c h o o s i n g t h e ' b e s t ' c a r o ' b e s t ' p e t . .

p r i n t e r i o n o t h o s e p e r i p h e r a l s t h a t p e o p l e e i t h e r h a v e ,o w i s h t h a t t h e y d i d . F o a n k i n d o s e r i o u s u s e , y o u s u a l l y n e e d s o m e k i n d o p e r m a n e n t p r i n t e d r e c o r d o y o u r p r o g r a m ' s o u t p u t . E v e n j u s t f o r p r o g r a m d e v e l o p m e n t ,i t ' s l o m o r e p r o d u c t i v e t s i d o w n w i t h l i s t i n g a n p e n c i l t h a n t s t a r e a 2 l i n e s o f c o d e a t i m e o t h s c r e e n .

B u d o n ' t h a v e t c o n v i n c e y o h o u s e f u l p r i n t e r i s T h p r o b l e m i s w h a t k i n d o p r i n t e r b e s t s u i t s C o m m o d o r eo w n e r ' s n e e d s ? C h o o s i n g t h e " b e s t " p r i n t e r i l i k e c h o o s i n gt h e " b e s t " c a r o r " b e s t " p e t : i d e p e n d s o y o u r n e e d s ,e x p e c t a t i o n s , b u d g e t , a n d o z e n s o o t h e r p e r s o n a l f a c t o r s .T h b e s t d e c i s i o n i t h r e s u l t o f c a r e f u l c o m p r o m i s e , a n dc a o n l y c o m e f r o m k n o w l e d g e o n t h s u b j e c t . T h a t i t h p u r p o s e o f t h i s a r t i c l e : t a r y o w i t h i n f o r m a t i o n a y o e n t e r t h e v e r - g r o w i n g w o r l d o m i c r o c o m p u t e r p r i n t e r s .

I n t e r f a c i n g a n C o m p a t i b i l i t y

B e f o r e g o i n g i n t o p r i n t e r s i g e n e r a l , t h i s s e c t i o n m u s t b p r e s e n t e d ; g e n e r a l a r t i c l e o p r i n t e r s i n o g o o d t C o m m o d o r e o w n e r u n l e s s h f i r s t k n o w s a b o u t c o m p a t i b i li t w i t h C o m m o d o r e e q u i p m e n t .

T h e r e i s o m e c o n f u s i o n i b u y i n g p r i n t e r f o C o m m od o r e 6 o V I C . Y o c a g e a p r i n t e r w h i c h g o e s o t h s e r i a l p o r t ( l i k e t h C o m m o d o r e p r i n t e r s ) , a R S - 2 3 2p r i n t e r , C e n t r o n i c s - t y p e p a r a l l e l p r i n t e r ( w h i c h c a n b e d r e c t l y c o n n e c t e d a n u s e d w i t h s p e c i a l s o f t w a r e ) , o a I E E Ep a r a l l e l p r i n t e r w i t h a i n t e r f a c e c a r d . O u o a l t h e s es c h e m e s , o n l y C o m m o d o r e p r i n t e r i d i r e c t l y c o m p a t i b l e ,s i n c e i w i l l c o n n e c t w i t h o u t a i n t e r f a c e , p r i n t a l s p e c i a lg r a p h i c s s y m b o l s , a n p r o d u c e p r o g r a m l i s t i n g s w h i c h l o o kj u s t a t h e y w o u l d o t h s c r e e n . T h a t d o e s n ' t m e a n t h a tC o m m o d o r e p r i n t e r i t h o n l y w a t g o h o w e v e r . T h e r ea r g r e a t v a r i e t y o p r i n t e r s o u t h e r e t h a t w i l l w o r k v e r yw e l l w i t h C o m m o d o r e s y s t e m . B u t b e c a r e f u l a b o u t y o u rc h o i c e o p r i n t e r a n i n t e r f a c e , o y o m a w i n d u p w i t hp r i n t e r t h a t y o w o n ' t b a b l e t u s f o p r o g r a m l i s t i n g s , o o n t h a t w i l l g i v e y o l o w e r c a s e w h e n y o u w a n t u p p e r , a n v i c e - v e r s a .

A i n t e r f a c e l e t s y o c o n n e c t p r i n t e r s u s i n g c o m m u n i c a t i o np r o t o c o l s o t h e r t h a n t h o s e u s e d b y C o m m o d o r e . T h e m o s t

c o m m o n p r o t o c o l s u s e d w i t h m i c r o c o m p u t e r p r i n t e r s a r eo u t l i n e d b e l o w .

I E E E - 4 8 8( U s u a l l y c a l l e d " I E E E " , p r o n o u n c e d " e y e t r i p l e e e " ) . C o n e c t s d i r e c t l y t P E T , o c a n b e u s e d o C 6 o V I w i t ha p p r o p r i a t e i n t e r f a c e c a r d . H e n c e r e f e r r e d t a " I E E E " .

C e n t r o n i c s - t y p e p a r a l l e lT h m o s t c o m m o n l y u s e d p r o t o c o l a m o n g p a r a l l e l p r i n t e r s :c a n b e u s e d o 6 o V I w i t h a i n t e r f a c e ( e g . c a r d c o ) , o p l u g g e d d i r e c t l y i n t o t h u s e r p o r t o n a n y m a c h i n e a n u s e dw i t h s p e c i a l s o f t w a r e . C a b e u s e d o P E T ' s I E E E b u w i t ha i n t e r f a c e w h i c h m a a l s o c o n v e r t f r o m C B A S C I I t r e a lA S C I I . R e f e r r e d t a j u s t " p a r a l l e l " f r o m n o o n

C 6 s e r i a lU s e d o n C o m m o d o r e p r i n t e r s : p l u g s i n t o s e r i a l p o r t o n C 6 4o r V I C , a n c a b e c o n n e c t e d a l o n g w i t h d i s k d r i v e s a n o t h e r p e r i p h e r a l s .

R S - 2 3 2R S - 2 3 2 i t h s t a n d a r d s e r i a l p r o t o c o l , u s e d b y m a n yp r i n t e r s . A R S - 2 3 2 p r i n t e r w i l l p l u g i n t o C 6 o V I w i t hC o m m o d o r e ' s R S - 2 3 2 i n t e r f a c e ( t h i s i n t e r f a c e m a n o b n e c e s s a r y w i t h s o m e p r i n t e r s , j u s t a c a b l e w i t h a p p r o p r i a t ec o n n e c t o r s ) . C 6 a n d V I C h a v e b u i l t - i n s o f t w a r e t c o m m un i c a t e w i t h R S - 2 3 2 d e v i c e s - j u s t o p e n f i l e t d e v i c en u m b e r 2 A R S - 2 3 2 p r i n t e r c a a l s o b e u s e d o P E T ' sI E E E b u s , w i t h a a p p r o p r i a t e i n t e r f a c e .

H e r e i t h d a n g e r w h e n b u y i n g n o n - C o m m o d o r e p r i n t e r :s o m e o t h C o m m o d o r e c o n t r o l c h a r a c t e r s w i l l b m i s i n t e rp r e t e d . F o e x a m p l e , t h " h o m e " c h a r a c t e r i 1 i C B A S C I I , b u t m a n y p r i n t e r s , a 1 s e l e c t s " o f f l i n e " m o d e .T h a t m e a n s t h a t o n o y o u r e v e r y d a y g a r d e n - v a r i e t yp r o g r a m s c o u l d h a l t t h p r i n t e r w h i l e b e i n g l i s t e d , t h c u l p r i t b e i n g ' P R I N T " f l 1 " c o m m a n d e m b e d d e d s o m ew h e r e i t h p r o g r a m .

F o r t u n a t e l y , t h e r e a r e s o m e v e r y s m a r t i n t e r f a c e s t h a t g e ta r o u n d t h p r o b l e m q u i t e e l e g a n t l y . F o r e x a m p l e , t h C A R D ? i n t e r f a c e f r o m c a r d c o i n c . a l l o w s y o t c o n n e c tC 6 o V I t p a r a l l e l p r i n t e r t h r o u g h t h s e r i a l p o r t ( t h e

T h T r a n s a c t o r 5 V o l u m e 5 I s s u e 0

Page 60: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 60/88

s a m e p o r t t h e d i s k d r i v e i c o n n e c t e d t o ) . T h i n t e r f a c ek n o w s a l a b o u t t h C o m m o d o r e c o n t r o l c h a r a c t e r s , a n h a s a s p e c i a l " l i s t i n g m o d e " t d e a l w i t h t h e m . I l i s t i n gm o d e , h o m e c h a r a c t e r a p p e a r s o t h e p r i n t e r a s " { H M } " ,s c r e e n c l e a r a s " { S C } " ; a l c o n t r o l s y m b o l s i n c l u d i n g c u r s o rc o n t r o l s a n c o l o u r c o m m a n d s a r c o d e d s i m i l a r l y . Y o s t i l lw o n ' t b a b l e t s e t h s p e c i a l C o m m o d o r e g r a p h i c ss y m b o l s a t h e y a p p e a r o t h s c r e e n w i t h a n y t h i n g b u t aC o m m o d o r e p r i n t e r . T h a t m a b f a c t o r I y o u ' r e r u n n i n g

l o o g r a p h i c - o r i e n t e d s o f t w a r e .

O c o u r s e , t h e r e i a l s o t h e c o m p a t i b i l i t y p r o b l e m w i t hC o m m o d o r e A S C I I a n r e a l A S C I I : c o d e s f o u p p e r a n l o w e r c a s e a r e s w i t c h e d . T h i n t e r f a c e h a n d l e s t h a t p r o b l e ma s w e l l , a n u s u a l l y c a b s e l e c t e d b e t w e e n P E a n r e a lA S C I I b m e a n s o s w i t c h e s , o r b s o f t w a r e c o m m a n d s . S d o n ' t b a l k a b u y i n g n o n - C o m m o d o r e p r i n t e r , j u s t m a k es u r e t h a t y o c a g e a a p p r o p r i a t e i n t e r f a c e f o t h p r i n t e ry o b u y , a n i n c l u d e t h c o s t o t h i n t e r f a c e w h e n c o m p a ri n p r i c e s .

A R S - 2 3 2 p r i n t e r c a b p l u g g e d i n t o t h R S - 2 3 2 p o r t w i t ho n l y s i m p l e i n t e r f a c e , a n i w i l l w o r k , a l e a s t f r o mh a r d w a r e s t a n d p o i n t . B u t h c o m p a t i b i l i t y p r o b l e m s o u l i n e d a b o v e w i l l p e r s i s t , a n m a r e q u i r e y o t w r i t ec u s t o m s o f t w a r e t g e p r o p e r l i s t i n g s o c o n v e r t t o r e a lA S C I I .

C o n n e c t i n g p a r a l l e l p r i n t e r d i r e c t l y t t h u s e r p o r t ( s a m ec o n n e c t o r a s t h e R S - 2 3 2 p o r t ) w i l l c e r t a i n l y n e e d s p e c i a ls o f t w a r e , w h i c h i r e a d i l y a v a i l a b l e . B u w o r d p r o c e s s o r sa n o t h e r c o m m e r c i a l p a c k a g e s p r o b a b l y w o n ' t w o r k w i t ht h e p r i n t e r a a l l ; y o s a v e t h c o s t o a i n t e r f a c e , b u y o u ' l lm o s t l y b a b l e t u s t h p r i n t e r o n l y w i t h y o u r o w p r o g r a m s .

A I E E E p r i n t e r i t h e b e s t c h o i c e f o u s w i t h a n y P E T -s e r i e s m a c h i n e , s i n c e i w i l l d i r e c t l y p l u g i n w i t h t h a i o a I E E E c a b l e . S o m e p r i n t e r s , s u c h a t h E p s o n M X 8 0 , c a b o r d e r e d w i t h o p t i o n a l I E E E i n p u t i n s t e a d o i t u s u a lp a r a l l e l i n t e r f a c e . I y o h a v e a I E E E c a r d o n y o u C 6 4 , y o c a a l s o u s a I E E E p r i n t e r .

N o w , a l t h i s t a l k a b o u t i n c o m p a t i b i l i t y w i t h c o m m o d o r ec o n t r o l c h a r a c t e r s w o n ' t c o n c e r n y o i y o p l a n o u s i n gt h e p r i n t e r o n l y w i t h c o m m e r c i a l s o f t w a r e p a c k a g e s . M o s tw o r d p r o c e s s o r s , f i l e - m a n a g e r s , e t c . k n o w h o w t h a n d l ed i f f e r e n t p r i n t e r s , a n t h e r e a r e p r o g r a m s a v a i l a b l e w h i c hw i l l l e y o L I S T t n o n - C o m m o d o r e p r i n t e r . B u t h i sb r i n g s u a n o t h e r i m p o r t a n t p o i n t : M a k e s u r e t h a t a n s o f t w a r e y o u b u y w i l l w o r k w i t h y o u r p a r t i c u l a r p r i n t e r /i n t e r f a c e c o m b i n a t i o n ! Y o m i g h t w a l k o u o c o m p u t e rs t o r e w i t h a e x p e n s i v e p r i n t e r a n w o r d p r o c e s s o r , o n l y t f i n d t h a t y o c a n ' t g e p r o p e r p r i n t o u t s . I y o u ' r e n o s u r ew h a t ' s c o m p a t i b l e w i t h w h a t , y o u ' r e b e s t o f b u y i n g f r o ms o m e w h e r e t h a t h a c o m p e t e n t s a l e s p e o p l e , e v e n i t h e i rp r i c e s a r e h i g h e r t h a n t h l o c a l d e p a r t m e n t s t o r e .

O c o u r s e , t h e r e ' s n " b e s t " s e t u p a f a a i n t e r f a c i n g g o e s .T h t y p e o c o m m u n i c a t i o n p r o t o c o l u s e d o p r i n t e r

s h o u l d o n l y i n f l u e n c e y o u r p u r c h a s i n g d e c i s i o n i i t ' s g o i n gt p r e s e n t p r o b l e m a f a a i n t e r f a c i n g g o e s , o r i t h c o s to t h e r e q u i r e d i n t e r f a c e i p r o h i b i t i v e .

P r i n t T e c h n o l o g i e s

T h e r e a r q u i t e f e p r i n t t e c h n o l o g i e s i u s t o d a y . T h o n e s m o s t u s e d f o m i c r o c o m p u t e r s a r e :

D a i s y w h e e lD o m a t r i x ( i m p a c t )I n k - j e tT h e r m a lT h e r m a l T r a n s f e rl a s e r

M o s t h o m e - o r i e n t e d p r i n t e r s a r o t h e d a i s y w h e e l o d o t -m a t r i x v a r i e t y , b u t h e r e h a v e b e e n g r e a t a d v a n c e s i t h f i e l d o f i n k - j e t , t h e r m a l t r a n s f e r , a n l a s e r p r i n t e r s . T h m e r i t s a n f a u l t s o t h d i f f e r e n t c a t e g o r i e s w i l l b g i v e nl a t e r , b u h e r e ' s j u s t b r i e f e x p l a n a t i o n o h o e a c hb a s i c a l l y w o r k s :

D a i s y W h e e l

T h p r i n t e r g e t s i t n a m e b e c a u s e t h e c h a r a c t e r s a r e a t h e n d s o t h s p o k e s o w h e e l . T h w h e e l s p i n s u n t i l t h d e s i r e d c h a r a c t e r i i f r o n t o p r i n t h a m m e r , w h e r e i i s t r u c k t i m p r e s s t h r i b b o n o t h e p a p e r . T h p r i n t q u a l i t yo t h e c h a r a c t e r s i u s u a l l y c o m p a r a b l e t t h a t o t y p ew r i t e r , a n d i f f e r e n t w h e e l s c a n b u s e d t p r o v i d e d i f f e r e n tt y p e f a c e s .

D o M a t r i x

d o t - m a t r i x p r i n t e r f o r m s i t c h a r a c t e r s f r o m d o t s . E a c hd o i p r o d u c e d b y l i t t l e p r i n t h a m m e r s t r i k i n g t h r i b b o ni f r o n t o t h p a p e r . T h a p p r o p r i a t e h a m m e r s i r o o f t 9 a r r a n g e d v e r t i c a l l y , s t r i k e t h r i b b o n s i m u l t a n e o u s l yb e f o r e t h e p r i n t h e a d m o v e s t h h a m m e r s t t h n e x tp o s i t i o n .M a t r i x p r i n t e r s a r e g e n e r a l l y f a s t e r a n l e s s e x p e n s i v e t h a nD a i s y W h e e l s , a n c a o f t e n d g r a p h i c s a w e l l .

I n k - j e t

I n k - j e t p r i n t e r s a r o n l y r e c e n t l y b e i n g u s e d w i t h m i c r oc o m p u t e r s . H e w l e t t - P a c k a r d r e c e n t l y i n t r o d u c e d t h e T h i n k -J e t , l o c o s t I n j e p r i n t e r u s i n g d i s p o s a b l e i n c a r t r i d g e s .A n r a d i o s h a c k m a k e s a i n k - j e t c o l o u r p r i n t e r f o t h T R S - 8 0 c o l o u r c o m p u t e r . I n j e p r i n t e r s w o r k b s p r a y i n gi n d i r e c t l y o t t h p a p e r t h r o u g h t i n y h o l e s , a n h a v e t h p o t e n t i a l o c o m b i n i n g h i g h p r i n t s p e e d w i t h g o o d p r i n tq u a l i t y .

T h e r m a l

T h e r m a l p r i n t e r s h a v e b e e n a r o u n d f o l o n g t i m e , b u a r e n ' t v e r y p o p u l a r b e c a u s e t h e y r e q u i r e c o s t l y t h e r m a l

T h T r a n s a c t o r 5 V o l u m e 5 I s s u e 0

Page 61: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 61/88

p a p e r . T h e r m a l p r i n t e r s f o r m c h a r a c t e r s i t h s a m e w a a m a t r i x p r i n t e r s , b u u s l i t t l e h e a t i n g e l e m e n t s i n s t e a d o p r i n t h a m m e r s t b u r n m a r k s i n t o t h h e a t - s e n s i t i v e p a p e r .

T h e r m a l T r a n s f e r

T h i s i n e t e c h n o l o g y , a n d w o r k s o n t h e r m a l p r i n c i p a l ,b u w i t h r e g u l a r p a p e r . T h p r i n t h e a d h e a t s u t h e i n k i t h s p e c i a l r i b b o n , a n b o i l s i o u t o n t o t h p a p e r . T h e r m a lt r a n s f e r p r i n t e r s c a b f a s t , g i v e g o o d q u a l i t y , a n p r i n t i c o l o u r .

L a s e r

W e l l , l a s e r p r i n t e r s c a n ' t b c o n s i d e r e d f o h o m e u s b c a u s e t h c o s t i s s t i l l t o h i g h , b u t h e y ' r e m e n t i o n e d h e r ef o c o m p l e t e n e s s . l a s e r p r i n t e r i l i k e p h o t o c o p y m c h i n e , b u i u s e s l a s e r t e t c h t h i m a g e t b p r i n t e d o n t o

p h o t o s e n s i t i v e d r u m . L a s e r p r i n t e r s a r v e r y f a s t ( t h i n k o h o l o n g i t a k e s a p h o t o c o p i e r t t u r n o u p a g e ) a n a r u s e d o n m a i n f r a m e s y s t e m s a t h p r i m a r y h i g h - s p e e dp r i n t e r . T h e s e l a r g e l a s e r p r i n t e r s c o s t l i t e r a l l y m i l l i o n s o d o l l a r s , a n s p e w o u p r i n t e d p a p e r a f a s t a s 1 2 i n c h e s p e rs e c o n d . S m a l l l a s e r p r i n t e r s f o m i c r o u s e a r e a v a i l a b l e f o b e t w e e n f i v e t o t e t h o u s a n d d o l l a r s , a n a r e e x c e l l e n t f o o f f i c e u s e .

C o s tO b v i o u s l y , s i n c e y o d o n ' t w a n t t s p e n d a l y o u r b e e rm o n e y f o t h n e x t 1 8 1 / 2 y e a r s o p r i n t e r , t h c o s tc r i t e r i o n i v i t a l l y i m p o r t a n t . I ' k e e p i n g a w a y f r o m q u o ti n a c t u a l p r i c e s , s i n c e t h e y ' r e c h a n g i n g a l t h t i m e , a n t h e r e a r e s u c h d i f f e r e n c e s b e t w e e n C a n a d i a n a n d A m e r i c a np r i c e s . D e p e n d i n g o n h o m a n y f e a t u r e s a n h o m u c hs p e e d y o n e e d , y o c a s p e n d a n y w h e r e f r o m c o u p l e o h u n d r e d t s e v e r a l t h o u s a n d d o l l a r s . G e n e r a l l y , d o t m a t r i xp r i n t e r s a r c h e a p e r t h a n d a i s y w h e e l , a n s m a l l t h e r m a lp r i n t e r s a r o f t e n t h c h e a p e s t .

L e t t e r Q u a l i t y

L e t t e r q u a l i t y i u s u a l l y t h m a i n r e a s o n t h a t p e o p l e c h o o s ed a i s y w h e e l p r i n t e r o v e r d o t - m a t r i x o n t h a t i f a s t e r ,

q u i e t e r , a n c h e a p e r . B u d o n ' t t h i n k t h a t y o u m u s t h a v ed a i s y w h e e l p r i n t e r s i m p l y b e c a u s e y o u w a n t t p r i n tc o r r e s p o n d e n c e . M o s t m o d e r n m a t r i x p r i n t e r s g i v e v e r yr e a d a b l e c o p y , a n m a n y h a v e " c o r r e s p o n d e n c e q u a l i t y "m o d e w h i c h g i v e s b e t t e r q u a l i t y b p r i n t i n g m o r e d o t s , a t h e x p e n s e o s p e e d .

I n k - j e t a n t h e r m a l t r a n s f e r p r i n t e r s u s m a t r i x - f o r m e dc h a r a c t e r s , b u g i v e b e t t e r q u a l i t y c h a r a c t e r s t h a n i m p a c td o t - m a t r i x p r i n t e r s , s i n c e t h e d o t s b l e n d t o g e t h e r m o r e .

m a t r i x p r i n t e r c a b u s e d t p r i n t l e t t e r s , b u f o b u s i n e s su s o i m p o r t a n t d o c u m e n t s l i k e j o r e s u m e s , e v e n g o o dm a t r i x m a n o b g o o d e n o u g h . E v e n s o i t h e s e a p p l i c at i o n s a r e t h e e x c e p t i o n , r a t h e r t h a n t h r u l e t y o u r p r i n t i n g

n e e d s , y o m i g h t w a n t t g e d o t - m a t r i x p r i n t e r a n y w a ya n m a k e f r i e n d s w i t h s o m e o n e w h h a a d a i s y w h e e l .A n i v e r y s h o r t l e t t e r h a t l o o k j u s t r i g h t , y o c a a l w a y s p r i n t i o d o m a t r i x , t h e n d o s o m e t h i n g t o t a l l ys t r a n g e l i k e u s T Y P E W R I T E R t g e y o u r f i n a l c o p y .

H o d o y o u c h o o s e b e t w e e n a d a i s y w h e e l p r i n t e r a n m a t r i x p r i n t e r f o t h s a m e p r i c e , b u t 1 0 t i m e s f a s t e r ? W e l l ,w h a t d o y o u w a n t y o u r p r i n t e r f o r ? H e r e ' s t w s c e n a r i o s .

G e o r g e i h a r d - c o r e h a c k e r . H u s e s h i c o m p u t e r f o p r o g r a m m i n g a n d p l a y i n g w i t h , a s a h o b b y . H n e e d sp r i n t e r f o p r o g r a m l i s t i n g s , a n t p r i n t d o c u m e n t a t i o n f o p r o g r a m s t h a t h w r i t e s o u t i l i t i e s t h a t h u s e s . H a l s o h a

m o d e m a n a c c e s s e s b u l l e t i n b o a r d s y s t e m s , a n h w a n t s h a r d c o p y o s o m e o t h i n f o r m a t i o n h g e t s f r o mt h e m . H e M a k e s i n t e n s i v e u s o t h e g r a p h i c s c a p a b i l i t i e s o h i c o m p u t e r , a n d w o u l d l i k e t o p r i n t g r a p h s a n p i c t u r e so h i p r i n t e r .

J e f f h a s m a l l b u s i n e s s , a n w a n t s t u s h i c o m p u t e r t p r i n t i n v o i c e s , m a i l i n g l a b e l s , a n l e t t e r s t o s u p p l i e r s a n c u s t o m e r s . A l o h i o u t p u t i t e x t u a l , a n h w a n t s t g i v ep r o f e s s i o n a l i m p r e s s i o n . H d o e s n ' t d m u c h o h i o w p r o g r a m m i n g , b u t u s e s c o m m e r c i a l l y a v a i l a b l e b u s i n e s sp a c k a g e s .

C l e a r l y , G e o r g e s h o u l d g e m a t r i x p r i n t e r o s o m e t y p e( w h i c h i n c l u d e s d o t - m a t r i x , t h e r m a l , a n t h e r m a l t r a n s f e r ) ,a n J e f f n e e d s l e t t e r q u a l i t y : h e ' l l p r o b a b l y b b e s t o f w i t hd a i s y w h e e l . M o s t o u a r s o m e w h e r e b e t w e e n G e o r g e a n J e f f , a n i t ' s j u s t m a t t e r o s e t t i n g p r i o r i t i e s .

S p e e d

E x p e c t s p e e d s o 8 t 1 6 c h a r a c t e r s p e s e c o n d ( c p s ) f r o md o t - m a t r i x p r i n t e r s . T h c h e a p e s t ( a n d s l o w e s t ) d a i s y w h e e lp r i n t e r s f l a l o n g a 1 2 c p s ( s a r c a s m i n t e n d e d ) , a n t h f a s t e s t a b o u t 2 2 H e w l e t t P a c k a r d ' s i n k - j e t p r i n t e r i f a i r l yf a s t : 1 5 c p s . T h e r m a l p r i n t e r s a r u s u a l l y s o m e w h e r eb e t w e e n d o m a t r i x a n d a i s y w h e e l s i t e r m s o s p e e d .

T g i v e y o a i d e a o w h a t t h e s e s p e e d s m e a n , f u l l p a g ec a n b e p r i n t e d i u n d e r m i n u t e a 1 2 c p s . I y o u ' r ec o n s t a n t l y p r i n t i n g m a n y i n v o i c e s o l o n g p r o g r a m l i s t i n g s ,s p e e d w i l l b e a n i m p o r t a n t c o n s i d e r a t i o n . F o t h o c c as i o n a l s i n g l e - p a g e d l e t t e r , y o m i g h t n o t c a r e i y o u h a v e t w a i t 1 0 m i n u t e s i n s t e a d o 1 a n y o c a h a v e g o o d p r i n tq u a l i t y a l o c o s t .

Y o s h o u l d b e a w a r e t h a t t h C P r a t i n g o p r i n t e r i b n m e a n s a n a v e r a g e s p e e d . I i b e s t - c a s e m e a s u r e m e n t ,t a k e n a t h f a s t e s t p r i n t h e a d s p e e d . I y o u w e r e t c a l c u l a t et h t i m e a p r i n t e r s h o u l d t a k e t p r i n t p a g e b a s e d o t h n u m b e r s o c h a r a c t e r s o t h p a g e a n t h s p e e d o t h p r i n t e r , t h r e s u l t y o u ' d g e w o u l d p r o b a b l y b l e s s t h a n h a l ft h t i m e t h a t t h p r i n t e r w o u l d a c t u a l l y t a k e . T h e r e a r o t h e r f a c t o r s a f f e c t i n g s p e e d b e s i d e s t h e C P r a t i n g , s u c h a b i d i r e c t i o n a l p r i n t i n g , e x p l a i n e d l a t e r .

T h T r a n s a c t o r 5 V o l u m e 5 I s s u e 0

Page 62: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 62/88

P h y s i c a l C a p a b i l i t i e s

F e e d t y p e

F r i c t i o n f e e d p r i n t e r s a l l o w y o t u s s i n g l e s h e e t s o o r d i n a r y p a p e r , j u s t a i a t y p e w r i t e r . T r a c t o r f e e d u s e s p i n st g u i d e t h p a p e r , a n r e q u i r e s t h u s o f a n f o l d p r i n t e rp a p e r w i t h h o l e s i t h s i d e . T r a c t o r f e e d i b e t t e r f o l o n gp r i n t o u t s , s i n c e t h e f o r m s a r c o n t i n u o u s a n d d o n o t r e q u i r er e l o a d i n g a f t e r e v e r y p a g e . A l s o , t r a c t o r f e e d k e e p s t h p a p e r p e r f e c t l y s t r a i g h t . F r i c t i o n f e e d h a t h a d v a n t a g e o a l l o w i n g y o t u s f a n c y p a p e r l i k e l e t t e r h e a d s , o t p r i n to a n y t h i n g : l a b e l s , c h e q u e s , e n v e l o p e s , e t c . M a n y p r i n t e r sg i v e t h c h o i c e o f f r i c t i o n o t r a c t o r f e e d , o h a v e t r a c t o r f e e da a o p t i o n . I t ' s b e s t t h a v e b o t h .

C h a r a c t e r s p e r l i n e

M o s t p r i n t e r s w i l l a c c e p t s t a n d a r d s i z e 8 1 / 2 b 1 p a p e r ,w h i c h i / i n c h e s w i d e i n c l u d i n g t h s i d e s f o t h t r a c t o rp i n s . S o m e L a r g e r p r i n t e r s a c c e p t w i d e r p a p e r , f o e x a m p l e1 o e v e n 1 i n c h e s . T h e n u m b e r o c h a r a c t e r s y o c a p r i n t a c r o s s a p a g e i a i m p o r t a n t c o n s i d e r a t i o n , e s p e c i a l l yf o w o r k w i t h c h a r t s , t a b l e s , a n s p r e a d s h e e t s . M o s t p r i n t e r sw i l l f i 8 c h a r a c t e r s a c r o s s o l i n e , w h i c h i f i n e f o r l e t t e r sa n s u c h , b u t s o m e p r i n t e r s o f f e r u t 2 3 c h a r a c t e r s p e rl i n e ( c p l ) . T h e r e a r i n e x p e n s i v e p r i n t e r s w h i c h f i o n l y 3 2o 4 c p l , a n a r e n ' t r e a l l y g o o d f o a n y t h i n g o t h e r t h a np r o g r a m m i n g u s e s ( l i s t i n g s , v a r i a b l e d u m p s , e t c ) .

P i t c h

T h p i t c h i t h n u m b e r o c h a r a c t e r s p e i n c h . c o m m o np i t c h f o p r i n t e r s i 1 c p i , a n d i f f e r e n t p i t c h e s m a b s e l e c t a b l e b s o f t w a r e . C h e c k t h p i t c h c a p a b i l i t i e s o p r i n t e r t s e i t h e r e i a a c c e p t a b l e r a n g e . D a i s y w h e e lp r i n t e r s m a h a v e p i t c h e s r a n g i n g f r o m 1 t 1 c p i , a n m a t r i x p r i n t e r s f r o m t 1 c p i . T h e r m a l a n d i n e x p e n s i v ed a i s y o r d o t - m a t r i x p r i n t e r s m a h a v e f i x e d p i t c h . I t ' s n i c et b a b l e t c h a n g e p i t c h e s w i t h i n d o c u m e n t f o e m p h as i o c e r t a i n p a s s a g e s .

N o i s e L e v e l

S o m e d a i s y w h e e l p r i n t e r s s o u n d l i k e m a c h i n e g u n , a n t h a t m e a n s y o m a n o b a b l e t u s i a 3 : 0 0 A M j u s tw h e n y o r e a l l y n e e d i t T h e r m a l a i n k - j e t p r i n t e r s a r e t h eq u i e t e s t , b e i n g v i r t u a l l y s i l e n t . M a t r i x p r i n t e r s c a n b e r e s o n a b l y q u i e t , b u s o m e c a s t a n d y o u r h a i r s o e n d ,s o u n d i n g l i k e 2 0 h o r s e p o w e r d e n t i s t ' s d r i l l . W h e n h e a ri n g a p r i n t e r d e m o n s t r a t e d i s t o r e , a s y o u r s e l f i t h s a m e n o i s e l e v e l w i l l b a c c e p t a b l e i i t ' s i n t e n d e d e n v i r o nm e n t .

D u r a b i l i t y / p o r t a b i l i t y

F o h o m e u s e , y o m a n o n e e d a n i n d e s t r u c t i b l e p r i n t e r ,b u i i t ' s g o i n g t f i n d u s i a o f f i c e o c l a s s r o o m , y o n e e d s o m e t h i n g b i g , h e a v y a n i n t i m i d a t i n g s o t h a t p e o p l ew o n ' t d e s t r o y i t I m i g h t b e w o r t h s p e n d i n g m o r e f o

s o m e t h i n g w i t h b i o e x t r a a r m o u r - p l a t i n g . A l t e r n a t i v e l y ,i y o u ' r e g o i n g t b m o v i n g i a r o u n d l o t , y o m i g h t w a n ts o m e t h i n g p o r t a b l e , o r a l e a s t b r i e f c a s e - a b l e . S o m ep r i n t e r s w i l l o p e r a t e f r o m b a t t e r i e s , s t h a t y o c a u s t h e m w i t h p o r t a b l e c o m p u t e r .

P r i n t F e a t u r e s

b i d i r e c t i o n a l / l o g i c s e e k i n g

B i d i r e c t i o n a l m e a n s t h a t t h p r i n t h e a d p r i n t s l i n e i b o t hd i r e c t i o n s f r o m l e f t t r i g h t , a n d o n i t r e t u r n p a t h t o w a r d st h f i r s t c o l u m n . T h i s s p e e d s t h i n g s u c o n s i d e r a b l y .

L o g i c - s e e k i n g i a n o t h e r t i m e - s a v e r . L o g i c s e e k i n g m e a n st h a t t h p r i n t h e a d o n l y m o v e s t w h e r e t e x t i t p r i n t e dn o n e c e s s a r i l y t h b e g i n n i n g o t h l i n e , a n i s t o p s w h e r et h t e x t e n d s a t h e n o t h l i n e . W h e n c o n s i d e r i n g t h s p e e d o p r i n t e r , t a k e i n t o a c c o u n t w h e t h e r i t ' s b i d i r e ct i o n a l a n d / o r l o g i c - s e e k i n g ( e v e r y p e r s o n w i t h l o g i c -s e e k i n g h e a d s h o u l d d s o ) .

b u f f e r

S o m e p r i n t e r s h a v e b u i l t i " b u f f e r " t s t o r e t e x t t e m p o r a ri l b e f o r e i t ' s p r i n t e d , f r e e i n g u t h c o m p u t e r f o t h l e n g t h y p r i n t p r o c e s s . W i t h l a r g e e n o u g h b u f f e r , y o c o u l ds e n d d o c u m e n t t t h e p r i n t e r a n r e g a i n c o n t r o l o y o u rc o m p u t e r a l m o s t i m m e d i a t e l y , w h i l e t h b u f f e r ' s c o n t e n t sa r p r i n t e d . P r i n t e r s c o m e w i t h b u f f e r s i z e s v a r y i n g f r o m 8 c h a r a c t e r s ( o n e l i n e ) t u t 8 K a n d s o m e t i m e s l a r g e rb u f f e r i a v a i l a b l e a a o p t i o n .

t r u e d e s c e n d e r s

T h i s d o e s n ' t a p p l y t d a i s y w h e e l p r i n t e r s , a n a l b u s o m eo t h c h e a p e s t m a t r i x p r i n t e r s h a v e t r u e d e s c e n d e r s t o d a y .D e s c e n d e r s a r e t h e b o t t o m p a r t o s o m e l o w e r c a s e l e t t e r s ,l i k e t h t a i l i n " y " . T r u e d e s c e n d e r s s h o u l d e x t e n d b e l o w t h b o t t o m o t h l i n e , o e l s e t h l e t t e r l o o k s q u i t e s i l l y . M o s tm o d e r n m a t r i x p r i n t e r s h a v e s o l v e d t h p r o b l e m b u s i n gm o r e p r i n t h a m m e r s , b u c h e c k p r i n t s a m p l e b e f o r e y o b u t m a k e s u r e t h o s e l i t t l e t a i l s h a n g d o w n n i c e a n l o w .

t y p e f a c e s

W i t h m a t r i x p r i n t e r s , t h e a v a i l a b l e t y p e f a c e s i a i m p o r t a n tb u o f t e n o v e r l o o k e d f e a t u r e . Y o u ' l l p r o b a b l y w a n t i t a l i c s ,a n s o m e s p e c i a l g r a p h i c s s y m b o l s t h a t y o c a u s f o d r a w i n g b o x e s , d i f f e r e n t t h i c k n e s s e s o f v e r t i c a l a n h o r iz o n t a l l i n e s , s o l i d b l o c k s , e t c . S o m e p r i n t e r s a l s o h a v e a l k i n d s o g r e e k s y m b o l s ( p i , o m e g a , m u , e t c . ) w h i c h a r u s e f u l i m a t h e m a t i c a l o r e l e c t r o n i c a l l y - o r i e n t e d d o c um e n t s . D a i s y w h e e l p r i n t e r s h a v e t h c a p a b i l i t y o c h a n g i n ga e n t i r e t y p e f a c e s i m p l y b y c h a n g i n g t h e d a i s y w h e e l i t s e l f .S o m e d a i s y w h e e l s h a v e m o r e c h a r a c t e r s t h a n o t h e r sg i v i n g y o a g r e a t e r s e l e c t i o n w i t h o u t c h a n g i n g w h e e l s .

_ T h T r a n s a c t o r 6 V o l u m e 5 I s s u e 0

Page 63: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 63/88

W i t h a n p r i n t e r o t h e r t h a n a d a i s y w h e e l , t h e a v a i l a b l et y p e f a c e s a r e f u n c t i o n o t h s o f t w a r e ( f i r m w a r e , a c t u a l l y )i n s i d e t h p r i n t e r . A g a i n , s e e p r i n t s a m p l e o a l a v a i l a b l ec h a r a c t e r s a n s e i t h e p r i n t e r h a w h a t y o u w a n t .

U s e r - d e f i n a b l e c h a r a c t e r s

T e x t e n d t h e a v a i l a b l e t y p e f a c e s t o s u i t y o u r o w n e e d s ,s o m e p r i n t e r s o t h m a t r i x v a r i e t y a l l o w u s e r - d e f i n a b l et y p e f a c e s . T h a t m e a n s t h a t y o c a d e s i g n a c h a r a c t e r s e t ,m u c h a y o c a i y o u r C 6 4 , a n u s t h a t c u s t o m s e f o f u t u r e p r i n t i n g . Y o c o u l d u s e t h i s f e a t u r e t d e f i n e C o m m od o r e g r a p h i c s s y m b o l s i n o n - C o m m o d o r e p r i n t e r .

g r a p h i c s

I y o u ' r e g e t t i n g m a t r i x p r i n t e r o a n t y p e , y o m i g h t a w e l l h a v e o n t h a t c a d h i g h r e s o l u t i o n g r a p h i c s p r i n to u t s . Y o c a t h e n u s e y o u r p r i n t e r a s p l o t t e r f o d r a w i n gc h a r t s , g r a p h s , o f u n c t i o n p l o t s . Y o c a a l s o u s g r a p h i c sp r o g r a m o s o m e s o r t t c o m p o s e p o s t e r s , w h i c h c a n b ep r i n t e d o u t a n u s e d f o a d v e r t i s i n g o r p r e s e n t a t i o n s . O c o u r s e , i t ' s a l s o n e a t t h a v e j u s t f o r f u n , a n t i m p r e s s y o u rf r i e n d s a n n e i g h b o u r s .

P r i n t e r s m a h a v e m o r e t h a n o n g r a p h i c s m o d e , o f f e r i n gv a r y i n g r e s o l u t i o n ( m o r e d o t s a c r o s s ) .

c o l o u r

A n o t h e r n i f t y a n w o n d e r f u l f e a t u r e , f o u n d o f e w i m p a c td o t - m a t r i x , t h e r m a l t r a n s f e r , a n i n k - j e t p r i n t e r s . C h a r a ct e r s m a b p r i n t e d i o n o f e c o l o u r s ( w i t h i m p a c t d o t -m a t r i x , m a d e p o s s i b l e b m u l t i - c o l o u r r i b b o n a o t y p e w r i t e r ) . C o m b i n e d w i t h g r a p h i c s , t h e p r i n t e r b e c o m e sp r o f i c i e n t p i c t u r e d r a w i n g t o o l w h i c h m a o m a n o b w h a t y o u w a n t i f o r .

p r o p o r t i o n a l s p a c i n g

T h i s d e s e r v e s i t o w c a t a g o r y , b e c a u s e o a d a i s y w h e e lp r i n t e r t h i s f e a t u r e w i l l a l l o w y o t p r o d u c e d o c u m e n t s o t y p e s e t q u a l i t y ( l i k e y o u ' r e r e a d i n g h e r e ) . P r o p o r t i o n a l s p a ci n a c k n o w l e d g e s t h f a c t t h a t c h a r a c t e r s h a v e d i f f e r e n tw i d t h s , a n m o v e s t h p r i n t h e a d a c c o r d i n g l y . I y o w a n t t u s p r i n t e r t p r o d u c e p e r f e c t l o o k i n g d o c u m e n t s , w o r t h yo a p p e a r i n g i n p r i n t , c o n s i d e r p r o p o r t i o n a l s p a c i n g .

" c o r r e s p o n d e n c e q u a l i t y " p r i n t m o d e

T h i s a p p l i e s t m a t r i x p r i n t e r s , a n g i v e s m o r e f u l l y f o r m e dc h a r a c t e r s b u s i n g m o r e d o t s . S e l e c t i n g t h i s m o d e s l o w sd o w n p r i n t s p e e d c o n s i d e r a b l y ( a n d e a t s r i b b o n s f a s t e r ) , b u c a n b e u s e d t p r i n t t h e f i n a l c o p y o i m p o r t a n t d o c u m e n t s ,w h i l e u s i n g t h e r e g u l a r f a s t p r i n t m o d e f o r o u g h d r a f t s .g o o d f e a t u r e t h a v e i y o u w a n t t u s y o u r m a t r i x p r i n t e rf o c o r r e s p o n d e n c e . I t ' s k n o w n a " e n h a n c e d m o d e " o s o m e p r i n t e r s .

o t h e r f e a t u r e s

T h e r e a r m a n y t h i n g s t h a t p r i n t e r c a d f o y o u , a n y o s h o u l d k n o w w h a t y o u n e e d a n d w h a t t h p r i n t e r c a d b e f o r e y o b u y . f e o t h e s e f e a t u r e s a r e : S u p e r s c r i p t s a n s u b s c r i p t s , b o l d f a c e , u n d e r l i n i n g ( p r o p e r u n d e r l i n i n g u d e r l i n e s s p a c e s a w e l l a s l e t t e r s ) , t a s t o p s , a n f o r m a t t i n g .C o m m o d o r e p r i n t e r s h a v e e x c e p t i o n a l l y g o o d f o r m a t t i n gc a p a b i l i t i e s , w h i c h m a k e s i e a s y t p r i n t c o l u m n o f i g u r e sn e a t l y . E v e r y p r i n t e r h a i t o w l i s t o u n i q u e f e a t u r e s , a n y o u ' l l h a v e t s e e t h e p r i n t e r m a n u a l t d i s c o v e r t h e m a l l .

O p e r a t i n g C o s t a n M a i n t e n a n c e

W i t h i m p a c t t y p e p r i n t e r s , t h o p e r a t i n g c o s t s ( b e s i d e se l e c t r i c i t y o c o u r s e ) c o m e f r o m t h c o n t i n u o u s u s o p a p e ra n r i b b o n s . R i b b o n s c o m e i t w f l a v o u r s : t h e c a r t r i d g et y p e , a n t h o p e n t y p e . C a r t r i d g e r i b b o n s a r v e r y e a s y t r e p l a c e : j u s t s n a p t h e o l d o n o u a n t h n e o n i n T h e ya r a l s o m u c h m o r e e x p e n s i v e t h a n t h o p e n t y p e w r i t e rs t y l e r i b b o n . C h e c k t h e r i b b o n t y p e w h e n b u y i n g ; i t ' s c a s eo p r e f e r e n c e - p e r s o n a l l y , I ' r a t h e r g e m h a n d s d i r t yo n c e i w h i l e a n s a v e t h m o n e y ( a b o u t $ 2 . 0 0 f o a o p e n t y p e w r i t e r r i b b o n v s $ 1 6 . 0 0 f o c a r t r i d g e ) .

I n k - j e t p r i n t e r s u s r e p l a c e a b l e i n k c a r t r i d g e s , a n a r f a i r l yi n e x p e n s i v e t o p e r a t e . F o e x a m p l e , R a d i o S h a c k ' s C G P -2 2 u s e s a t h r e e c o l o u r c a r t r i d g e w h i c h i g o o d f o c l a i m e d

t m i l l i o n c h a r a c t e r s . C o s t o r e p l a c e m e n t c a r t r i d g e s i a b o u t $ 1 3 . 0 0 h e r e i C a n a d a . I n c i d e n t a l l y , t h i s p r i n t e r h a p a r a l l e l i n t e r f a c e a n c o u l d p r o b a b l y b e u s e d o C o m m od o r e s y s t e m ( c o s t i a r o u n d $ 9 0 0 C a n a d i a n ) .

C o s t o p a p e r i t h s a m e f o a l e x c e p t t h e r m a l p r i n t e r s ,w h i c h u s m o r e e x p e n s i v e h e a t - s e n s i t i v e p a p e r . Y o u ' l ln e e d b o o p a p e r f o y o u r p r i n t e r h e r e ' s l i t t l e a s i d e :W h e n y o u b u y p a p e r f o t r a c t o r - f e e d p r i n t e r , y o u h a v e t g e 9 1 / 2 b 1 i y o u w a n t t h e s h e e t s t b t h e s t a n d a r d

b 1 1 s i z e a f t e r t h e p e r f o r a t e d t r a c t o r f e e d e d g e s a r r e m o v e d .

G o o d L u c k

N o t h a t y o k n o w b i a b o u t p r i n t e r s , d o n ' t g e t o s m u g ;t h i n f o r m a t i o n i c h a n g i n g a l t h t i m e . N e f e a t u r e s ,c a p a b i l i t i e s , a n l o w e r p r i c e s a r c h a n g i n g p r i n t e r t e c h n o lo g ( f o r t h b e t t e r ) t t h p o i n t w h e r e i t ' s h a r d t k e e p u p B u a r m e d w i t h t h i n f o r m a t i o n c o v e r e d h e r e , a n m a y b es o m e t h a t I ' v e l e f t o u t , y o w o n ' t f e e l l o s t i t h w o r l d o t h p r i n t e r w h i c h m a b t h m o s t i m p o r t a n t p e r i p h e r a l i y o u r s y s t e m .

T h T r a n s a c t o r 6 V o l u m e s , I s s u e 0 4

Page 64: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 64/88

E v o l u t i o n O T h C P A n R e v o l u t i o n a r yM e m o r y A d v a n c e m e n t s

H o w a r d R o t e n b e r gT o r o n t o , O n t .

E v o l u t i o n o f T h C P

T h i s s h o u l d t a k e s o m e o y o o l d e r f o l k s b a c k t m e m o r y l a n e ( n o p u i n t e n d e d ) a n g i v e t h y o u n g e r o n e s b i o h i s t o r y . T h i n s t r u c t i o ns e t s o f a l t h e e a r l y c o m p u t e r s c o n t a i n e d f i x e d p o i n t a r i t h m e t i c i n s t r u ct i o n s , b o o l e a n a n s h i f t i n s t r u c t i o n s . T h e r e w a a l s o f e p r i m i t i v ei n s t r u c t i o n s f o c o n t r o l l i n g t h i n s t r u c t i o n s e q u e n c e . T h e n c a m e t h s e c o n d g e n e r a t i o n c o m p u t e r s . T h e s e h a m u c h l a r g e r i n s t r u c t i o n s s e t sa n l o m o r e f l e x i b i l i t y a n p o w e r . B a s i c a l l y t h e s e c o m p u t e r s f e l l i n t ot w c a t e g o r i e s : b u s i n e s s a n s c i e n t i f i c c o m p u t e r s .

T h b u s i n e s s d a t a p r o c e s s i n g c o m p u t e r s w e r e t y p i c a l l y c h a r a c t e ro r i e n t e d a n d h a d a e n o r m o u s c a p a b i l i t y f o m a n i p u l a t i n g v a r i a b l el e n g t h d a t a . T h e s e o p e r a t i o n s w e r e u s u a l l y c h a r a c t e r r e p l a c e m e n t s o c o m p a r i s o n s f o r s o r t i n g , m e r g i n g o f i x e d - p o i n t a r i t h m e t i c . T h a r i t hm e t i c w a g e n e r a l l y s l o w o t h i s t y p e o c o m p u t e r s i n c e i w a u s u a l l yd o n e s e r i a l l y b c h a r a c t e r , a n o f t e n d o n e d e c i m a l l y r a t h e r t h a n i b i n a r y .

T h o t h e r c o m p u t e r s p o k e a b o u t w a t h s c i e n t i f i c c o m p u t e r . A t h o u g h i h a e x t e n s i v e f l o a t i n g - p o i n t a r i t h m e t i c c a p a b i l i t y , i o p e r a t e do d a t a o f i x e d p r e c i s i o n . I t u n l i k e t h b u s i n e s s c o m p u t e r , h a v e r yl i t t l e c a p a b i l i t y f o d e a l i n g w i t h v a r i a b l e l e n g t h s t r i n g s a n d i n o h a v ed e c i m a l a r i t h m e t i c , a l t h o u g h i c o u l d b e p e r f o r m e d t h r o u g h p r o g r a mm i n g a h i g h c o s t o c o m p u t i n g t i m e .

T o w a r d t h e n o t h s e c o n d g e n e r a t i o n , t h d i s t i n c t i o n b e t w e e nb u s i n e s s a n s c i e n t i f i c c o m p u t i n g s t a r t e d t f a d e . L a r g e s c i e n t i f i c u s e r sp e r f o r m e d c o m p u t a t i o n s i n v o l v i n g s o r t i n g , m e r g i n g a n c h a r a c t e rm a n i p u l a t i o n o v a r i a b l e l e n g t h d a t a t h a t w a p r e v i o u s l y c l a s s e d a sb u s i n e s s f u n c t i o n s . W h i l e t h i s w a g o i n g o n m a n y b u s i n e s s a p p l i c at i o n s s t a r t e d t m a k e u s o s o p h i s t i c a t e d f o r e c a s t i n g a n i n v e n t o r yc o n t r o l p r o g r a m s w h i c h r e l i e d o o p e r a t i o n s o f s c i e n t i f i c c o m p u t i n g .T h b e g i n n i n g o t h e 6 0 ' s s a n e b r e e d o c o m p u t e r . T h m a n u f a ct u r e r s s t a r t e d t c o m b i n e b o t h k i n d s o f u n c t i o n s i n t o o n c o m p u t e r .

m a j o r o b s t a c l e i t h w a o h a v i n g s i n g l e g e n e r a l p u r p o s ec o m p u t e r f o b o t h b u s i n e s s a n s c i e n c e w a t h c o s t . A n u m b e r o i n s t r u c t i o n s i c o m p u t e r g r e w , s o d i d t h e c o s t o i t c o n t r o l u n i t w h i c hi t u r n a f f e c t e d t h c o s t o t h m a c h i n e t t h u s e r . B t h e t i m e t h m i d d l e s i x t i e s c a m e a b o u t , n e t e c h n o l o g i e s a n n e d e s i g n t e c hn i q u e s b r o u g h t h a r d w a r e c o s t d o w n d r a m a t i c a l l y . I w a n o p o s s i b l et c o n s t r u c t g e n e r a l p u r p o s e c o m p u t e r t s a t i s f y a l u s e r s .

A c o m p u t e r s m o v e d i n t o t h t h i r d g e n e r a t i o n , i n s t r u c t i o n s w e r e n o d e s i g n e d f o l a r g e v a r i e t y o f u n c t i o n s . T h n u m b e r o e l e m e n t a r yi n s t r u c t i o n s i n c r e a s e d f r o m f e d o z e n i t h e a r l y c o m p u t e r s t o v e r

h u n d r e d , a n i f e i n s t a n c e s t o v e r t w h u n d r e d . A r i t h m e t i ci n s t r u c t i o n s o n l y a c c o u n t e d f o s m a l l p o r t i o n o t h e s e r e p e r t o i r e s . T h n e w e r f u n c t i o n s i n c l u d e d i n s t r u c t i o n s f o s u b r o u t i n e e n t r y a n e x i t ,e n v i r o n m e n t c h a n g i n g , s t a s i s r e c o r d i n g , a n m e m o r y p r o t e c t i o n . E v e nt h l e a s t e x p e n s i v e m i n i c o m p u t e r o t h e a r l y s e v e n t i e s c a n p e r f o r mu p w a r d s o o n e h u n d r e d d i f f e r e n t e l e m e n t a r y i n s t r u c t i o n s .

B t h i s t i m e t h e c o m p u t e r d e s i g n e r s r e c o g n i z e d t h n e e d f o m o d u l a ri t i t h e p h y s i c a l c o n s t r u c t i o n o c o m p u t e r s . I w a o n l y n a t u r a l t h a tt h b a s i c b u i l d i n g b l o c k s t h e y u s e d w e r e n a n d / n o r l o g i c g a t e s a n f l i p /

f l o p s . A t h a t t i m e t h e s e w e r e f a b r i c a t e d f r o m d i s c r e e t r e s i s t e r s , c a p a c it o r s , a n v a c u u m t u b e s . S e c o n d g e n e r a t i o n c o m p u t e r s u s e d t r a n s i s t o r si p l a c e o v a c u u m t u b e s . T h e r e w a s s o m e s i m p l i f i c a t i o n s i t h s t r u c t u r e o t h l o g i c g a t e s b u b a s i c a l l y t h d e s i g n s w e r e s i m i l a r t t h o s e u s e d p r e v i o u s l y . R e g i s t e r s w e r e r e l a t i v e l y e x p e n s i v e d u r i n g t h i st i m e s t h a t m u l t i p l e r e g i s t e r s w e r e f o u n d m a i n l y i h i g h s p e e dc o m p u t e r s w h o s e u s e r s w e r e w i l l i n g t p a p r e m i u m f o s p e e d .

D u r i n g t h e a r l y s i x t i e s s e v e r a l d e v e l o p m e n t s i d e v i c e t e c h n o l o g yl e a d t r e v o l u t i o n c h a n g e s i t h l o g i c d e v i c e s a v a i l a b l e . T h e s ec h a n g e s a l s o l e a d t d r a m a t i c d e c r e a s e s i t h c o s t p e l o g i c f u n c t i o n .T h l o g i c d e v i c e s b t h i s t i m e w e r e f a b r i c a t e d o f l a t f i l m s d e p o s i t e d o

s i l i c o n s u b s t r a t e . T h i s n e s i l i c o n c h i p c o n t a i n e d s e v e r a l a c t i v et r a n s i s t o r s , y e t h c o s t o c h i p f a b r i c a t i o n w a a p p r o x i m a t e l y e q u a l t t h c o s t o f a b r i c a t i n g a s i n g l e t r a n s i s t o r u s i n g p r e v i o u s t e c h n i q u e s .

T h i s n e t e c h n o l o g y h a m a j o r i m p a c t o n c o m p u t e r d e s i g n a n t h e no n c o m p u t e r a r c h i t e c t u r e . T h c o s t s o b a t c h f a b r i c a t e d d e v i c e s c o u l db h e l d l o i m a n y c o p i e s o t h c h i p s w e r e m a d e . F o t h p o r t i o n s o c o m p u t e r s u c h a m e m o r i e s , a r i t h m e t i c u n i t s , a n r e g i s t e r s , t h i s n e t e c h n o l o g y f i w e l l a n a d a p t a t i o n w a r e l a t i v e l y s i m p l e . B u f o t h u n s t r u c t u r e d l o g i c o f t h c o n t r o l u n i t , t h e r e w e r e s i g n i f i c a n t p r o b l e m s .

F r o m t h i s w c a s e t h a t t h n e t e c h n o l o g y i n v a l i d a t e d t h e f o r m e rd e s i g n c r i t e r i a o m i n i m i z i n g t h n u m b e r o l o g i c g a t e s i d e s i g n a n r e p l a c e d i w i t h t h n e e d t m a x i m i z e t h r e p e t a t i v e u s o f u n c t i o n a lc h i p , o t m i n i m i z e t h n u m b e r o i n t e r c o n n e c t i o n s b e t w e e n f u n ct i o n a l p a r t i t i o n s o t h c o n t r o l u n i t . ( B o y t h a t w a m o u t h f u l ) . T h i s n o p r o v i d e d p a r t i a l i m p e t u s f o i m p l e m e n t i n g t h c o n t r o l p o r t i o n o c o m p u t e r w i t h m e m o r y r a t h e r t h a n d i s c r e e t l o g i c t a c h i e v e r e g u l a r i t yo f s t r u c t u r e . T h i s i t u r n c o n t r i b u t e d t t h r i s e o m i c r o p r o g r a m m i n gi t h m i d d l e a n l a t e s i x t i e s .

E v o l u t i o n o M e m o r y

A l o n g w i t h t h e v o l u t i o n a r y c h a n g e s i t h e c e n t r a l p r o c e s s i n g u n i t ,g r e a t a d v a n c e s w e r e a l s o m a d e i m e m o r y a r c h i t e c t u r e . T h l a t e s t a n m o s t r e v o l u t i o n a r y a d v a n c e m e n t i m e m o r y w i l l d i s c u s s t o w a r d s t h e n o f t h i s a r t i c l e . T h e r e a r e t h r e e t y p e s o m e m o r i e s t h a t h a c o m ei n t o p o p u l a r u s e a s p r i m a r y m e m o r y o c o m p u t e r . I t h f i f t i e s , t h p r i m a r y m e m o r i e s w e r e m a i n l y r o t a t i n g d r u m s . T h l a t e f i f t i e s s a t h i n t r o d u c t i o n o s e c o n d g e n e r a t i o n o c o m p u t e r s w i t h m a g n e t i c c o r em e m o r i e s . T h e s e c o m p u t e r s w e r e s u b s t a n t i a l l y f a s t e r t h a n t h e i r p r e d ec e s s o r s b e c a u s e o t h n e r a n d o m a c c e s s c a p a b i l i t y .

T h a t i s a n i t e m c a b f e t c h e d f r o m m e m o r y i f i x e d t i m e s p a n t h a ti i n d e p e n d e n t o t h e p r e v i o u s m e m o r y r e f e r e n c e . M a g n e t i c d r u m s h a w h a t w c o u l d c a l l a i n h e r e n t r o t a t i o n a l l a t e n c y . W h a t m e a n b t h i si t h a t i t h i t e m t b a c c e s s e d w a n o u n d e r t h e r e a d h e a d o d r u ma t h e p r e c i s e t i m e t h a c c e s s r e q u e s t w a i s s u e d , t h e n t h e r e q u e s tc o u l d n o b g r a n t e d u n t i l t h i t e m e v e n t u a l l y r e a c h e d t h r e a d h e a d .D u r i n g t h i s t i m e t h e c o m p u t e r r e m a i n e d i d l e u n t i l t h e a c c e s s o c c u r r e d .

T h t h i r d a n m o s t p o p u l a r m e m o r y t h a t w a i n t r o d u c e d w a t h i n t e g r a t e d c i r c u i t m e m o r y . L i k e t h m a g n e t i c c o r e m e m o r i e s , t h i n t e g r a t e d m e m o r i e s a r r a n d o m a c c e s s . T h e y w e r e m u c h f a s t e rh o w e v e r a n d w i t h t h n e t e c h n i q u e s a v a i l a b l e f o t h m a k i n g o t h e s e

T h T r a n s a c t o r 6 V o l u m e 5 I s s u e 0

Page 65: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 65/88

c h i p s , e v e n c h e a p e r . I n t e g r a t e d c i r c u i t s a r t h m o s t p o p u l a r t y p e o m e m o r y u s e d t h e s e d a y s a n p r e t t y w e l l t h o n l y k i n d f o u n d i t o d a y sm i c r o s .

T h o r g a n i z a t i o n o p r i m a r y m e m o r y t o d a y i e s s e n t i a l l y j u s t a t h e a r l y d e s i g n e r s e n v i s i o n e d i t b e I t e m s h a v e u n i q u e p h y s i c a l a d r e s s e s , a n a c c e s s e s a r m a d e b a d d r e s s . T h a d v a n c e s t h a t w e r em a d e i m e m o r y a r c h i t e c t u r e f e l l p r i m a r i l y i t w r e l a t e d a r e a s :

1 M e m o r y h i e r a r c h i e s c o n s i s t i n g o h i g h s p e e d f i r s t l e v e l s t o r a g et o g e t h e r w i t h m u c h l a r g e r a n s l o w e r s e c o n d l e v e l a n p o s s i b l y ,t h i r d l e v e l s t o r a g e , a p p e a r t t h p r o g r a m a s a s i n g l e l a r g e m e m o r yw h o s e s p e e d i n e a r l y e q u a l t f i r s t l e v e l s t o r a g e , ( w o w t h a t w a a n o t h e r m o u t h f u l ) . W w o u l d t e n d t s e t h a t f r e q u e n t l y u s e d i t e m st e n d t r e s i d e i t h f a s t e s t m e m o r y o t h h i e r a r c h y a n a u t o m a t ic a l l y d r i f t t t h s l o w e r p a r t s o t h h i e r a r c h y w h e n f r e q u e n c y o u s d i m i n i s h e s .

T h s e c o n d f e e l i m o r e i m p o r t a n t a d v a n c e m e n t .

2 S e v e r a l i n d e p e n d e n t p r o g r a m s c a n r u n i t h s a m e c o m p u t e r s y s t e ms i m u l t a n e o u s l y , e a c h u s i n g c o m p l e t e l y s e p a r a t e s e t o f m e m o r yl o c a t i o n s . M e m o r y a d d r e s s t r a n s l a t i o n f a c i l i t i e s s i m p l i f y t h e p r o b l e mo a l l o c a t i n g m e m o r y t t h i n d i v i d u a l p r o g r a m s , a n g u a r a n t e e t h a to n p r o g r a m c a n n o t i n t e r f e r e w i t h a n o t h e r p r o g r a m . I s o m e i s t a n c e s , s p e c i f i e d d a t a o r p r o g r a m s e g m e n t s a r p e r m i t t e d t b s h a r e d b y t w o o m o r e p r o g r a m s .

w i l l n o g i n t o a n m o r e d e t a i l a b o u t t h e s e t o p i c s o t h e r t h a n t m e n t i o n t h a t t h f i r s t o t h t w i c a l l e d v i r t u a l m e m o r y o c a c h em e m o r y . T h e s e c o n d d e s c r i b e s s i t u a t i o n k n o w n a m u l t i p r o g r a mm i n g a n a d d r e s s t r a n s l a t i o n f a c i l i t i e s a r e e s s e n t i a l f o i t s u p p o r t .

G l i m p s e o T h F u t u r e

T h e r e i m a n w h o i p r e s e n t l y s e n i o r r e s e a r c h o f f i c e r i t h E l e c t r i c a l E n g i n e e r i n g D i v i s i o n o f t h e N a t i o n a l R e s e a r c h C o u n c i l i O t t a w a t h a t h a c o m e u w i t h a n a s t o u n d i n g d i s c o v e r y . H i s n a m e i A l e x S z a b o a n d h u n b e l i e v a b l y h a f o u n d w a t p a c k m o r ei n f o r m a t i o n i n t o c o m p u t e r m e m o r y t h a n h u m a n b r a i n c o u l d h o l di t h s a m e a m o u n t o s p a c e .

A h a v e m e n t i o n e d e a r l i e r , f o r y e a r s d a t a h a b e e n s t o r e d o d i s c s ,t a p e a n m o r e r e c e n t l y b u b b l e m e m o r y . N o t h i s m a h a a d d e d t h c o n c e p t o t h c r y s t a l m e m o r y . T h p o t e n t i a l o f t h i s d i s c o v e r y i o v e r w h e l m i n g . H i i d e a w a o r i g i n a l l y c o n c e i v e d i t h e a r l y 7 0 ' s .

T b r i e f l y r e m i n d a l h o d a t a i s t o r e d , i i e s s e n t i a l l y o n o t w k i n d so s i g n a l s o s t a t e s . T h i s i o o o f f , w h e t h e r t h d a t a i o t a p e , d i s k o ri o t h e r t y p e s o m e m o r y . F o i n s t a n c e , e i g h t b i t s m a b s t o r e d i c e r t a i n s e q u e n c e t r e p r e s e n t a p a r t i c u l a r c h a r a c t e r . S z a b o ' s i d e a i q u i t e d i f f e r e n t i t h a t i t a k e s c r y s t a l i n e m a t e r i a l w h i c h l i g h t n o r m a l l yc a n ' t g e t t h r o u g h , a n m a k e s i t r a n s p a r e n t t c e r t a i n c o l o u r s o l i g h t i ns p e c i f i c s p o t s .

T h f i r s t m a t e r i a l h e u s e d w a r u b y , s i n c e w h i l e a r u b y c o u l d h o l db a c k m o s t l i g h t b u t n o t t h i n l a s e r b e a m . T h e r e a r l o o o t h e rc r y s t a l s i n t h i s c a t e g o r y a l s o t h a t a r e v e n b e t t e r . H h a f o u n d o u t h a ty o c o u l d p a s s a t h i n l a s e r b e a m t h r o u g h t h i n s l a b o m a t e r i a l a n p e n e t r a t e i t T h p e n e t r a t i o n w o u l d l e a v e t i n y t u b e l i k e s e c t i o nt r a n s p a r e n t e x a c t l y t h s i z e o f t h l a s e r b e a m . T h i s t u b e w a n o c l e a rw h i l e t h r e s t o t h c r y s t a l w a s t i l l i m p e n e t r a b l e t l i g h t . T h e s e b e a m sc a b f o c u s e d d o w n t t h i c k n e s s o l e s s t h a n 1 0 , 0 0 0 o c e n t i m e t r e . T h i s i t h k e t t h i s f a n t a s t i c c a p a b i l i t y : T h i s m a f o u n do u t h a t t h t i n y t r a c k t h a t h a d b e e n l e f t t r a n s p a r e n t w o u l d o n l y p a s st h s a m e c o l o u r o f l i g h t a s t h e c o l o u r o t h o r i g i n a l l a s e r b e a m t h a tp e n e t r a t e d i t I t h l a s e r w a g r e e n a n d y o u p a s s e d g r e e n l i g h t o v e r

t h c r y s t a l , y o u w o u l d o n l y s e e o n d o o g r e e n l i g h t a c t u a l l y p a s s i n gt h r o u g h . I y o p a s s e d r e l a s e r b e a m t h r o u g h t h c r y s t a l t h s a m ee f f e c t w o u l d b e v i d e n t . T h l a s t t h i n g t h a t S z a b o f o u n d o u w a t h a t i y o p a s s e d b o t h r e a n g r e e n l a s e r b e a m t h r o u g h t h s a m e s p o t , i w o u l d b t r a n s p a r e n t t r e a n g r e e n b o t h b u s t i l l b l o c k a l o t h e rc o l o u r s . T h n e x t a m a z i n g t h i n g t h a t s h o u l d b e m e n t i o n e d h e r e i t h a t ,t h e o r e t i c a l l y , l a s e r s c o u l d d i s t i n g u i s h b e t w e e n 1 0 m i l l i o n s h a d e s . T h e yc a n b e t u n e d v e r y p r e c i s e l y t t h e s e s h a d e s o c o l o u r a l s o .

T h N e x t S t e pS z a b o r e a s o n e d t h a t h c o u l d a r r a n g e a p a t t e r n o s p o t s o a s l a b o c r y s t a l a n s h i n e r e l a s e r b e a m s o s o m e o t h o s e s p o t s b u n o o o t h e r s . H c o u l d t h e n a r r a n g e t i n y l i g h t s e n s o r s i a i d e n t i c a l p a t t e r no a n o t h e r s u r f a c e u n d e r n e a t h . N o i h s h o n e f l o o d l i g h t o t h s a m e r e c o l o u r o t o o t h c r y s t a l t h l i g h t w o u l d g e t h r o u g h o n l yt h s p o t s t h a t h a d b e e n p e n e t r a t e d e a r l i e r . T h i s w o u l d a c t i v a t e t h e l i g h ts e n s o r s b e n e a t h t h o s e s p o t s b u t l e a v e a l t h e o t h e r s e n s o r s d a r k a n i n e r t . T h i s a r r a n g e m e n t c o u l d b e u s e d a s m e m o r y c e l l . c o m p u t e rc o u l d g e d i g i t a l o s i g n a l s f r o m t h e s e n s o r s w h i c h g o l i g h t , a n o f s i g n a l s f r o m t h o n t h a t s t a y e d d a r k .

T h i s w a v e r y i m p r e s s i v e i d e a f o d a t a s t o r a g e , b e c a u s e l a s e r b e a m sc a n b e m a d e s o t h i n t h a t c o u l d b d i r e c t e d a h u n d r e d m i l l i o nd i f f e r e n t s p o t s , w i t h o u t o v e r l a p p i n g , o s l a b o c r y s t a l o n l y o n c e n t i m e t r e s q u a r e . T h i s w o u l d b a b o u t t h s i z e o f h u m a n f i n g e r n a i l .H i i d e a w e n t f a b e y o n d t h i s . I y o p e n e t r a t e d c r y s t a l b r e l a s e rb e a m s i o n a r r a y o s p o t s , t h a t w o u l d s t o r e d a t a w h i c h c o u l d t h e n b r e a d b a c k b y s i m p l y s h i n n i n g a r e d l i g h t o t h s l a b a l a t e r t i m e . I t h s a m e c r y s t a l w a t h e n p e n e t r a t e d b y g r e e n l a s e r b e a m s i a n o t h e ra r r a n g e m e n t o s p o t s , i w o u l d s t o r e s e p a r a t e h u n d r e d m i l l i o n b i t s o fd a t a , w h i c h c o u l d b r e a d b a c k l a t e r b s h i n n i n g g r e e n l i g h t o i t I a l p r a c t i c a l i t y p r o b a b l y o n l y o n e t h o u s a n d s h a d e s o l a s e r s w o u l d b u s e d b e c a u s e t o d a y ' s e q u i p m e n t c a t e l l t h a t m a n y a p a r t v e r y q u i c k l y .T h i s w o u l d m e a n t h a t f i n g e r n a i l s i z e s l a b o f c r y s t a l c o u l d b e u s e d t s t o r e u t o n m i l l i o n b i t s o d a t a i e a c h o o n t h o u s a n d d i f f e r e n tl a s e r c o l o u r s . W a r n o t a l k i n g a b o u t t h s t o r a g e o o n h u n d r e db i l l i o n b i t s o d a t a i a f i n g e r n a i l s p a c e .

W i t h t h i s p r i n c i p a l i m i n d , i c r y s t a l t h s i z e o f h i - f i m u s i c a l b u m ,i w o u l d b p o s s i b l e , t h e o r e t i c a l l y t s t o r e a s m a n y b i t s o d a t a a t h e r ea r n e u r o n s i t h a v e r a g e a d u l t h u m a n b r a i n . F r o m t h i s w c a s t a r tt s e t h e n o r m o u s c a p a b i l i t i e s t h a t c o u l d c o m e f r o m t h i s r e v o l u t i o na r t y p e o m e m o r y . T h e r e a r s o m e p r o b l e m s t c o p e w i t h h e r e , a s i d ef r o m f i g u r i n g h o t f i h u n d r e d m i l l i o n l i g h t s e n s o r s i n t o s q u a r et h s i z e o f i n g e r n a i l . T u s a n c r y s t a l m a t e r i a l t h i s w a y , i i a b s o l u t e l y n e c e s s a r y t k e e p i e x t r e m e l y c o l d . T b l i t t l e m o r ep r e c i s e , t h t e m p e r a t u r e o l i q u i d h e l i u m , 2 6 d e g r e e s b e l o w z e r oc e l s i u s i g o o d . T h h o t t e s t a l l o w a b l e t e m p e r a t u r e w o u l d b a p p r o x im a t e l y 2 5 b e l o w .

T h r e a s o n f o t h e s e l o t e m p e r a t u r e s i t s l o w t h m o t i o n o t h m o l e c u l e s i t h c r y s t a l a l m o s t t z e r o - t o k e e p t h e m f r o z e n s t i f f . I t h m o l e c u l e s w e r e t m o v e a m u c h a t h e y d a h i g h e r t e m p e r a t u r e s ,t h e m a t e r i a l w o u l d l o s e i t c o l o u r s t a b i l i t y a n t h l a s e r h o l e s c o u l d n l o n g e r c o n t r o l t h e p r e c i s e s h a d e s t h e y w e r e m a d e f o r . T k e e p s u c hf r i g i d l e v e l h i g h p o w e r c o o l i n g s y s t e m s w o u l d b n e e d e d . U n f o r t un a t e l y , a t t h i s t i m e t h a t w o u l d m e a n c r y s t a l m e m o r i e s w o u l d b p r a c t i c a l o n l y f o b i c o m p u t e r s t h a t s t a y i o n p l a c e . W w o u l d n ' t s e t h e m f o d e s k t o p o r p o r t a b l e m o d e l s f o a l o n g t i m e .

C o n c l u s i o n

h o p e t h a t t h i s a r t i c l e h a g i v e n s o m e i n s i g h t i n t o t h e a r c h i t e c t u r e a n f u n c t i o n a l i t y o t h C P a n n e a d v a n c e m e n t s t h a t a r b e i n g m a d e i m e m o r y . I r e m i n d s m o t h s h o w y o m a b f a m i l i a r w i t h : W H A TW I L L T H E Y T H I N K O N E X T .

T h T r a n s a c t o r 6

Page 66: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 66/88

M o d i f y i n g t h V I C - 2 03 R A P a c kF o U s e W i t h E P R O M s

T h o m a s H e n r yM a n k a t o , M

A e a s y w a t a d E P R O M s t y o u r V I C !

I y o e v e r o p e n u y o u r 3 R A P a c k f o t h V I C - 2 0 , y o u ' l l b i f o a p l e a s a n t s u r p r i s e . B e s i d e s t h 3 o R A c h i p s , y o w i l l f i n dr o o m o t h c i r c u i t b o a r d f o t w 2 p i E P R O M ' s ! I s o m e c a s e sa l y o w i l l h a v e t d t u s t h e s e s l o t s i t h r o w i c o u p l e o i n t e g r a t e d c i r c u i t s o c k e t s a n a w a y y o u g o T h i s a r t i c l e e x p l o r e st h w o r k i n g s o t h 3 c a r t r i d g e a n s h o w s s e v e r a l w a y s t e m p l o yt h e x t r a E P R O M s p a c e .

A l y o u ' l l n e e d , b e s i d e s t h e 3 R A p a c k , i s

t w 2 p i I C s o c k e t s ,t w . 0 m f d . d i s k c a p a c i t o r s ,a n 7 4 L S 0 0 q u a d N A N D g a t e

( T h i s s h o u l d c o s t y o l e s s t h a n c h e a p l u n c h a t h l o c a l g r e a s ys p o o n . )

B u f i r s t , w a r n i n g . A n t i m e y o s t a r t f i d d l i n g w i t h t h e h a r d w a r eo y o u r c o m p u t e r y o u e x p o s e y o u r s e l f t s e v e r a l d a n g e r s . F i r s t ,y o w i l l v o i d a n w a r r a n t y t h a t c a m e w i t h y o u r s y s t e m . T h i s m a o m a n o b o t h e r y o u , d e p e n d i n g o y o u r o u t l o o k t o w a r d sw a r r a n t i e s . M o r e i m p o r t a n t l y , t h o b j e c t o p e r f o r m i n g a n h a r dw a r e m o d i f i c a t i o n i t i m p r o v e t h e s y s t e m , b u i y o a r e n ' tc a r e f u l , y o m a e n u d e s t r o y i n g s o m e v a l u a b l e e q u i p m e n t !T h g e n e r a l r u l e , t h e n , i i y o d o n ' t u n d e r s t a n d w h a t y o u a r d o i n g , d o n ' t d i t H i r e s o m e o n e m o r e s k i l l e d i e l e c t r o n i c s t p e r f o r m t h n e e d e d c h a n g e s .

H a v i n g p o s s i b l y s c a r e d y o u , l e i q u i c k l y b n o t e d t h a t t h m o d i f i c a t i o n s t t h 3 R A P a c k d e s c r i b e d i t h i s a r t i c l e a r a c t u a l l y q u i t e e a s y t p e r f o r m a n a l o n g a g o o d s h o p p r a c t i c e sa r u t i l i z e d , y o s h o u l d e n c o u n t e r n t r o u b l e . A n o u t s t a n d i n gt r i c k y p o i n t s w i l l b m e n t i o n e d a l o n g t h w a y .

W i t h a l o t h c a v e a t s b e h i n d u n o w , l e t ' s e x a m i n e t h e c a r t r i d g ea n s e w h a t c a b d o n e w i t h i t Y o u r f i r s t m o v e s h o u l d b t o p e n u t h e c a r t r i d g e a n d s p e n d s o m e t i m e s i m p l y l o o k i n g a i t T h e r e i o n s c r e w w h i c h h o l d s t h c a r t r i d g e t o g e t h e r , a n t h i s i f o u n d i t h m i d d l e o t h e b a c k . R e m o v e t h i s s c r e w . N e x t i n s e r tt h e b l a d e o s m a l l s c r e w d r i v e r i n t o o n o t h t w s l o t s f o u n da l o n g t h b a c k e d g e . C a r e f u l l y p u s h t h e i n t e r l o c k i n g t a b o u o t h w a a n p u l l t h b a c k u s l i g h t l y . N o r e p e a t w i t h t h o t h e r s l o t . I a l h a g o n e w e l l , t h b a c k o t h 3 c a r t r i d g e c a n o b l i f t e d o f f .

H o l d i n g t h c i r c u i t b o a r d t h u s r e m o v e d , w i t h t h e d g e c o n n e c t o rf i n g e r s d o w n w a r d , l o o k f o t h s i R A c h i p s o f t t h l e f t . N o l o o k f o t h t w e m p t y E P R O M l o c a t i o n s o t h r i g h t s i d e . F i n a l l y ,

l o c a t e t h e i g h t c i r c u l a r " s e l e c t p a d s " b e t w e e n t h R A a n E P R O M a r e a a n t o w a r d s t h b o t t o m o t h e b o a r d . F i g u r e O n s h o w s h o t h s e l e c t p a d s s h o u l d a p p e a r i a s t o c k 3 c a r t r i d g e .

W h a t a r t h e s e p a d s ? S i m p l y p u t , t h s e l e c t p a d s a l l o w y o t c h a n g e t h d e c o d i n g o t h E P R O M c h i p s a n f u r t h e r m o r e m a k et h u s o t h r e e d i f f e r e n t t y p e s o c h i p s p o s s i b l e . E a c h s e l e c t p a i c o m p o s e d o t w s e m i - c i r c u l a r r e g i o n s . S o m e o t h e s e p a i r s ( t h eo n e s l a b e l l e d 1 5 1 a n 1 2 h a v e a p r i n t e d c i r c u i t b o a r d t r a c ec o n n e c t i n g t h t w h a l v e s . T h o t h e r o n e s a r e l e c t r i c a l l y d i s t i n c t .B c u t t i n g t h e t r a c e s o b r i d g i n g t h d i s t i n c t p a i r s w i t h s o l d e r , i i p o s s i b l e t c o n f i g u r e t h E P R O M d e c o d i n g f o a v a r i e t y o u s e s .L e t ' s g e m o r e s p e c i f i c .

S e l e c t p a d s a n g o v e r n h o t h u p p e r r i g h t h a n d E P R O M c h i pi t b e d e c o d e d . S i n c e t h e p r i n t e d c i r c u i t b o a r d c o m e s w i t h s e l e c tp a b r i d g e d a n s e l e c t p a b r o k e n , t h c h i p w i l l b d e c o d e d b B l o c k 5 o i o t h e r w o r d s b y a n y a d d r e s s b e t w e e n $ A 0 0 0 a n $ B F F F . B b r e a k i n g s e l e c t p a ( c u t t h t r a c e w i t h r a z o r k n i f e )a n m a k i n g s e l e c t p a ( b r i d g e t h e t w s e m i - c i r c l e s w i t h d o o s o l d e r ) y o c a c h a n g e t h d e c o d i n g s t h a t t h c h i p i n o a d d r e s s e d b B l o c k ( $ 4 0 0 0 t $ 5 F F F ) . N o t e t h a t o n l y o n o t h t w p a d s ( o 2 s h o u l d b b r i d g e d a t i m e .

I s i m i l a r m a n n e r , s e l e c t p a d s a n g o v e r n h o t h E P R O M i t h l o w e r r i g h t h a n d s i d e o t h b o a r d w i l l b a d d r e s s e d . I p a i b r i d g e d , t h e n t h c h i p w i l l b a d d r e s s e d b B l o c k ( $ 2 0 0 0 t $ 3 F F F ) ; i p a i b r i d g e d , t h e n B l o c k d o e s t h t r i c k ( $ 6 0 0 0 t $ 7 F F F ) . T h u s b m a k i n g o b r e a k i n g s e l e c t p a d s 1 2 3 o i i p o s s i b l e t l o c a t e E P R O M i a n a r e a b e t w e e n $ 2 0 0 0 t $ 7 F F F a n $ A 0 0 0 t $ B F F F . T h a t ' s q u i t e a b i o f v e r s a t i l i t y ! ( I n c i d e n t a l l y ,a d d r e s s e s $ 8 0 0 0 t $ 9 F F F a r r e s e r v e d b t h V I C - 2 0 f o c h a r a c t e rs e t s a n I / O ) .

B u t h e r e ' s m o r e t c o m e ! L o o k a g a i n a y o u r e x p o s e d c i r c u i t b o a r do F i g u r e O n a n d y o u w i l l s e f o u r m o r e p a d s t h a t h a v e n ' t b e e nm e n t i o n e d y e t . T w o t h p a d s a r e a s s o c i a t e d w i t h t h n u m b e r 1 a n t w w i t h t h e n u m b e r 1 2 . C a l l t h e s e 1 1 - u p p e r , 1 1 - l o w e r , 1 2 u p p e r a n 1 2 - l o w e r . B m a k i n g o b r e a k i n g v a r i o u s c o m b i n a t i o n so t h e s e s e l e c t p a d s i i p o s s i b l e t s e t h 3 R A p a c k u t u s a n y o n e o t h r e e t y p e s o E P R O M . T h e s e a r e t h e 2 7 1 6 ( 2 K ) , t h 2 5 3 2 ( 4 K ) a n t h 2 5 6 4 ( 8 K ) .

F i g u r e T w s h o w s t h c o m b i n a t i o n s o p a d s n e e d e d t a c c o m o d a t ee a c h o t h t h r e e t y p e s o E P R O M u s e a b l e w i t h t h i s c a r t r i d g e . O n i m p o r t a n t p o i n t t n o t i c e i t h a t t h 2 7 3 2 ( a l s o 4 E P R O M ) m a yn o b e u s e d w i t h t h i s s e t u p . T h p i n o u t i j u s t s u f f i c i e n t l y d i f f e r e n t

T h T r a n s a c t o r 6 V o l u m e 5 I s s u e 0

Page 67: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 67/88

Page 68: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 68/88

j u s t a e a s i l y t a p p e d o f o f d i s k c a p a c i t o r l e a d r i g h t n e x t t p i n 1 4o t h 7 4 L S 0 0 . U s i n g F i g u r e s T h r e e a n F o u r , c o m p l e t e t h w i r i n go t h d e c o d i n g c i r c u i t r y .

T h d e c o d i n g c i r c u i t r y i n F i g u r e F o u r i s i m p l e t f i g u r e o u i y o d r a w u p t r u t h t a b l e . I n t u i t i v e l y y o c a s e t h a t t h B L K 5 l i n e i n e e d e d t t u r n o e i t h e r t h $ A 0 0 0 o r t h e $ B 0 0 0 c h i p , a n i i t h A 1 l i n e t h a t d e t e r m i n e s w h i c h o t h t w c h i p s a r t b s e l e c t e d .N o t e t h a t t h o u t p u t s a r a c t i v e l o w .

R e m e m b e r , t h e r e ' s n r u s h , s o t a k e y o u r t i m e a n s e t h a t t h f i n a lw i r i n g g e t s d o n e c o r r e c t l y . A f t e r h a l f a h o u r ' s w o r k y o s h o u l d b d o n e a n r e a d y t s t i c k t h c i r c u i t b o a r d b a c k i i t c a s e .

T h N e F i n a l P r o d u c t

W h a t h a v e w a c c o m p l i s h e d ? W e l l , u s i n g t h 3 R A P a c k , w h i c hw a l r e a d y h a d , a n h a n d f u l o i n e x p e n s i v e e l e c t r o n i c p a r t s , w h a v e s e u t h c a r t r i d g e t a c c e p t t w 4 E P R O M ' s , o n e d e c o d e dt t h $ A 0 0 0 r e g i o n a n o n t t h $ B 0 0 0 r e g i o n . T h i s i a l m o s t

l i k e g e t t i n g s o m e t h i n g f o f r e e , i y o s t o p a n t h i n k a b o u t i t w g e s o m e e x t r a m e m o r y w i t h o u t e v e n h a v i n g t g e o u h a n d s d i r t ym a k i n g c i r c u i t b o a r d !

N o t h a t y o u h a v e t h i s m e m o r y a r e a a v a i l a b l e , w h a t a r s o m eg o o d u s e s f o i t W e l l , u s e d m c a r t r i d g e t i m p l e m e n t F O R T Hp a c k a g e o t h V I C - 2 0 . O t h e r g o o d u s e s w o u l d b t b u r n a E P R O M v e r s i o n o M I C R O M O N f o t h V I o a n o t h e r u t i l i t i e st h a t y o n e e d f r e q u e n t l y . H a v i n g p r o g r a m s l i k e t h e s e a v a i l a b l e i E P R O M i r e a l l y n e a t ; t h e y ' r e a l w a y s t h e r e a n r e a d y t g o N m o r e l o n g t a p e l o a d s f o 4 a n 8 u t i l i t i e s !

W e ' v e s e e n i n t h i s a r t i c l e , t h e n , h o t s q u e e z e t h m o s t o u o f 3 R A P a c k . A m e n t i o n e d , b y u n d e r s t a n d i n g a n u s i n g t h s e l e c t p a d s , i i p o s s i b l e t h a n d l e t h r e e d i f f e r e n t t y p e s o E P R O M sa n l o c a t e t h e m i a v a r i e t y o d i f f e r e n t m e m o r y l o c a t i o n s . F u t h e r m o r e , w i t h t h e a d d i t i o n o f e e x t r a c o m p o n e n t s , w s a h o t o s e t u t h E P R O M d e c o d i n g t a c c o m o d a t e t w o 4 u n i t sw i t h n w a s t e d a d d r e s s e s . W h w o u l d h a v e t h o u g h t t h a t t h 3 R A P a c k w a c a p a b l e o s m u c h !

J u m p e r1 1 - u p p e r1 1 - l o w e r1 2 - u p p e r1 2 - l o w e r

2 7 1 6b r e a km a k em a k eb r e a k

2 5 3 2m a k eb r e a km a k eb r e a k

2 5 6 4m a k eb r e a kb r e a km a k e

F i g u r e O n e : S e l e c t i o n P a d s i a S t o c k 3 R A P a c k

F i g u r e T w o : S e l e c t i o n S c h e m e f o T h r e e T y p e s o E P R O M S

f

p a t t h r o u g h h o l e

t h i s , h a l f o n l y

c h i p s e l e c t* A O O O

A 1

B L K S

e a c h N A N D g a t e - 1 / 4 7 4 L S O Oc h i p s e l e c t

B O O O

c h i p s e l e c tA O O O

F i g u r e F o u r : D e c o d i n g C i r c u i t r y F o T w 4 E P R O M S

F i g u r e T h r e e : M o d i f i e d S e l e c t i o n P a d s

F i g u r e F i v e : B r e a k i n g C o n n e c t i o n s F i g u r e S i x : N e C a p a c i t o r

T h T r a n s a c t o r 6 V o l u m e 5 I s s u e 0

Page 69: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 69/88

C o m p u t e r S l i d eP r o j e c t o r C o n t r o l

T h f o l l o w i n g a p p l i c a t i o n i o n e w h i c h w i l l i n t e r e s t m a n y . A t h o u g h t h t i t l e d e n o t e s s p e c i f i c i n t e r f a c e f o s l i d e p r o j e c t o rn a m e l y t h K o d a k E k t a g r a p h i c , i c a n b e a d a p t e d t c o n t r o l a n 1 2 V A a p p l i c a t i o n t h a t y o d e e m n e c e s s a r y . I i a l s o p o s s i b l e t a l l o w f o c o n t r o l o u t t o t a l l y i s o l a t e d c h a n n e l s , t h r o u g hp r o g r a m c o n t r o l . E a c h o t h e s e c h a n n e l s c a n p e r f o r m w h a t e v e rd u t i e s y o a s s i g n t t h e m , w i t h o u t r e q u i r i n g a s s i s t a n c e i a n s h a p e o f o r m f r o m t h o t h e r c h a n n e l s . A p r o m i s e d , a i n t e r f a c et h a t w i l l i n t e r e s t m o s t .

I b r i e f , t h s t a n d a r d i n t e r f a c e w i l l a l l o w f o f o r w a r d a n r e v e r s em o t i o n o K o d a k E k t a g r a p h i c S l i d e P r o j e c t o r u n d e r p r o g r a mc o n t r o l v i a t h e u s e r p o r t o t h c o m p u t e r . I o r d e r t h e l p y o v i s u a l i z e h o t h i s c a n b e a c h i e v e d , q u i c k e x p l a n a t i o n o t h p o r ti i o r d e r .

T h U s e r P o r t

T h p o r t s P A 0 - P A 7 ( P E T / C B M ) o P B 0 - P B 7 ( V I C / C 6 4 ) a r p r g r a m m a b l e i n p u t / o u t p u t l i n e s , d r i v e n b P O K E s , a n d r e a d w i t hP E E K s . W h e n p r o g r a m m e d a o u t p u t s t h r o u g h t h D a t a D i r e c t i o nR e g i s t e r , e a c h l i n e i c a p a b l e o d r i v i n g a s i n g l e T T i n p u t , w i t ha p p r o x i m a t e c u r r e n t d r a i n o 1 . m a W h e n p r o g r a m m e d a i n p u t s , e a c h l i n e a c t s a s i n g l e T T l o a d , w i t h t h s a m e c u r r e n td r a i n e x p e c t e d .

W h e n p r o g r a m m e d a o u t p u t s t h r o u g h t h D a t a D i r e c t i o n R e g i st e r , t h O u t p u t R e g i s t e r w i l l a l l o w f o g r a d u a t i o n o v o l t a g e l e v e l so t h e p o r t d u t t h s t a t u s o f t h c o r r e s p o n d i n g b i t . I t h p o r t i s e t t o 0 t h v o l t a g e l e v e l c a n b e e x p e c t e d t b . v o l t o l e s s . I t h b i i t u r n e d o n b i t = 1 t h e n t h e v o l t a g e l e v e l w i l l b 2 . 4 v o l t o g r e a t e r . I t h i s w a y , t h p o r t c a c o n t r o l v i r t u a l l y a n d e v i c ed e s i r e d , t h r o u g h t h e c o r r e c t i n t e r f a c e .

T b e s t u n d e r s t a n d p r o g r a m m e d a c c e s s t t h p o r t , h i g h l yr e c o m m e n d r e f e r r i n g b a c k t t h H a r d w a r e C o r n e r o V o l u m e 5 I s s u e 1 i t h T r a n s a c t o r . T h a u t h o r s c o v e r t h e s u b j e c t e x t e ns i v e l y , a n i w o u l d b e r e d u n d a n t f o m t e v e n a t t e m p t t c o v e r i o n c e a g a i n .

B o o l e a n L o g i c

C e r t a i n t e c h n i q u e s a r u s e d w i t h i n t h d e m o n s t r a t i o n p r o g r a ms h o w n b e l o w t h a t d n o f a l l w i t h i n t h e h e a d i n g o c o m m o nk n o w l e d g e . B o o l e a n l o g i c i u s e d w i t h i n , a n w i l l c o n f u s e m a n y a f i r s t g l a n c e . T h e l p a l l e v i a t e s o m e o t h i s c o n f u s i o n , a q u i c kb o o l e a n t o u r i r e q u i r e d .

I o r d e r t t u r n o o o f s p e c i f i c b i t s o t h p o r t s w i t h o u td i s t u r b i n g i t c u r r e n t s t a t u s , b o o l e a n l o g i c i b e s t u s e d . Y o c o u l dd e v i c e v a s t f o r m u l a t c a l c u l a t e t h p o r t s t a t u s w i t h o w i t h o u ty o u r b i t , b u t h e r e i n n e e d . C o m m o d o r e h a i n c o r p o r a t e dB o o l e a n o p e r a t o r s i n t o t h e i r v e r s i o n o B A S I C , t h e r e b y r e l i e v i n gy o o t h a g o n y .

T h o p e r a t o r s a r A N D , O R , a n d N O T . q u i c k e x p l a n a t i o n w i l l b f o u n d f o e a c h b e l o w

T e E v e r sR i c h m o n d H i l l , O n t .

A N

R e s u l t i n c l u d e s o n l y t h a t i n f o r m a t i o n w h i c h i i n c l u d e d i b o t hs e t s .

S e A - 0 0 1 1 0 1 0 1 D e c i m a l 5 S e B - 1 1 1 0 0 0 0 1 = D e c i m a l 2 2 R e s u l t 0 0 1 0 0 0 0 1 D e c i m a l 3 2

T h e r e f o r e , 5 A N 2 2 3

T f i n d t h s t a t u s o s i n g l e b i t , ( b i t 3 ) m a s k o f o t h e r i n f o r m a t i o nb A N D i n g w i t h t h d e c i m a l v a l u e f o t h a t b i t :

P R I N T P E E K ( 5 9 4 7 1 ) A N D 8. . . w i l l r e t u r n i b i i h i g h ( o n ) , o i t h b i i l o ( o f f ) .

O

C o m b i n e s s e s t h a t t h r e s u l t i n c l u d e s a l b i t s o w h i c h w e r eo i e i t h e r s e t .

S e A - 0 0 1 1 0 1 0 1 = D e c i m a l 5 S e B - 1 1 1 0 0 0 0 1 = D e c i m a l 2 2 R e s u l t 1 1 1 1 0 1 0 1 D e c i m a l 2 4 5

T h e r e f o r e , 5 o 2 2 2 4

T s e b i i b y t e , t h o p e r a t o r O s h o u l d b u s e d :

P O K E 5 9 4 7 1 , ( P E E K ( 5 9 4 7 1 ) O N

. . w h e r e n r e p r e s e n t s n u m b e r i t h r a n g e o 0 - 2 5 5 , w i l l s e t t h b i t , o b i t s , o y o u r c h o o s i n g .

N O

I n v e r t s a l i n f o r m a t i o n w i t h i n s e t .

A - 0 0 1 1 0 1 0 1 = D e c i m a l 5 N O A - 1 1 0 0 1 0 1 0 D e c i m a l 2 0 2

T h e r e f o r e , n o 5 2 0 ( 2 0 2 2 5 5 - 5 3 )

T c l e a r s p e c i f i c b i w i t h i n a b y t e , A N a n N O a r u s e d i t a n d e m :

P O K E 5 9 4 7 1 , ( P E E K ( 5 9 4 7 1 ) A N N O N

. . w h e r e n r e p r e s e n t s n u m b e r i t h e r a n g e o 0 - 2 5 5 , w i l l c l e a r( t u r n o f f ) t h b i t ( s ) o y o u r c h o o s i n g .

W h e n e x e c u t e d d i r e c t l y f r o m B A S I C , t h N O c o m m a n d w i l lp r o d u c e s t r a n g e r e s u l t s , i t a k e n a f a c e v a l u e . F r o m B A S I C , N O 5 - 5 4 , a c c o r d i n g t C o m m o d o r e l o g i c . I r e a l i t y , N O 5 2 0 2 , ( 2 0 2 2 5 5 - 5 3 ) . T h v a l u e o - 5 i 2 5 6 + ( - 5 4 ) w h i c h e q u a l s2 0 2 , t h c o r r e c t r e s u l t . I a p p e a r s t h a t t h s i g n b i i f l a g g e d , a c t i n g

T h T r a n s a c t o r 6 V o l u m e 5 I s s u e 0

Page 70: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 70/88

l i k e c a r r y t u r n i n g o b i ( 2 5 6 v a l u e ) . T h e r e f o r e , a d t h e mt o g e t h e r a n d y o u g e t h e c o r r e c t r e s u l t .

T h P r o g r a mW i t h t h p o r t e x p l a i n e d , a n b o o l e a n l o g i c c r y s t a l c l e a r f o a l l , t h p r o g r a m , c i r c u i t d i a g r a m , b o a r d d e s i g n a n l a y o u t a r e b e s t s h o w n .O n c e t h i s h a b e e n d o n e , w i l l e x p l a i n h o t h c i r c u i t c a e a s i l yb a d a p t e d f o a n a p p l i c a t i o n .

1 0 0 r e m * t e e v e r s - m . s . s . b . t o r o n t o u p d a t e s e p t / 8 41 0 r e * f o u s w i t h p e t / c b m / c 6 4 / v i c 2 01 1 p r i n t c h r $ ( 1 4 7 )1 1 5 c d $ c h r $ ( 1 7 ) c h r $ ( 1 7 ) c h r $ ( 1 7 )

c h r $ ( 1 7 ) c h r $ ( 1 7 ) : r e c u r s o r d o w n1 2 c r c h r $ ( 2 9 ) c h r $ ( 2 9 ) c h r $ ( 2 9 )

c h r $ ( 2 9 ) c h r $ ( 2 9 ) : r e - c u r s o r r i g h t1 2 r e d a t a d i r e c t i o n r e a o u t p u t r e 1 2 5 9 4 5 9 : n 5 9 4 7 1 : r e m * p e t / c b m1 3 0 r e m 5 6 5 7 9 : n 5 6 5 7 7 : r e m * c - 6 41 3 5 r e m : m 3 7 1 3 8 : n 3 7 1 3 6 : r e m * * v i c 2 01 4 0 p o k e m , 3 : p o k e n , : r e m s e p o r t s a o u t p u t s a n h i g h . 1 4 p r i n t m i d $ ( c d $ , 3 ) m i d $ ( c r $ , 4 ) " s l i d e p r o j e c t o r c o n t r o l1 5 p r i n t m i d $ ( c d $ , 4 ) m i d $ ( c r $ , 4 ) " d e m o p r o g r a m1 5 p r i n t m i d $ ( c d $ , 1 ) m i d $ ( c r $ , 1 ) " ( f ) a d v a n c e s m a g a z i n e1 6 p r i n t m i d $ ( c d $ , 4 ) m i d $ ( c r $ , 1 ) " ( r ) r e v e r s e s m a g a z i n e1 6 5 g e t a $ : i f a $ = " " t h e n 1 6 1 7 i a f t h e n g o s u b 1 9 1 7 i a r t h e n g o s u b 2 4 1 8 g o t o 1 6 1 8 5 :1 9 0 r e m * a d v a n c e m a g a z i n e * 1 9 p e e k ( n ) : r e m - r e t a i n c u r r e n t v a l u e2 0 a n n o : r e m - t u r n o f f b i t2 0 5 p o k e n , : r e m - p o k e i b a c k i 2 1 t 2 1 i f t i < k 2 t h e n 2 1 : r e m - w a i t l o o p2 2 x o : r e m - t u r n o b i 2 2 p o k e n , 2 3 r e t u r n2 3 5 :2 4 r e * r e v e r s e m a g a z i n e • 2 4 5 x p e e k ( n ) : r e m - r e t a i n c u r r e n t v a l u e2 5 0 x x a n d n o 2 : r e m t u r n o f f b i t2 5 p o k e n , : r e m p o k e i b a c k i 2 6 t 2 6 i t i < k 2 t h e n 2 6 : r e m w a i t l o o p2 7 0 x x o : r e m - t u r n o b i 2 7 p o k e n , 2 8 r e t u r n

N o t e s

W i t h t h C o m m o d o r e 6 4 + v o l t s i a v a i l a b l e t h r o u g h t h e u s e rp o r t T h P E T / C B M w a n o a w e l l d e s i g n e d . Y o w i l l b r e q u i r e dt t a o n t o t h c a s s e t t e p o r t t f i n d t h p o w e r r e q u i r e d . T h p i n o u t s o a l t h p o r t s w i l l b r e q u i r e d f o t h c o r r e c t i n s t a l l a t i o no t h i s i n t e r f a c e , a n c a n b e f o u n d i t h T r a n s a c t o r R e f e r a n c eI s s u e , T h P r o g r a m m e r s R e f e r e n c e G u i d e f o t h C 6 4 , a n m a n yo t h e r ' b o o k s . T h i s l e a v e f o y o t o l o c a t e .T f u r t h e r i n c r e a s e t h e p o w e r h a n d l i n g c a p a b i l i t y o t h i n t e r f a c e

s u i t a b l e T R I A C s h o u l d b e u s e d i p l a c e o t h e x i s t i n g R C T 3 2 0 2 B T R 1 A C .

F u t u r e V a r i a t i o n s

W i t h f e s i m p l e c h a n g e s t o t h i s i n t e r f a c e , c o n t r o l c a b e x e r c i s e d o v e r s e p a r a t e c h a n n e l s , u s i n g a l u s e r p o r t s l i n e s . F o e v e r y e x t r a 2 c h a n n e l s r e q u i r e d , a d d a n e x t r a c i r c u i t b o a r d . E a c hb o a r d w i l l a l l o w f o c o n t r o l o v e r t w p o r t s , t h e r e f o r e , a d u t m o r e b o a r d s . s i m p l e m e t h o d t a c h i e v e g r e a t e r r e s u l t s .

T c o n t r o l l o a d s o t h e r t h a n o n s p e c i f i c s l i d e p r o j e c t o r , y o w i l lf i n d l i t t l e e f f o r t e x p e n d e d o y o u r p a r t . d i a g r a m ( n e x t p a g e ) h a b e e n p r e p a r e d t b e t t e r d e m o n s t r a t e t h m e t h o d .A c a n b e s e e n f r o m t h d i a g r a m , l i t t l e h a b e e n c h a n g e d . T h j u m p e r b e t w e e n t h Y E L L O W l i n e i a n t h e o p p o s i t e s i d e o t h b o a r d h a b e e n r e m o v e d , a n t w s e p a r a t e L O A D s h a v e b e e nb r o u g h t i n t o p l a y . I t h d i a g r a m i h a b e e n s h o w n t h a t 2 s o u r c e so A a r e r e q u i r e d . T h i s d o e s n ' t h a v e t b i y o b r i d g e t h e A l i n e s t o g e t h e r . I t h i s w a y , s i n g l e A l i n e i n c o u l d c o n t r o l u t e i g h t c h a n n e l s , i y o s d e v i s e d . T h c h o i c e i y o u r s t m a k e .

3 9

p n o

G N

R E

V E L L O W

W H I T E

V E L L O W

G N

S o c k e t P r e h # 7 1 2 0 2 - 0 3 8

P l u g P r e h # 7 1 4 1 8 - 0 3 0

f l d d T h i s P l u g T " K o d a k R e m o t e C o n t r o l " F o P a t c h C o r d T P r o j e c t o r

S c h e m a t i c D i a g r a m

T h T r a n s a c t o r 6 V o l u m e 5 I s s u e 0

Page 71: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 71/88

m . s . 8 « b ,

A V - 8 3 O 1, P r i n t e d C i r c u i t B o a r d D e s i g nu o u b l e s i z e a s h o w n . T h b o a r d p h y s i c a l l y m e a s u r e s i a i n c h e s i l e n g t h b 1 . 7 5 i n c h e s i w i d t h .

T 2 3 0 2 B

" - r * « = -

W

F = > l = l © i

F = - l = )

G M C o m p o n e n t L a y o u t D i a g r a m

T 2 3 0 2 B

L O R D

L O R D

^ / - • ^ • - J 4 7 0 0 , e

T

C o n n e c t i o n o l o a d s a n A l i n e s

h T r a n s a c t o r 6 V o l u m e 5 I s s u e 0

Page 72: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 72/88

A u d i o / V i d e oC a b l e A d a p t e rF o T h V I 2

A r t h u r S B a r l a a nC h i c a g o , I

t 4 0 / 8 0 c o l u m nt A u d i o / V i d e oc o n n e c t o r o f

V I 2

5 - p i n D I N p l u g /w i t h c a b l e

t a u d i os y s t e m

D u a l R C p h o n o j a c k s

t T m o n i t o r 5 - p i n D I s o c k e t

c o n n e c t c a b l e c o m i n g f r o mR m o d u l a t o r b o x h e r e

F i g u r e

T h V I C 2 0 w a o r i g i n a l l y d e s i g n e d t b e c o n n e c t e d t b l o c k a n w h i t e o r c o l o r t e l e v i s i o n s e d i s p l a y i n g 2 c h a r a c t e r s p e l i n e . T h i sc a b m a j o r l i m i t a t i o n t s e r i o u s u s e r s w h i n t e n d t u s t h e i rV I C s t d o w o r d p r o c e s s i n g o s p r e a d s h e e t s o 4 o 8 c o l u m nd i s p l a y . s o l u t i o n t o t h i s p r o b l e m i t g e 4 0 / 8 0 c o l u m na d a p t e r s u c h a s t h e o n s u p p l i e d b y D a t a 2 0 T h n e x t t h i n g t c o n s i d e r i t h t e l e v i s i o n m o n i t o r . W i t h 4 c o l u m n d i s p l a y , t h r e g u l a r b & o r c o l o r T s e t w i l l g i v e a s a t i s f a c t o r y d i s p l a y ,h o w e v e r , i y o a r g o i n g t u s t h 8 c o l u m n d i s p l a y y o w i l ln e e d a s p e c i a l T m o n i t o r a v a i l a b l e i e i t h e r a m b e r , g r e e n , o rc o l o r f r o m w i d e v a r i e t y o s u p p l i e r s .

T h T m o n i t o r w i l l d i f f e r f r o m t h r e g u l a r T s e i t h w a i i c o n n e c t e d t t h c o m p u t e r . T h s i g n a l g o i n g t t h T m o n i t o rd o e s n o n e e d t p a s s t h r o u g h t h R m o d u l a t o r b o ( b l a c k b o w i t h c h a n n e l 2 o r 3 s e l e c t o r s w i t c h ) . Y o w i l l n e e d s p e c i a l c a b l et c o n n e c t t h T m o n i t o r t y o u r V I 2 o C 6 4 . Y o c a c o n s t r u c t y o u r o w i n e x p e n s i v e c a b l e a s s e m b l y w i t h t h o p t i o n o r e t a i n i n g t h e c o n n e c t i o n t y o u r r e g u l a r T s e t . F i g u r e s h o w s t h p i n u m b e r i n g o t h A u d i o / V i d e o c o n n e c t o r a t h b a c k o t h V I 2 a n t a b l e s h o w s t h p u r p o s e o e a c h p i n . T h i s c o n n e c t o rr e q u i r e s a s t a n d a r d m a l e 5 - p i n D I c o n n e c t o r ( R a d i o S h a c k * 4 2 -2 1 5 1 D I p a t c h c o r d ) . T h s t a n d a r d c o n n e c t o r u s e d b y m o s t T m o n i t o r s i a R C j a c k w h i c h w i l l r e q u i r e a R C p l u g c a b l e( R S * 4 2 - 3 0 9 a u d i o c a b l e s e t ) . F o l l o w i n g t h c i r c u i t d i a g r a m i F i g u r e y o w i l l h a v e a n a u d i o / v i d e o a d a p t e r w h i c h w i l l h a v ec o n n e c t i o n s :

1 5 - p i n m a l e D I p l u g w i t h c a b l e t b c o n n e c t e d t t h b a c k o t h e V I C 2 0 ( R S * 4 2 - 2 1 5 1 )

2 5 - p i n f e m a l e D I j a c k ( R S # 2 7 4 - 0 0 5 5 - p i n c h a s s i s s o c k e t ) t b c o n n e c t e d t t h R m o d u l a t o r c a b l e f o r e g u l a r T c o n n e c t i o n

3 R C j a c k s ( R S # 2 7 4 - 3 3 2 d u a l p h o n o j a c k ) , o n f o v i d e o o u t p u tt b e c o n n e c t e d t t h e v i d e o - i n j a c k o t h T m o n i t o r a n a n o t h e r f o a u d i o o u t p u t t b e c o n n e c t e d t t h e a u d i o - i n o s t a n d a r d s t e r e o s e t . B o t h j a c k s w i l l b c o n n e c t e d t t h T m o n i t o r a n d / o r s t e r e o s e u s i n g a R C p l u g a u d i o c a b l e s e ( R S * 4 2 - 2 3 0 9 )

T h t w c a p a c i t o r s ( C a n C 2 i f i g u r e 2 a r u s e d t p r o t e c t t h d e v i c e s c o n n e c t e d t t h c o m p u t e r . C i c o u p l i n g c a p a c i t o rw h i c h a l l o w s o n l y v i d e o s i g n a l s t p a s s a n p r e v e n t s a n D ( d i r e c t c u r r e n t ) v o l t a g e s f r o m p a s s i n g w h i c h c a n d o d a m a g e t t h T m o n i t o r . C i b y p a s s c a p a c i t o r w h i c h e l i m i n a t e s a n h i g hf r e q u e n c y s i g n a l s , s u c h a n o i s e g e n e r a t e d b h a i r d r y e r s o v a c u u m c l e a n e r s , f r o m i n t e r f e r i n g w i t h t h a u d i o s y s t e m .

W i t h t h i s a d a p t e r a n 4 0 / 8 0 c o l u m n a d a p t e r y o c a u s y o u rV I 2 t d i s p l a y 2 2 4 0 , o r 8 c o l u m n s o n e i t h e r y o u r r e g u l a r T s e o s p e c i a l T m o n i t o r . T h n e x t t h i n g y o m a g e t i r e d o d o i n g i s w i t c h i n g f r o m 2 t 4 0 / 8 0 c o l u m n s w h i c h r e q u i r e s t h a tt h 5 - p i n D I p l u g c o m i n g f r o m t h b o x y o u j u s t a s s e m b l e d b ec o n n e c t e d e i t h e r a t h b a c k o t h V I 2 f o 2 c o l u m n s o a t h b a c k o t h 4 0 / 8 0 c o l u m n c a r t r i d g e f o 4 o 8 c o l u m n s . T h i s c a e a s i l y b s i m p l i f i e d b a d d i n g D P D T ( d o u b l e p o l e , d o u b l e t h r o w )

T h T r a n s a c t o r 7 V o l u m e 5 I s s u e 0

Page 73: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 73/88

s w i t c h a n a n o t h e r 5 - p i n D I p l u g t t h c a b l e a d a p t e r c i r c u i t .F i g u r e s h o w s h o t h D P D T s w i t c h a n t h e a d d i t i o n a l c a b l es h o u l d b c o n n e c t e d . T h e n t i r e a s s e m b l y c a n b e h o u s e d i s m a l l a l u m i n u m b o ( l / 4 x l / 8 x 1 / 8 ) o r u s i n g R S # 2 7 0 - 2 3 0e x p e r i m e n t e r b o x .

s i m p l e p r o c e d u r e m u s t b f o l l o w e d t b a b l e t s w i t c h f r o m 2 2t 4 0 / 8 0 c o l u m n s d i s p l a y o r v i c e - v e r s a w i t h o u t l o s i n g w h a t e v e r i a l r e a d y i m e m o r y . Y o u m a f i n d t h i s n e e d f o s w i t c h i n g w h e ne d i t i n g B A S I C p r o g r a m s . Y o m a f i n d i m o r e c o n v e n i e n t t e d i tu s i n g 2 c o l u m n m o d e s i n c e t h e m a x i m u m l i n e l e n g t h u n d e r t h i sm o d e i 8 c h a r a c t e r s w h i l e i i o n l y 4 o 8 c h a r a c t e r s u n d e r 4 0o 8 c o l u m n m o d e .

w i l l a s s u m e y o a r u s i n g a ( o m o r e ) s l o t e x p a n d e r t o g e t h e rw i t h t h 4 0 / 8 0 c o l u m n c a r t r i d g e p o s i t i o n e d i n s l o t c o r r e s p o n di n t D I s w i t c h * 1 W i t h t h p r o p e r c a b l e s c o n n e c t e d a n t h m o d e s w i t c h o y o u r a u d i o / v i d e o a d a p t e r b o p o s i t i o n e d t 2 c o l u m n s a n d D I P s w i t c h * o t h e x p a n d e r b o a r d o O F p o s i t i o n( d i s a b l i n g t h 4 0 / 8 0 c o l u m n c a r t r i d g e ) , y o w i l l s e o y o u rm o n i t o r 2 c o l u m n d i s p l a y ( l a r g e c h a r a c t e r s ) . L o a d a n p r o g r a my o u w a n t t t e s t j u s t t o s e t h a t y o w o n f l o s e t h i s p r o g r a m w h e ny o s w i t c h t 4 0 / 8 0 c o l u m n m o d e . T o s w i t c h t 4 0 / 8 0 c o l u m nm o d e f o l l o w t h i s p r o c e d u r e c a r e f u l l y i t h r i g h t s e q u e n c e :

S t e p 1 S w i t c h D I * o e x p a n d e r b o a r d t O ( e s t a b l i s h e s t h c o n n e c t i o n o t h 4 0 / 8 0 c o l u m n c a r t r i d g e t t h e x p a ns i o n p o r t ) .

S t e p 2 T y p e S Y S 4 0 9 6 9 ( f o r D A T A 2 c a r t r i d g e ) , o w h a t e v e r y o u r4 0 / 8 0 c o l u m n c a r t r i d g e m a n u a l t e l l s y o t e n a b l e 4 c o l u m n d i s p l a y o S Y S 4 0 9 7 2 ( D A T A 2 c a r t r i d g e ) f o 8 c o l u m n d i s p l a y . T h c u r s o r w i l l d i s a p p e a r a t t h i s p o i n t .D o n ' t p a n i c .

S t e p 3 S w i t c h t h e d i s p l a y m o d e s w i t c h o y o u r a u d i o / v i d e oa d a p t e r t 4 0 / 8 0 c o l u m n p o s i t i o n . A t h i s p o i n t t h e' R E A D Y ' m e s s a g e w i l l a p p e a r o t h s c r e e n i e i t h e r 4 o 8 c o l u m n d i s p l a y d e p e n d i n g o t h c h o i c e y o m a d e .

S t e p 4 N o l i s t t h p r o g r a m y o l o a d e d a n i w i l l s t i l l b i m e m o r y r e a d y t r u n .

T t r a n s f e r b a c k t 2 c o l u m n s a l y o u h a v e t d i s w i t c h t h D I # t O F p o s i t i o n ( d i s a b l i n g t h 4 0 / 8 0 c o l u m n c a r t r i d g e ) t h e nt u r n t h e m o d e s w i t c h o y o u r a d a p t e r t 2 c o l u m n s . b i ' R E A D Y ' m e s s a g e w i l l b d i s p l a y e d a t h t o o y o u r s c r e e ni n d i c a t i n g t h a t y o a r n o i 2 c o l u m n m o d e . A g a i n , w h a t e v e ri i m e m o r y w i l l b r e t a i n e d . T h e r e m a b t i m e s t h a t y o w i l ll o s e w h a t i i m e m o r y , b u t h i s c a n b e c a u s e d b y t o m u c h j a r r i n gw h e n s w i t c h i n g t h D I s w i t c h o t h e x p a n d e r b o a r d . S b e x t r ac a r e f u l w h e n p u s h i n g t h D I s w i t c h e s .

C o m m o d o r e 6 U s e r s : T h i s p r o j e c t c a e a s i l y b e a d a p t e d t t h C o m m o d o r e 6 b j u s t c o n n e c t i n g t h p r o p e r p i n u m b e r s o t h a u d i o / v i d e o c o n n e c t o r o t h 6 4 N o y o u h a v e c h o i c e 2 2 4 0 o 8 i n j u s t f l i p o s w i t c h e s . H a p p y s w i t c h i n g !

T o 4 0 / 8 0 C o l u m n C a r t r i d g e

T R l l o d u l a t o r ( b l a c k b o x )

5 - p i n D l f l j a c k

1 ^ R C o u t p u t j a c kl V V u i c - o O u

l O u f 1 6

R C A o u t p u t j a c kA u d i o O u

F i g u r e 2 A u d i o / V i d e o C a b l e A d a p t e r F i g u r e 3 A u d i o / V i d e o A d a p t e r f o 2 o 4 0 / 8 0 C o l u m n D i s p l a y

T h T r a n s a c t o r 7

Page 74: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 74/88

L I N K E D L I S T SP a r t i

K M u r r a y S m i t hL o n d o n , O n t .

S o r t w i t h o u t S o r t i n g . .

L i n k e d l i s t s p r o v i d e p o w e r f u l a l t e r n a t i v e t s o r t i n g w h e n l a r g eq u a n t i t i e s o d a t a m u s t b o r g a n i z e d . T h f o l l o w i n g e x a m p l ei l l u s t r a t e s s o m e o t h e f e a t u r e s o l i n k e d l i s t s . A d d i t i o n a l f e a t u r e sa n s o m e s i m p l e p o s s i b i l i t i e s f o t h e i r u s w i l l b e f o u n d i t h s u m m a r y o P a r t 2

T h R e n t a w r e c k c a r e n t a l a g e n c y i c o m p u t e r i z i n g i t o p e r a t i o n .I t h i n i t i a l s e t u p i w a d e c i d e d t g r o u p t h v e h i c l e s o w n e d b t h c o m p a n y i n t o t h r e e l i s t s : t h o s e c u r r e n t l y r e n t e d , t h o s e a v a i l ab l f o r e n t a n t h o s e b e i n g s e r v i c e d . F o l l o w i n g t h i s , i w o u l d b n e c e s s a r y t b a b l e t m o v e v e h i c l e s b e t w e e n t h e s e l i s t s . F o e x a m p l e , w h e n r e n t e d v e h i c l e i r e t u r n e d , i i r e m o v e d f r o m t h r e n t e d l i s t a n d a d d e d t t h a v a i l a b l e l i s t ( o m a y b e t t h l i s t o t h o s e b e i n g s e r v i c e d ) . W h e n n e v e h i c l e s a r e p u r c h a s e d , t h e ym u s t b m a d e a v a i l a b l e f o r r e n t a l . A l s o , v e h i c l e s t h a t h a v e p a s s e dt h e i r u s e f u l l i f e t i m e s s h o u l d b e r e m o v e d f r o m c i r c u l a t i o n a t h e ya r e r e t u r n e d .

I w a a l s o r e q u i r e m e n t t h a t v e h i c l e s o t h e a v a i l a b l e l i s t b r a n k e d a t m i l e a g e , t h v e h i c l e w i t h l o w e s t m i l e a g e b e i n g t h f i r s t a v a i l a b l e , a n t h o s e o t h r e n t e d l i s t b r a n k e d b y d a t e - t o -b e - r e t u r n e d .

T h D a t a

T h v e h i c l e i n f o r m a t i o n i g i v e n i d a t a f i l e . T r e f r e s h y o u rm e m o r y , d a t a f i l e c o n s i s t s o o n o m o r e r e c o r d s . I o u c a s er e c o r d c o n t a i n s a l t h i n f o r m a t i o n a b o u t o n v e h i c l e . T h r e c o r di m a d e u o o n o m o r e f i e l d s . R e f e r r i n g t t h e v e h i c l e r e c o r d ,e a c h d a t u m s u c h a s l i c e n c e p l a t e n u m b e r i f i e l d .

T h d a t a f i l e i l a r g e t h n u m b e r o v e h i c l e s e x c e e d s 5 0 ( a t h o u g h i w i l l b m u c h s m a l l e r f o o u p u r p o s e s n o w ) a n f o e a c hi a e n t r y ( r e c o r d ) c o n t a i n i n g p l a t e n u m b e r , m i l e a g e , t y p e o v e h i c l e , e n g i n e s i z e , c o l o u r , t y p e o t r a n s m i s s i o n , d a t e o l a s ts e r v i c i n g a n s o t a e s t i m a t e d 1 f i e l d s .

S t a t e m e n t o t h P r o b l e m

T h i s i e a s y : w r i t e t h e s e r i e s o p r o g r a m s n e c e s s a r y t t a k e t h ec o m p a n y t h r o u g h t h a u t o m a t i o n ( s o t o s p e a k ! ) o i t o p e r a t i o n .

S o l u t i o n t t h P r o b l e m

T h i s i n o a s e a s y . T h f i r s t s t e p , a a n s t a r t i n g p r o b l e m - s o l v e rk n o w s , i t d i v i d e t h p r o b l e m i n t o s m a l l e r t a s k s a n h a n d l et h e s e s e p a r a t e l y . F o u s t h t a s k s b e c o m e e s t a b l i s h i n g t h e i n i t i a ll i s t s o v e h i c l e s a n p r o v i d i n g t h m e a n s o u p d a t i n g t h e s e l i s t s .

S i n c e t h l i s t s m u s t e x i s t b e f o r e t h e y c a b m a n i p u l a t e d , l e u c o n c e n t r a t e o t h i s ( b u t k e e p i m i n d t h r e q u i r e m e n t s o t h s e c o n d t a s k ) .

D a t a S t o r a g e

S i n c e t h r e s u l t s o f o u i n i t i a l i z a t i o n p r o g r a m w i l l b r e q u i r e d i t h s e c o n d h a l f o t h s o l u t i o n , t h e s e w i l l b s t o r e d o d i s k ( o t a p e ) .

W i t h i n t h p r o g r a m d a t a s t o r a g e w i l l b i a r r a y s . O n m i g h t t h i n ko u s i n g t w o - d i m e n s i o n a l a r r a y s , e a c h r o b e i n g f o v e h i c l e a n e a c h c o l u m n f o o n o t h d o z e n f i e l d s . H o w e v e r , t h i s i r a p i d l yd i s c a r d e d a w n o t e t h a t i i p o s s i b l e t r e q u i r e t h e v e h i c l e s i l i s t t b s o r t e d o m o r e t h a n o n f i e l d ( f o r e x a m p l e , t h a v a i l a b l el i s t i s s o r t e d o m i l e a g e b u a l s o o v e h i c l e t y p e f o t h c u s t o m e rw h n e e d s a s t a t i o n w a g o n r e g a r d l e s s o i t m i l e a g e ) . F o e a c h f i e l ds o r t e d , a e n t i r e a r r a y m u s t e x i s t ! U n l e s s y o u r m i n i m u m m e m o r ys i z e i f e h u n d r e d k i l o b y t e s , t h i s c o u l d c a u s e p r o b l e m s .

I i d e s i r a b l e t t r t c o n f i n e o u s t o r a g e t o n s e o t h d a t a . B u h o c a w p o s s i b l y s o r t o t w o m o r e f i e l d s w i t h o u t s c r a m b l i n gt h e d a t a i t h a r r a y ? T h a n s w e r i s i m p l e - b f o r g e t t i n gt r a d i t i o n a l s o r t i n g t e c h n i q u e s .

O n o t h m o s t c o m m o n o t h e s e i n v o l v e s c o m p a r i n g c o n s e c u t i v ee l e m e n t s o a a r r a y a n s w i t c h i n g t h e m i t h o r d e r i n o c o r r e c t .F o r e x a m p l e , c o n s i d e r t h a l p h a b e t i c s o r t i n g o t h e a r r a y s h o w n i t h e t o p l i n e o f F i g u r e 1

F i g u r e

A r r a y E n t r i e s

E l e m e n t

i

N u m b e r

t

A B C D E F G HC o m p a r i n g e l e m e n t s a n 2 w f i n d t h e y a r i o r d e r .C o m p a r i n g e l e m e n t s a n 3 w f i n d t h e y a r i o r d e r .C o m p a r i n g e l e m e n t s a n 4 w f i n d t h e y m u s t b s w i t c h e d .

Page 75: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 75/88

T h i s c o n t i n u e s u n t i l e l e m e n t s a n 8 a r e c o m p a r e d . A f t e r t h i s t h a r r a y l o o k s l i k e t h s e c o n d l i n e o f F i g u r e 1 N o t e t h a t t h " l a r g e s t "v a l u e , H h a b e e n p l a c e d i i t c o r r e c t s p o t .

S t a r t i n g a g a i n a e l e m e n t s a n 2 t h c o m p a r i s o n s a n s w i t c hi n g s a r m a d e o n c e m o r e b u o n l y u t e l e m e n t s a n t h i s t i m e .N o t h a r r a y l o o k s l i k e t h t h i r d r o w . T h r e m a i n i n g r o w s o F i g u r e s h o w t h r e s t o t h s o r t i n g p a s s e s t h r o u g h t h a r r a y . T h u n d e r l i n e d e l e m e n t s i n d i c a t e t h o s e t h a t a r e p r o p e r l y s o r t e d a n d n o h a v e t b c o n s i d e r e d o t h n e x t p a s s . N o t e a l s o t h a t t h l a s tt w l i n e s a r t h s a m e . T h i s s i t u a t i o n m i g h t o c c u r a a n t i m e i s o r t i n g a n s c h e c k i u s u a l l y m a d e t s e i a n s w i t c h e s h a v eb e e n m a d e i g i v e n p a s s . I n o t , t h e n t h s o r t i f i n i s h e d .

I o u p r o b l e m t h i s m e t h o d o s o r t i n g w o u l d i n v o l v e t h m o v em e n t o l a r g e n u m b e r s o e l e m e n t s w i t h i n t h a r r a y . O c o u r s e y o c o u l d s a v e m a n y o p e r a t i o n s b u s i n g o n e - d i m e n s i o n a l a r r a y ,e a c h e l e m e n t o w h i c h i s t r i n g c o n t a i n i n g a l t h i n f o r m a t i o n o o n v e h i c l e . H o w e v e r , f o o u c o m p a r i s o n s w a r n o r e q u i r e d t u s e t h e M I D $ f u n c t i o n t c o m p a r e t h c o r r e c t f i e l d s ! T h n u m b e ro o p e r a t i o n s i n t o t a l t h e n i n o s i g n i f i c a n t l y r e d u c e d , i a a l l .

S o r t i n g W i t h o u t S o r t i n g

T h p r o b l e m s o s o r t i n g o m a n y f i e l d s c a n b e s o l v e d u s i n g l i n k e dl i s t s . A e x a m p l e o l i n k e d l i s t i s s h o w n i F i g u r e 2 T h l i n k a g e sb e t w e e n a r r a y e l e m e n t s a r e i n d i c a t e d b a r r o w s . T h a r r o w s p o i n tt t h n e x t e l e m e n t i t h l i s t , a n b f o l l o w i n g t h a r r o w s i n t o a n o u o e a c h e l e m e n t i i p o s s i b l e t g a l o n g t h l i s t f r o m b e g i n n i n gt e n d . ( O c o u r s e i l a r g e l i s t i w o u l d b n i c e t h a v e p o i n t e r t t h s t a r t o t h l i s t ! )

F i g u r e

F i g u r e

r

R a t h e r t h a n a r r o w s , s e c o n d o n e - d i m e n s i o n a l a r r a y o t h s a m el e n g t h c a b u s e d t h o l d t h e p o i n t e r s t t h n e x t e l e m e n t s a s h o w n i F i g u r e 3 N o t e t h a t t h q u a n t i t y S T A R T E R i u s e d t i n d i c a t e w h e r e i L E T T E R S t h l i s t b e g i n s . I t h i s c a s e i i t h f o u r t h e l e m e n t . T h e n l o o k i n g a t h e f o u r t h e l e m e n t o t h L I N Ka r r a y w f i n d a e i g h t . T h i s s a y s t h n e x t l e t t e r i t h l i s t i t h e i g h t h e l e m e n t o L E T T E R S ( w h i c h i B ) T h e n g o i n g f o t h e e i g h t he l e m e n t o L I N K , i i o n e , g i v i n g a s t h e n e x t l e t t e r i t h l i s ta n s o n S i n c e i t h l a s t l e t t e r i n t h l i s t , i t c o r r e s p o n d i n ge l e m e n t o L I N K m u s t i n d i c a t e s o m e h o w t h a t t h l i s t i s d o n e a n dz e r o i u s e d ( a r b i t r a r i l y ) f o r t h i s p u r p o s e .

E l e m e n t N u m b e r s5

A R R A Y

L E T T E R SL I N K

S T A R T E R

R e g a r d l e s s o t h n u m b e r o f i e l d s i e a c h r e c o r d , o n l y o n e L I N Ka r r a y i n e e d e d . T h i s a r r a y i v a l i d o n l y f o t h s p e c i f i c f i e l d w l i n k e d . I w w i s h f i l e o r g a n i z e d o m o r e t h a n o n f i e l d , w w i l ln e e d o n a r r a y o p o i n t e r s f o e a c h f i e l d t b l i n k e d . ( A f i l ec o n t a i n i n g f o u r f i e l d s p e r e c o r d a n s o r t e d o a l f i e l d s w o u l dr e q u i r e f o u r a r r a y s f o t h f i l e a n t h e n f o u r f o t h e p o i n t e r sw h e r e a s t r a d i t i o n a l s o r t s m i g h t r e q u i r e u t f o u r a r r a y s f o t h f i l ep l u s 1 m o r e , o n g r o u p o f o u r f o e a c h f i e l d s o r t e d . )

T h M e c h a n i c s

L e t ' s n o l o o k a t h m e c h a n i c s o s e t t i n g u t h l i n k e d l i s t . T a b l es h o w s s o m e o R e n t a w r e c k ' s c u r r e n t l y r e n t e d v e h i c l e s ( o n l y t w

f i e l d s a r s h o w n ) .

T a b l e 1 T h R e n t e d V e h i c l e s

P l a t eN u m b e r

T E 6 8 L A 2 4 J D L 4 1 3V A 7 5 S J S 0 1 7

S P 0 0

D u D a t e( M o n t h - D a y )

1 2 - 0 71 2 - 1 81 2 - 1 11 2 - 2 71 2 - 0 31 2 - 1 1

A s s u m e t h a t t h e r e i p o s s i b i l i t y o m a x i m u m o 5 v e h i c l e s .T h i s p r o v i d e s l i m i t o o u a r r a y s i z e s r i g h t n o w . P r o g r a m r e a d st h d a t a a n l i n k s t h f i l e b a s e d o n d u e d a t e a n T a b l e 2 d e s c r i b e st h e v a r i a b l e s u s e d .

P r o g r a m D e s c r i p t i o n

T h f o l l o w i n g i a l i n e - b y - l i n e d e s c r i p t i o n o P r o g r a m 1

3 0 , 4 0 : d i m e n s i o n t h e a r r a y s t b u s e d . O n l y l i n e 3 n e e db c h a n g e d t o a f f e c t t h e a r r a y s i z e s t h r o u g h o u t t h p r o g r a m .

6 0 - 9 0 : b f i l l i n g t h a r r a y s w i t h t h e s e s t r i n g s , t h e a r r a y sc a b p r i n t e d b e s i d e e a c h o t h e r i c o l u m n s .

1 1 0 - 1 6 0 : i n p u t t h e p l a t e n u m b e r s a n d u d a t e s f o t h v e h i c l e s c u r r e n t l y r e n t e d , k e e p i n g c o u n t o h o m a n y i N R S t o p r e a d i n g d a t a w h e n ' d u m m y 'r e c o r d i r e a d ( l i n e 1 4 0 ) .

1 8 0 - 2 0 0 : c o p y i n t o w o r k a r r a y t h e p o r t i o n o t h d u d a t ea r r a y t b l i n k e d . T h i s i n e c e s s a r y a t h s u b r o ut i n e w h i c h s e t s u t h l i n k s d e s t r o y s t h e a r r a y u p o nw h i c h i w o r k s .

2 1 0 , 2 2 0 : d e f i n e t h h i g h e s t a n l o w e s t e l e m e n t s i t h w o r ka r r a y t b u s e d i t h l i n k i n g .

T h T r a n s a c t o r 7 V o l u m e S I s s u e 0

Page 76: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 76/88

2 3 0 : p e r f o r m t h l i n k i n g .2 4 0 : s a v e t h e e n t r y p o i n t t t h e l i n k e d l i s t o r e n t e d

v e h i c l e s .8 0 0 0 : t h H o o p e n s u r e s t h a t w g o t h r o u g h t h p o r t i o n o

t h w o r k i n g a r r a y w a r u s i n g o n c e f o e a c he l e m e n t .

8 0 1 0 , 8 0 2 0 : s i n c e w a r e l i n k i n g v a l u e s f r o m s m a l l e s t t l a r g e s t ,h e r e w a s s u m e t h a t t h s m a l l e s t v a l u e i i t h f i r s te l e m e n t o t h e p o r t i o n o t h e a r r a y w a r u s i n g .S M a n S s t o r e t h i s " s m a l l e s t v a l u e s f a r " a n i t s u b s c r i p t .

8 0 3 0 - 8 0 8 0 : g t h r o u g h t h r e m a i n d e r o f t h i s p o r t i o n o t h w o r k a r r a y a n s e i t h e r e i s m a l l e r v a l u e i s o p u t h i s v a l u e i S M a n t h s u b s c r i p t i n t o S B

8 0 9 0 - 8 1 2 0 : c h e c k i t h i s i t h f i r s t p a s s t h r o u g h t h i s s e c t i o n o t h w o r k a r r a y i s o t h e n w h a v e t h e e n t r y p o i n tt t h i s l i n k e d l i s t ( S E ) . T h i s s u b s c r i p t m u s t a l s o b s a v e d ( i J b e c a u s e t h i s e l e m e n t o t h l i n k a r r a y( L D ) m u s t c o n t a i n t h e p o i n t e r t t h n e x t s m a l l e s tv a l u e .

8 1 4 0 - 8 1 5 0 : o a n o t h e r p a s s t h r o u g h t h w o r k a r r a y , p u t h s u b s c r i p t o t h c u r r e n t s m a l l e s t v a l u e i n t o t h c o r r e c t p o s i t i o n o t h p o i n t e r a r r a y ( a g i v e n b J a n u p d a t e t h v a l u e o J

8 1 6 0 : r e p l a c e t h e c u r r e n t s m a l l e s t v a l u e b ' [ w h i c h h a a A S C I I v a l u e h i g h e r t h a n a n d i g i t o u p p e r c a s el e t t e r . T h i s e n s u r e s t h a t t h i s e l e m e n t w i l l n o b c h o s e n a g a i n a n e x t - s m a l l e s t v a l u e .

8 1 8 0 - 8 1 9 0 : i w h a v e n o l i n k e d a l o t h v a l u e s i t h w o r ka r r a y , s e t t h l a s t p o i n t e r t z e r o t i n d i c a t e t h ee n o t h l i s t .

T a b l e 2 D e s c r i p t i o n o V a r i a b l e s

D U t h e a r r a y c o n t a i n i n g t h e d u d a t e s o t h r e n t e d v e h i c l e sI , J , K l o o p c o n t r o l l e r s ( s e e p r o g r a m d e s c r i p t i o n )L t h l i n k a r r a y c o n t a i n s t h e p o i n t e r sN t h n u m b e r o r e n t e d v e h i c l e sP L t h e a r r a y c o n t a i n i n g l i c e n c e p l a t e n u m b e r s

t h s i z e ( d i m e n s i o n ) o a l a r r a y sS t h s u b s c r i p t o t h s m a l l e s t e l e m e n t f o u n d i t h w o r k

a r r a y s f a S w h e r e t e n t e r t h i s p a r t i c u l a r l i n k e d l i s tS t h s t a r t i n g e l e m e n t n u m b e r f o l i s t t b l i n k e dS M t h s m a l l e s t v a l u e f o u n d i t h w o r k a r r a y u t o t h i s p o i n tS t h e p o i n t e r t t h s t a r t i n g e l e m e n t f o t h e l i n k e d l i s t o

r e n t e d v e h i c l e sU t h e h i g h e s t e l e m e n t n u m b e r f o l i s t t b l i n k e dW O w o r k a r r a y , s t a r t i n g a s c o p y o t h l i s t t b l i n k e d

P r o g r a m O u t p u t

S i n c e t h j o o o r g a n i z i n g R e n t a w r e c k ' s f i l e s h a j u s t b e g u n , t h p r o g r a m c o n t a i n s n o u t p u t s e c t i o n . T h a r r a y s c a b e x a m i n e db t y p i n g i i m m e d i a t e m o d e :

P R I N T S A $ = ' 7 "F O R I = 1 T O U L : ? P L $ ( I ) A $ D U $ ( I ) A $ L D ( I ) : N E X T I

( F o r o u t p u t t p r i n t e r , p r e c e d e t h a b o v e i n s t r u c t i o n s w i t hO P E N 4 , 4 : C M D 4 a n f o l l o w t h e m w i t h P R I N T # 4 : C L O S E 4 )

Y o s h o u l d s e e :

T E 6 8 L A 2 4 J D L 4 1 3V A 7 5 S J S 0 1 7S P 0 0

1 2 - 0 71 2 - 1 81 2 - 1 11 2 - 2 7 01 2 - 0 31 2 - 1 1 2

T h " s o r t e d " l i s t i n g o f d u d a t e s b e g i n s w i t h e l e m e n t 5 t h f i f t hp o i n t e r s h o w s t h n e x t d u d a t e i e l e m e n t 1 t h f i r s t p o i n t e rs h o w s t h n e x t d u d a t e i e l e m e n t a n s o n T h s e c o n d l a s td u d a t e i e l e m e n t a n e l e m e n t 2 o t h l i n k a r r a y i 4 T h f o u r t h e l e m e n t o t h l i n k a r r a y i 0 i n d i c a t i n g t h e e n o t h l i s t( t h o s e m e m o r y s c a v e n g e r s o u t h e r e w h l i k e t u s t h z e r oe l e m e n t s o a r r a y s m i g h t u s e - t i n d i c a t e t h e e n d ! )

T h O t h e r L i s t s

P a r t o o u i n i t i a l t a s k i d o n e . W h a v e y e t e s t a b l i s h l i n k e d l i s t sf o t h o s e v e h i c l e s w h i c h a r a v a i l a b l e f o r e n t a l ( l i n k e d b m i l e a g e )a n f o t h o s e b e i n g s e r v i c e d ( l i n k e d b m i l e a g e a l s o ) . W h e r es h o u l d w s t o r e t h e s e d a t a ? W c o u l d u s a n o t h e r s e t o f a r r a y s f o e a c h o t h e s e s i t u a t i o n s . W w o u l d t h e n h a v e t h r e e s e p a r a t ep o i n t e r a r r a y s . T h r e s u l t w o u l d b w e l l - o r g a n i z e d d a t a , e a c hc a t e g o r y h a v i n g i t o w l i n k a g e a r r a y .

A t h i s p o i n t i w o u l d b e w i s e t r e m e m b e r t h a t w e a r l i e r s a i d t h a ta l t h o u g h w w e r e w o r k i n g t s o l v e t h e f i r s t h a l f o f t h p r o b l e m , w s h o u l d a l s o k e e p i m i n d t h r e q u i r e m e n t s o t h s e c o n d p a r t . O n o t h e s e i t h a t w a r e a b l e t t r a n s f e r v e h i c l e s b e t w e e n l i s t s a r e n t e d o n e s a r e r e t u r n e d , s e r v i c e d o n e s a r m a d e a v a i l a b l e a n s o n W i t h s e p a r a t e l i s t s , e l e m e n t s w i l l h a v e t b c o p i e d f r o m o n s e t o f a r r a y s t a n o t h e r . T h i s a l s o i m p l i e s t h a t e a c h s e o a r r a y sm u s t b d i m e n s i o n e d s u f f i c i e n t l y l a r g e t h o l d n e a r l y a l ( i n o a l l )o t h e v e h i c l e s a o n c e . S u d d e n l y m e m o r y u s a g e i i n c r e a s i n ga g a i n , s i t u a t i o n w w i s h e d t a v o i d . I a d d i t i o n , w h a t d w d w i t h t h n e w l y - v a c a t e d a r r a y e l e m e n t s ? H o d w k e e p t r a c k o t h e m t u s t h e m a g a i n l a t e r ?

T h b e s t p l a c e t s t o r e t h o t h e r v e h i c l e s i i t h s a m e a r r a y a t h o s e c u r r e n t l y r e n t e d . T h a d v a n t a g e h e r e i t h a t a l o t h v e h i c l e s o w n e d b t h c o m p a n y a r e t o g e t h e r i t h s a m e p l a c e .N o o n l y t h a t b u t h e p o i n t e r s f o a l t h r e e l i s t s c a a l s o b k e p t i t h s a m e a r r a y , e a c h l i s t h a v i n g i t o w e n t r y v a l u e a n t e r m i n a ti n w i t h z e r o e l e m e n t .

F i g u r e s h o w s L I N K a r r a y c o n t a i n i n g p o i n t e r s f o t h t h r e el i n k e d l i s t s p r e v i o u s l y d e s c r i b e d . A l s o l i n k e d i n t o a l i s t a r e t h eu n u s e d ( o f r e e ) e l e m e n t s o t h a r r a y . T h e s e a r u s e f u l f o s t o r i n gd a t a o e v e n t u a l p u r c h a s e s . I i i m p o r t a n t t r e a l i z e t h a t t h l i s t s o r e n t e d a n a v a i l a b l e v e h i c l e s w e r e s o r t e d o d i f f e r e n t f i e l d s ,n a m e l y d u e d a t e f o t h r e n t e d a n m i l e a g e f o t h a v a i l a b l e . T h i si v e r y p o w e r f u l f e a t u r e o l i n k e d l i s t s .

T h T r a n s a c t o r 7

Page 77: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 77/88

F i g u r e

E L E M E N TN U M B E R

L I N KA R R A Y

S T A R T I N GE L E M E N T S

1 1 1 1 1 1 1 1 1 1 2

1 1

1

1 1

1 1 1 2

R e n t e d

A v a i l a b l e

B e i n g/ S e r v i c e d

F r e e

1

1

P r o g r a m c o n t a i n s a d d i t i o n s t P r o g r a m t r e a d t h e d a t a f o t h a v a i l a b l e v e h i c l e s a n t h o s e b e i n g s e r v i c e d , t l i n k b o t h o t h e s eb m i l e a g e , a n f i n a l l y t l i n k t h f r e e s p a c e t o g e t h e r . L i n k i n g t h f r e e s p a c e p r o v i d e s f o g o o d m e m o r y m a n a g e m e n t . A v e h i c l e sa r s o l d , t h a r r a y s p a c e o c c u p i e d b t h e s e c a b r e u s e d b n e v e h i c l e s p u r c h a s e d .

L i n e s 1 0 2 0 a n d 1 0 6 0 r e q u i r e a e x p l a n a t i o n . T h m i l e a g e s a r s t o r e d a s t r i n g s f o t w r e a s o n s . O n i t h e d e s i r e t h a v e t h e s en u m b e r s d i s p l a y e d o r p r i n t e d r i g h t - j u s t i f i e d i c o l u m n , t h a t i s l i n e d u a l o n g t h r i g h t e n d s o t h n u m b e r s . T h s e c o n d i b e i n ga b l e t u s t h s a m e r o u t i n e f o l i n k i n g a l o t h l i s t s . S i n c e t h m a x i m u m m i l e a g e i 9 9 9 9 9 9 , l i n e 1 0 6 0 i u s e d w i t h l i n e 1 0 2 0 t p u t l e a d i n g b l a n k s i m i l e a g e s h a v i n g f e w e r t h a n s i d i g i t s .O t h e r w i s e ' 1 1 ' w o u l d s o r t a b e i n g g r e a t e r t h a n ' 1 0 0 0 0 0 ' !

T a b l e 3 D e s c r i p t i o n o A d d i t i o n a l V a r i a b l e s

B s t r i n g o s i b l a n k s t p r o v i d e l e a d i n g b l a n k s w h e r en e c e s s a r y i t h m i l e a g e s t r i n g s

M I t h a r r a y c o n t a i n i n g t h m i l e a g e s ( i k i l o m e t r e s ) o t h v e h i c l e s

N A , N S t h n u m b e r s o a v a i l a b l e v e h i c l e s a n v e h i c l e s b e i n gs e r v i c e d , r e s p e c t i v e l y

S A , S S , S F t h e p o i n t e r s t t h s t a r t i n g e l e m e n t s o t h e l i n k e d l i s t s o t h a v a i l a b l e v e h i c l e s , t h o s e b e i n g s e r v i c e d a n t h f r e ee l e m e n t s r e s p e c t i v e l y .

T s e t h f i r s t t h r e e l i n k e d l i s t s a n t h s t a r t o f t h e l i n k e d f r e e l i s t ,t y p e i i m m e d i a t e m o d e a g a i n :

P R I N T S R ; S A ; S S ; S FA $ = 7 "F O R I = 1 T O 2 0 : ? P L $ ( l ) A $ D U $ ( l ) A $ M I $ ( l ) A $ L D ( l ) : N E X T I

Y o c a n t h e n s t a r t a t h e l e m e n t g i v e n b S D , S A , S o S t e n t e rt h e a p p r o p r i a t e l i s t a n t h e n f o l l o w i t h r o u g h t t h e n ( a i n d i c a t e d b a z e r o p o i n t e r ) . I y o w i s h t s e h o t h f r e e l i s te n d s , t h e n r e p l a c e t h e

' T 2 0 b ' 2 T 5 0

( T h e o u t p u t i b e s t s e e n o p r i n t e r u s i n g F O R I = 1 T O 5 0 w i t h t h o p e n i n g a n c l o s i n g s t a t e m e n t s g i v e n p r e v i o u s l y . )

S a v i n g t h L i s t s

I o r d e r t b a b l e t u p d a t e t h l i s t s i P a r t o f t h i s a r t i c l e , w n e e d t s a v e t h e s e l i s t s o t a p e o r d i s k . P r o g r a m c o n t a i n s t h n e c e s s a r y a d d i t i o n s t t h c u r r e n t p r o g r a m t s a v e t h d a t a i s e q u e n t i a l f i l e o d i s k .

S u m m a r y

T h u s f a w h a v e a c c o m p l i s h e d a l o t h r e q u i r e m e n t s f o t h i n i t i a l s e t u p o R e n t a w r e c k ' s f i l e s . W h a v e a l s o a t t e m p t e d t b c o n s e r v a t i v e w i t h r e s p e c t t m e m o r y a n h a v e g i v e n s o m e c o n s i de r a t i o n t b e i n g a b l e t e a s i l y m a n i p u l a t e t h l i s t s , s o m e t h i n g t h a tw m u s t b a b l e t d i P a r t 2

P r o g r a m a n d P r o g r a m o N E X T p a g e

P r o g r a m

1 0 r e m - p r o g r a m4 0 0 0 r e m - o u t p u t l i n k e d l i s t s t d i s k4 0 1 0 p r i n t " d y o w i s h t s a v e t h e l i n k e d "4 0 2 0 p r i n t " l i s t s a t h i s t i m e ? "4 0 3 0 p r i n t " ( t y p e y o n ) : " ;4 0 4 0 g e d 4 0 5 0 i d " t h e n 4 0 4 04 0 6 0 p r i n t d 4 0 7 0 i d $ n " t h e n 7 9 9 94 0 8 0 i f d $ < > " y " t h e n 4 0 3 04 0 9 0 c $ = c h r $ ( 1 3 )4 1 0 0 o p e n i , 8 , 2 , " 0 : l i n k e d l i s t s , s e q . w "4 1 1 0 p r i n t # 1 , s ; c $ ; u l ; c $ ; s r ; c $ ; s a ; c $ ; s s ; c $ ; s f4 1 2 0 f o t o 4 1 3 0 : p r i n t # 1 , p l $ ( i ) ; c $ ; d u $ ( i ) ; c $ ; m i $ ( i ) ; c $ ; l d ( i )4 1 4 0 n e x t4 1 5 0 c l o s e 14 1 6 0 p r i n t t a b ( 1 0 ) ; " l i s t s h a v e b e e n s a v e d "

T h T r a n s a c t o r 7 V o l u m e 5 I s s u e 0

Page 78: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 78/88

P r o g r a m P r o g r a m

1 r e m - p r o g r a m2 0 r e m - s e u a r r a y s , v a r i a b l e s3 0 5 4 d i p l $ ( s ) , d u $ ( s ) , w o $ ( s ) , l d ( s )5 r e m - i n i t i a l i z e a r r a y s6 f o t 7 : p l $ ( i ) = : r e m s p a c e s8 : d u $ ( i ) = " : r e m 5 s p a c e s9 n e x t1 0 r e m - i n p u t a r r a y s1 1 n 1 2 f o t 1 3 0 : r e a d p l $ ( i ) , d u $ ( i )1 4 : i p l $ ( i ) d u n u m " t h e n 1 7 1 5 : n n r + 11 6 n e x t1 7 r e m - r e a d d u d a t e s i n t o w o r k a r r a y1 8 f o t n 1 9 0 : w o $ ( i ) d u $ ( i )2 0 n e x t2 1 u n 2 2 s 2 3 0 g o s u b 8 0 0 02 4 0 s r s 7 9 9 9 e n d8 0 0 0 s 8 0 1 0 : s m $ w o $ ( s m )8 0 2 0 : s s 8 0 3 0 : s 8 0 4 0 : i s m $ < w o $ ( k ) t h e n 8 0 7 08 0 5 0 : : s m $ w o $ ( k )8 0 6 0 : : s b = k8 0 7 0 : : k k + 8 0 8 0 : i f k < u t h e n 8 0 4 08 0 9 0 : i i O s m t h e n 8 1 4 08 1 0 0 : r e m - e s t a b l i s h e n t r y p o i n t t t h l i n k a r r a y8 1 1 0 : s e s 8 1 2 0 : j s 8 1 3 0 : g o t o 8 1 6 08 1 4 0 : l d ( j ) s 8 1 5 0 : j s 8 1 6 0 : w o $ ( s b ) = " [ 8 1 7 0 : i8 1 8 0 i i u t h e n 8 0 1 08 1 9 0 l d ( j )8 2 0 0 r e t u r n1 0 0 0 0 d a t a t e 6 8 6 , 1 2 - 0 7 , l a s 2 4 1 , 1 2 - 1 81 0 0 0 1 d a t a j d 4 1 3 , 1 2 - 1 1 , v a x 7 5 0 , 1 2 - 2 71 0 0 0 2 d a t a s j 0 1 7 , 1 2 - 0 3 , s p y 0 0 7 , 1 2 - 1 11 0 0 0 3 d a t a d u n u m , 9 9 - 9 9

1 r e m - p r o g r a m4 d i p l $ ( s ) , d u $ ( s ) , w o $ ( s ) , m i $ ( s ) , l d ( s )8 : m i $ ( i ) " : r e m s p a c e s1 4 : i p l $ ( i ) d u n u m " t h e n 1 6 1 5 : n n 1 6 r e m - b l a n k o u t t h e d u m m y d a t a1 6 6 p l $ ( i ) = " : r e m 7 s p a c e s1 6 d u $ ( i ) : r e m s p a c e s1 0 0 0 r e m - f o a v a i l a b l e v e h i c l e s1 0 1 0 n a1 0 2 0 b $ " : r e m s p a c e s1 0 3 0 f o n + t o 1 0 4 0 : r e a d p l $ ( i ) , m i $ ( i )1 0 5 0 : i p l $ ( i ) d u n u m " t h e n 1 0 9 01 0 6 0 : m i $ ( i ) l e f t $ ( b $ , 6 - l e n ( m i $ ( i ) ) ) m i $ ( i )1 0 7 0 : n n 1 0 8 0 n e x t1 0 9 0 r e m - b l a n k o u t h d u m m y d a t a1 1 0 0 p l $ ( i ) = " : r e m s p a c e s1 1 1 0 m i $ ( i ) : r e m s p a c e s1 1 2 0 r e m - s e u l o w e r a n u p p e r l i m i t s o t h i s p a r t o a r r a y1 1 3 0 s m n 1 1 4 0 u n n 1 1 5 0 r e m - r e a d m i l e a g e i n t o w o r k i n g a r r a y1 1 6 0 f o s t u 1 1 7 0 : w o $ ( i ) m i $ ( i )1 1 8 0 n e x t i1 1 9 0 g o s u b 8 0 0 01 2 0 0 s s 2 0 0 0 r e m - f o v e h i c l e s b e i n g s e r v i c e d2 0 1 0 n s2 0 2 0 b $ : r e m s p a c e s2 0 3 0 f o r n n t o 2 0 4 0 : r e a d p l $ ( i ) , m i $ ( i )2 0 5 0 : i p l $ ( i ) = d u n u m " t h e n 2 0 9 02 0 6 0 : m i $ ( i ) l e f t $ ( b $ , 6 - l e n ( m i $ ( i ) ) ) m i $ ( i )2 0 7 0 : n = n s + 12 0 8 0 n e x t2 0 9 0 r e m - b l a n k o u t t h e d u m m y d a t a2 1 0 0 p l $ ( i ) = " " r e s p a c e s2 1 1 0 m i $ ( i ) " : r e m 6 s p a c e s2 1 2 0 r e m - s e l o w e r a n u p p e r l i m i t s2 1 3 0 s m n n a + 12 1 4 0 u n r + n a n 2 1 5 0 r e m - r e a d m i l e a g e i n t o w o r k a r r a y2 1 6 0 f o s t u 2 1 7 0 : w o $ ( i ) m i $ ( i )2 1 8 0 n e x t i2 1 9 0 g o s u b 8 0 0 02 2 0 0 s s 3 0 0 0 r e m - l i n k f r e e s p a c e3 0 1 0 i u 3 0 2 0 s 3 0 3 0 i t h e n 3 0 7 03 0 4 0 l d ( i )3 0 5 0 : i3 0 6 0 i i 4 t h e n 3 0 4 03 0 7 0 l d ( s )1 0 0 0 4 d a t a l o 1 9 0 , 1 0 1 7 6 0 , n j z 2 4 2 , 1 5 6 91 0 0 0 5 d a t a k f 8 2 2 , 1 3 7 5 6 4 , t n h 4 8 7 , 2 0 0 1 4 71 0 0 0 6 d a t a z o m 4 3 4 , 6 5 7 2 , e a r n 8 7 6 , 8 7 6 2 41 0 0 0 7 d a t a u p x 8 1 4 , 1 6 5 8 3 , d u m n u m , - 11 0 0 0 8 d a t a e r 0 9 8 , 6 0 1 0 5 , t r k 6 3 3 , 1 2 0 3 5 41 0 0 0 9 d a t a g b 4 8 4 , 3 2 9 0 0 , d u m n u m , - 1

T h T r a n s a c t o r 7 V o l u m e 5 I s s u e 0

Page 79: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 79/88

C o m p u t i n g D e s k S c o t t J o h n s o nT r a v e r s e C i t y , M

3

- 1 1 -

■ ■ ■ ■ : ■ . ■ . ■ ■ ■ ■ ■ - . - ■■ ■ ■ : .

1

2

: : ; . " ■ ■ ' " ■

. . ' . .

j . . .

■ ■ ( : . : ■ •

■ : ■ ■ ■ :. ' . . . - . : .

' : : ■ : : : • : ■ : : ■ . . , - ' ■ ' " ■ " ■ ■ . ■ ■ - : - ; , " j 2

F o m a n y o u s t h p u r c h a s e o o u f i r s t c o m p u t e r w a t h c u l m i n a t i o n o m o n t h s , o p e r h a p s y e a r s , o l o n g i n g a n d r e a mi n g . W h u r r i e d h o m e f r o m t h s t o r e w i t h o u r d r e a m t u c k e d u n d e ro u r a r m , s a f e l y p a c k e d a w a y i c a r d b o a r d a n s t y r o f o a m . W i t hg r e a t a n t i c i p a t i o n w f i n a l l y r e m o v e d o u d r e a m r e a l i z e d f r o m i t p l a s t i c c o c o o n , o n l y t b f a c e d w i t h a n o t h e r m a j o r d e c i s i o n ;w h e r e a r w g o i n g t p u i t O t h k i t c h e n t a b l e ? T h l i v i n g r o o mf l o o r ? O t h a t r i c k e t y o l c a r d t a b l e ? I ' a f r a i d t h a t t o m a n y h o m ec o m p u t e r s h a v e e i t h e r e n d e d u p g a t h e r i n g d u s t t u c k e d a w a yb e h i n d t h e f a m i l y T V o s t a s h e d i t h e t o p o f a c l o s e t a l o n g w i t ho t h e r d r e a m s t h a t w d i d n ' t h a v e c o n v e n i e n t p l a c e f o r .

W e l l , r e s c u e t h a t C o m m o d o r e f r o m t h d a r k c o r n e r i t ' s h i d i n g i b e c a u s e h e r e ' s h a n d y l i t t l e c o m p u t e r d e s k t h a t a l m o s t a n y o n ec a b u i l d f r o m l e s s t h a n o n s h e e t o 3 / p l y w o o d . T h i s s i m p l ed e s k w i l l e a s i l y h o l d y o u r c o m p u t e r , m o n i t o r , d i s k d r i v e , c a s s e t t e

d e c k , p r i n t e r , a n m a y b e e v e n h a v e s o m e r o o m l e f t f o y o u r b a c ki s s u e s o T h T r a n s a c t o r .

T h d e s k i c o n s t r u c t e d f r o m j u s t p i e c e s o p l y w o o d ;

( 5 ) 3 / 4 x 1 1 x 3 8( 1 ) 3 / 4 x 2 3 x 3 8( 2 ) 3 / 4 x 3 x 2 1

A l l o f t h j o i n t s m a b j u s t c a r e f u l l y g l u e d a n n a i l e d t o g e t h e r , o i y o u h a v e a c c e s s t t h p r o p e r e q u i p m e n t , y o m i g h t t r d a d o i n gt h s i d e s b e f o r e a t t a c h i n g t h e t h r e e h o r i z o n t a l s h e l v e s .

G o o d l u c k , w h o p e t h a t y o u r c o m p u t e r w i l l b r i n g y o m a n y m o r eh o u r s o c o m p u t i n g e n j o y m e n t n o t h a t y o u , a n i t h a v e s i m p l ea n c o n v e n i e n t d e s k a w h i c h t w o r k , p l a y , a n d r e a m .

T h T r a n s a c t o r 7 V o l u m e 5 I s s u e 0

Page 80: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 80/88

R e t h i n k i n gD A T A f i c a t i o nE v e r y n o a n t h e n w a r e f a c e d w i t h t h e n e c e s s i t y o c o n v e r t i n gm e m o r y i n t o D A T A s t a t e m e n t s , w h e t h e r i t ' s s p r i t e d e s c r i p t i o n s ,m a c h i n e l a n g u a g e , c h a r a c t e r s e t s , o s o m e t h i n g e l s e . M o s t o u h a v e w r i t t e n o o t h e r w i s e o b t a i n e d p r o g r a m s t d t h i s f i d d l y j o bf o r u s .

E v e n s o i t ' s h a r d t b t h r i l l e d a b o u t t h r e s u l t . D A T A s t a t e m e n t st a k e u l o o m e m o r y r e l a t i v e t t h d a t a t h e y a c t u a l l y e m b o d y ,a n t h p r o c e s s o p o k i n g t h d a t a b a c k i n t o m e m o r y i s l o w o n e .T h c o m p e n s a t i n g a d v a n t a g e , o c o u r s e , i t h a t d a t a k e e p s c o p a n y w i t h B A S I C p r o g r a m m o r e c o m f o r t a b l y i n t h i s f o r m t h a n i a n o t h e r .

I w o u l d b n i c e , w o u l d n ' t i t t p r e s e r v e t h a t a d v a n t a g e w h i l em i n i m i z i n g t h d r a w b a c k s ? I w a w i t h t h a t t h o u g h t t h a t w r o t et h D A T A f i e r .

T h D A T A f i e r a l s o c r e a t e s D A T A s t a t e m e n t s , a n l i n k s t h e m i n t om e m o r y i t h e u s u a l w a w i t h t h d y n a m i c k e y b o a r d t e c h n i q u e .B u i n s t e a d o b e i n g e n c o d e d a d e c i m a l n u m b e r s s e p a r a t e d b c o m m a s , i t h i s c a s e e a c h b y t e o d a t a i r e p r e s e n t e d b y t w ol e t t e r s , a n t h p a i r s o f l e t t e r s a r c o n c a t e n a t e d w i t h o u t c o m m a si n t o s t r i n g s u t 7 c h a r a c t e r s i l e n g t h .

C o n s i d e r h o t h a t s a v e s m e m o r y . O n b y t e o d a t a e n c o d e dd e c i m a l l y r e q u i r e s , o a v e r a g e , m o r e t h a n t w a n h a l f b y t e s o m e m o r y , p l u s a n o t h e r b y t e f o t h c o m m a . E n c o d i n g t h a t s a m eb y t e a p a i r o l e t t e r s r e s u l t s i n s a v i n g o n e a r l y 5 p e c e n t .

A l o n g w i t h t h D A T A s t a t e m e n t s , t h D A T A f i e r a l s o p r o v i d e ss h o r t m a c h i n e l a n g u a g e r o u t i n e t p o k e t h e n c o d e d d a t a i n t om e m o r y . T g e a i d e a o i t s p e e d o n c e e n c o d e d t h e n t i r e C 6 B A S I C R O M , a l 8 1 9 2 b y t e s o i t a p r o c e s s t h a t t o o k s e v e r a lm i n u t e s t c o m p l e t e . T h D A T A f i e r p o k e d i a l b a c k i n l e s s t h a nf o u r s e c o n d s . T r t h a t w i t h d e c i m a l l y e n c o d e d D A T A s o m e t i m ea n s e h o y o d o

U s i n g T h D A T A f i e r

T y p e R U N , a n R E T U R N .

T h p r o g r a m w i l l p r o m p t y o w i t h : D / D I S K M / M E M O R Y ?R e p l y w i t h i t h p r o g r a m y o a r i n t e n d i n g t d a t a f y i o d i s k( d r i v e o n l y ) . Y o w i l l b e a s k e d t e n t e r t h e f i l e n a m e , t h e n t h D a t a f i e r w i l l d t h r e s t .

I t h p r o g r a m i i m e m o r y , t y p e M T h D a t a f i e r w i l l p r o m p t y o uw i t h :

" S T A R T , E N D ?E n t e r t h s t a r t a n d e n d a d d r e s s e s i h e x a d e c i m a l , j u s t a y o w o u l d w i t h t h M a c h i n e L a n g u a g e M o n i t o r , b u t s e p a r a t e t h en u m b e r s w i t h c o m m a . R e m e m b e r t h a t t h e n a d d r e s s y o g i v es h o u l d b o n b y t e b e y o n d t h e a r e a y o u w a n t D A T A f i e d . P r e s sR E T U R N .

N o t h D A T A f i e r g o e s t w o r k , a n w o n ' t s t o p t i l l i t ' s d o n e . Y o u ' l ls e e t h i n g s h a p p e n i n g o t h s c r e e n t h a t ' s t h d y n a m i c k e b o a r d t e c h n i q u e i a c t i o n .

N i c k S u l l i v a nS c a r b o r o u g h , O n t .

W h e n f i n i s h e d , t h f i r s t 3 l i n e s ( 0 - 3 6 ) a r e e r a s e d b t h s u b r o ut i n e a l i n e 3 1 . D e l e t i n g l i n e s c a n b e a c c o m p l i s h e d u s i n gv a r i a t i o n o t h s a m e t e c h n i q u e u s e d t e n t e r l i n e s . H o w e v e r , t h t e c h n i q u e u s e d i t h i s s u b r o u t i n e e l i m i n a t e s t h e t r o u b l e o d e l e ti n e a c h l i n e i n d i v i d u a l l y . F i r s t i t r a c k s t h l i n e l i n k p o i n t e r s f o 3 l i n e s . T h e n i a d j u s t s t h l i n k p o i n t e r o t h f i r s t l i n e s t h a t i p o i n t s t t h l i n k p o i n t e r o l i n e 8 9 9 7 . B s i m p l y e r a s i n g l i n e 0 B A S I C w i l l r e m o v e a l t h e b y t e s u t t h e n o l i n e 3 6 . J u s t b e f o r et h i s i d o n e , l i n e 3 a d j u s t s t h h i g h b y t e o t h E n d - o f B A S I Cp o i n t e r a t h e d i t o r d o e s n o a c c o u n t f o m o v e a c r o s s m o r e t h a no n p a g e b o u n d a r y .

T h r e s u l t w i l l b s u b r o u t i n e b e g i n n i n g a l i n e n u m b e r 9 0 0 0 .Y o c a m e r g e t h s u b r o u t i n e i n t o a n y p r o g r a m t h a t r e q u i r e s t h d a t a ( o n e w a t d t h m e r g e i w i t h t h T r a n s B A S I C A D c o m m a n d s e e l s e w h e r e i t h i s i s s u e ) . T h i n s t r u c t i o n G O S U B9 0 0 0 w i l l d t h w o r k o r e a d i n g t h D A T A s t a t e m e n t s a n p o k i n gt h e m i n t o m e m o r y . N a t u r a l l y , i y o h a v e a n o t h e r D A T A s t a t em e n t s p r e c e d i n g l i n e 9 0 0 0 i y o u r p r o g r a m t h e y m u s t a l r e a d yh a v e b e e n r e a d a t h t i m e t h G O S U B 9 0 0 0 i n s t r u c t i o n i g i v e n .

T h m e t h o d o e n c o d i n g t h d a t a a a p a i r o f a l p h a b e t i c c h a r a c t e r si e x t r e m e l y s i m p l e : e a c h c h a r a c t e r r e p r e s e n t s o n n y b b l e o t h h e x a d e c i m a l d a t a b y t e . T h l e t t e r ' A r e p r e s e n t s 0 e a c h s u b s eq u e n t l e t t e r r e p r e s e n t s a s u b s e q u e n t h e x a d e c i m a l d i g i t . ' A A ' ,t h e r e f o r e , e n c o d e s z e r o b y t e ; ' D M ' w o u l d b e q u i v a l e n t t 3 * 1 6 + 1 2 $ 3 C , o 6 0 T h h i g h e s t l e t t e r u s e d i P w h i c hr e p r e s e n t s t h e h e x a d e c i m a l d i g i t F

T h o n l y d i s a d v a n t a g e o D A T A f i e d D A T A i t h a t i i e v e n h a r d e rt r e a d t h a n i t d e c i m a l c o u n t e r p a r t . H o w e v e r , t h D A T A f i e r w a s n ' td e s i g n e d f o p u b l i s h i n g p r o g r a m s f o h a n d e n t r y . I t ' s m a i n p u p o s e i f o i n c l u d i n g y o u r m a c h i n e l a n g u a g e s u b r o u t i n e s a p a r t o y o u r B A S I C t e x t . U s i n g a n t y p e o l o a d e r w i l l m a k e y o u r h y b r i dp r o g r a m s m o r e t r a n s p o r t a b l e , b u t D A T A f i e d D A T A i v i a b l ea l t e r n a t i v e f o p r o g r a m s t h a t w i l l a l m o s t n e v e r b e ' t r a n s p o r t e d ' b h a n d .

E d i t o r ' s N o t e

B e t w e e n t h t i m e t h T r a n s B A S I C a r t i c l e w a p r e p a r e d a n t h i so n e , N i c k h a b e c o m e t h n e E d i t o r f o T P U G M a g a z i n e .

O n l a s t n o t e a b o u t t h p r o g r a m . . y o ' I n o t i c e s e v e r a l s p a c e s i t h m i d d l e o l i n e 1 5 . T h r e a s o n ? L i n e 1 p r i n t s v a r i a b l e d e f i n it i o n s a t h b o t t o m o e a c h s c r e e n d u r i n g t h D T A f i c a t i o n p r o c e s s .T h i s w i l l a l w a y s t a k e t w l i n e s . W h e n B A S I C p r i n t s v a r i a b l e , t h f i r s t c h a r a c t e r o u t p u t i ' C u r s o r R i g h t ' . / t h a t c u r s o r r i g h t c h a r a ct e i t h o n r e s p o n s i b l e f o m o v i n g o n t o t h s e c o n d l i n e , t h s c r e e n l i n e w r a p t a b l e w i l l n o b u p d a t e d s t h a t t h t w l i n e s a r t r e a t e d a o n l i n e t h a t h a ' w r a p p e d a r o u n d ' . W h e n t h C a r r i a g eR e t u r n i d r o p p e d o n t o t h i s s t r i n g , t h G O T O c o m m a n d w i l l n o b e x e c u t e d u n l e s s s e c o n d C a r r i a g e R e t u r n i s e n t . T o a v o i d t h i s , i i n e c e s s a r y t h a v e t h s e c o n d l i n e e n t e r e d a s t h r e s u l t o S p a c e s .D e p e n d i n g o t h c o l u m n w i d t h o y o u r p a r t i c u l a r m a c h i n e , t h e s es p a c e s w i l l n e e d t b i n s e r t e d t e n s u r e t h t w l i n e s b e c o m e o n e .A a r t i c l e o t h s c r e e n w r a p t a b l e w i l l b a p p e a r i n g i n o t o d i s t a n t T r a n s a c t o r . M . E d .

7 V o l u m e 5 I s s u e 0

Page 81: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 81/88

C o n v e r t i n g T h D a t a f i e rF o r O t h e r C o m m o d o r e M a c h i n e sA s s h o w n , t h D a t a f i e r w i l l w o r k o t h C o m m od o r e 6 o n l y . T u s i w i t h o t h e r m a c h i n e sc h a n g e s m u s t b m a d e .

L i n e c o n t a i n s t h i n s t r u c t i o n 3 5 w h i c h s e t st h n u m b e r o m e m o r y b y t e s t b e e n c o d e d o e a c h D A T A l i n e . T h i s d e p e n d s o n t h s c r e e n s i z e ,a n f o o t h e r m a c h i n e s s h o u l d b e s e a f o l l o w s :

V 1 C - 2 0 G = 3 94 0 - C o l u m n P E T s 3 8 0 - C o l u m n P E T s 3

F o t h V I C - 2 0 m a k e t h e f o l l o w i n g c h a n g e s i l i n e 7

K D b e c o m e sP O K E 1 9 8 , 1 0 b e c o m e s P O K E 1 9 8 , 5

A g a i n f o t h V I C - 2 0 , c h a n g e i n l i n e t 4

O t h e r c h a n g e s i t h f i r s t p a r t o f t h p r o g r a m( b e f o r e l i n e 9 0 0 0 ) a f f e c t B A S I C 2 . a n B A S I C 4 . m a c h i n e s o n l y , n o t t h e V I C - 2 0 . T h c h a n g e s a r e :

L i n e s 7 2 3 , 2 4 : C h a n g e 1 9 t 1 5 L i n e s 8 2 3 , 2 4 : C h a n g e 6 3 t 6 2 L i n e 1 5 C h a n g e 1 5 t 1 7 L i n e 2 4 C h a n g e 6 3 t 6 2 L i n e 3 0 C h a n g e 4 t 4

T h r e m a i n i n g c h a n g e s a f f e c t R O r e f e r e n c e s i t h m a c h i n e l a n g u a g e e n c o d e d a D A T A s t a t em e n t s b e g i n n i n g a l i n e 9 0 1 2 . T h r e p l a c e m e n tD A T A l i n e s a r a f o l l o w s :

V I C - 2 0 :

9 0 0 7 d a t a 3 2 , 2 5 3 , 2 0 6 , 3 2 , 1 5 8 , 2 0 59 0 0 8 d a t a 3 2 , 1 6 3 , 2 1 4 , 1 3 3 , 3 4 , 1 6 29 0 1 7 d a t a 1 0 4 , 1 0 4 , 9 6 , 7 6 , 8 , 2 0 7

T h D A T A f i e r

g o s u b 2 5 g o t o 5

i n p u t " 0 d / d i s k m / m e m o r y " ; d m $i d m $ < > " d a n d m $ < > " m " t h e n e n

2 9 0 2 0 d i d m d t h e n d i n p u t q s t a r t , e n ( h e x ) " ; a $ , b $g o s u b 1 a b g o s u b 1 p o k e 2 5 2 , a / 2 5 6 p o k e 2 5 1 , a - 2 5 6 * p e e k ( 2 5 2 )i b t h e n p r i n t " r a n g e e r r o r " e n

7 3 5 : k 8 p o k e 1 9 8 , 1 0 : p r i n t " E H "8 f o r p 6 3 t o 9 : p o k e p , 1 3 : n e x t : c a : f o r i d t o k : i f c b o r s g o t o 1 3p r i n t i ; c h r $ ( 1 5 7 ) ; " d a t a " ; : f o t

1 p e e k ( c ) : i d t h e n g e t # 2 , m $ a s c ( m $ c h r $ ( 0 ) ) : s 1 1 m - 1 6 * ( i n t ( m / 1 6 ) ) : p r i n t c h r $ ( 6 5 m / 1 6 ) c h r $ ( 6 5 z ) 1 2 c + : - i * ( c b o r s > 0 ) : i f c < b a n d s O t h e n n e x t '1 p r i n t : n e x t i : i f y t h e n1 4 7 i f b o r s t h e n t = 1 91 5 p r i n t " a = " c " : b = " b " : d = " i [ a d d s p a c e s ] : s = " s " : d m = " d m "

: p o k e 1 5 2 , 2 : g o t o " t " 0 " : e n d1 a r i g h t $ ( " 0 0 0 0 " a $ , 4 )1 f o t a s c ( m i d $ ( a $ , i , 1 ) )1 v - 4 8 7 * ( v > 6 4 ) : v * 1 6 t ( 4 - i ) : n e x t : r e t u r n1 d s t r $ ( d - 9 0 2 0 ) : q c h r $ ( 3 4 ) : c l o s e c l o s e2 a 9 0 0 2 p o k e 2 5 1 , " s t r $ ( p e e k ( 2 5 1 ) ) : b $ 9 0 0 3 p o k e 2 5

s t r $ ( p e e k ( 2 5 2 ) ) ^ 2 c $ " 9 0 0 4 f o t o + d $ + : r e a d a $ " p r i n t E & f f i l a $ p r i n t b

p r i n t c 2 p r i n t g o t o 2 42 f o 6 3 U o i + p o k e 1 , 1 3 : n e x t : p o k e 1 9 8 , 4 e n 2 p r i n t " Q o p o k e 6 3 1 , 1 3 p o k e 6 3 2 , 1 4 7 p o k e 1 9 8 , 2g o s u b 3 0 p r i n t " @ e n 2 i n p u t " ^ f i l e n a m e " ; f l $ i f f l $ = " t h e n e n 2 6 o p e n 1 , 8 , 1 5 o p e n 2 , 8 , 2 , f l $ + " , p , r "2 i n p u t # 1 , d e , d e $ , d f , d f : i d e > 1 9 g o t o 2 2 g e t # 2 , a $ , b $ z c h r $ ( 0 ) : a s c ( a $ z $ 2 5 6 * a s c ( b $ z $ ) : = 6 5 5 3 6

r e t u r n2 p r i n t " f l d i s k e r r o r : ^ e e n ( j3 4 3 f o t 3 3 w = p e e k ( w ) + 2 5 6 * p e e k ( w 1 ) i t h e n y3 n e x t3 p o k e y . p e e k ( w )3 5 p o k e + 1 p e e k ( w + 1 )3 p o k e 3 , p e e k ( x 3 ) - i n t ( ( w - y ^ 2 5 6 ) : r e t u r n8 9 9 7 :

B A S I C 2 . 0 :

9 0 0 7 d a t a 3 2 , 2 4 8 , 2 0 5 ,9 0 0 8 d a t a 3 2 1 2 5 , 2 1 3 ,9 0 1 4 d a t a 2 4 0 , 1 6 , 1 7 7 ,9 0 1 7 d a t a 1 0 4 , 1 0 4 , 9 6

B A S I C 4 . 0 :

9 0 0 7 d a t a 3 2 , 2 4 5 , 1 9 0 ,9 0 0 8 d a t a 3 2 , 1 8 1 , 1 9 9 ,9 0 1 4 d a t a 2 4 0 , 1 6 , 1 7 7 ,9 0 1 7 d a t a 1 0 4 , 1 0 4 , 9 6

3 2 1 3 3 ,

3 1 7 6

3 2 1 3 3 ,

3 1 7 6

1 5 9 ,3 4

2 0 1 ,3

1 5 2 ,3 4

2 0 1 ,0

2 0 1 6

8 2 0

1 8 1 6

8 1 9

8 9 9 88 9 9 99 0 0 09 0 0 1

e n

f o r e a d

3 1 t 3 8 p o k e i , n e x t

9 0 0 5 s y 3 1 9 , a $ n e x t : r e t u r n9 0 0 69 0 0 79 0 0 89 0 0 99 0 1 09 0 1 19 0 1 29 0 1 39 0 1 4

d a t ad a t ad a t ad a t ad a t ad a t ad a t a

3 2 , 2 5 3 , 1 7 4 ,3 2 1 6 3 , 1 8 2 ,

0 1 6 0 , 2 5 5 ,1 0 1 0 1 0 3 2 , 1 0 2 , 1

2 5 1 , 2 3 0 , 2 5 1 ,2 5 2 , 2 0 8 , 2 3 2 ,

d a t a 2 4 0 , 1 6 , 1 7 7 ,9 0 1 5 d a t a9 0 1 69 0 1 79 0 1 8

1 7 6 , 1 3 , 2 0 1 ,d a t a 2 3 3 , 1 4 1 d a t a 1 0 4 , 1 0 4 , 9 6

3 2 , 1 5 8 ,1 3 3 , 3 6

3 2 , 1 0 2 ,1 0 , 1 3 3 ,

5 3 7 2 0 8 , 2 3 6 ,2 0 0 , 1 9 6 ,

3 4 , 2 0 1 ,6 5 1 4 4 ,1 5 , 1 6 ,7 6 8

1 7 1 6

3 1 2 2 3

3 8

1 7

T h T r a n s a c t o r 7 V o l u m e 5 I s s u e 0

Page 82: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 82/88

I ' L LT H E .T H N N K V O U

Y O 3 U S 1B O U & H T

T R O U B L ET H F L Q T S K VD \ 5 K . I V O U R

V J H K T G . R E K TI ' L L 3 U S T K S K f A XB I 3 . O D R . f U 3 T S W

H I D I S K

U K T E R , H ^ T H I F V U E R t ' S O N E

T H I N & H K T E . ,I T ' 5 S M N K T

M O U T HV 1 L L N N 5 )

D R O P P E D V O U RL E F T . '

l M U U L T H ES I T U R V I Q M O \ ) E R ,O N E T H \ N G B C O M E S C L E W . .

D L 0 T 5 K Y 1 f L E H D E R I T H ? \ E L OT E C H N O L O G Y . H R E C E N T L Y P E

E C T E D F C H I P T H R T E F \ N B R T T R C H E D T OT H t 5 V \ U U _ . I T \ \ m T \ J Q P C f i 5 \ B L E L G E ^ . I C P v N B L B t D P R n i N D C O N T R O L t » E \ l \ C E ,O P S n t N T H M a B

t E T H P ND

U K S U P E R ' H t R O

G . E 7 V T H K T C O P U T E R B N C K F O T H R T C H E P v PS H O T ! B U R L S OB U . f L O T S V - N .

H e U H I E N 5 T H L A S TT I M E T H I ST H I N G W A F E S O M EI N F O ? ?

C o m p u t e r w i n & s e r v i c e

T h T r a n s a c t o r 8 V o l u m e 5 I s s u e 0

Page 83: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 83/88

d i y o f i r s t r e a l i z et o o r f e a r o m o d e r nT e c h n o l o g y

3 5 C a

M O T H E R T o l d M H E R E W O U U ) B " D f l Y S

L I K E T H I S . . .

T h T r a n s a c t o r 8 V o l u m e 5 I s s u e 0

Page 84: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 84/88

M I C R O C a l c f o C - 6 4T h F u l l S c r e e n C a l c u l a t o rE a s i e r t u s t h a n s p r e a d s h e e t s

M a s t e r i n g Y o u r V I C - 2 0M a s t e r i n g Y o u r C o m m o d o r e 6

B e t t e r W a T L e a r n B A S I CE i g h t m a j o r p r o g r a m s t e n j o y

w h i l e y o a r e l e a r n i n g

M a s t e r i n g Y o u r V I C - 2 0M a s t e r i n g Y o u r C o m m o d o r e 6

T h p r o g r a m s , " r u n - r e a d y " o d i s k ( C - 6 4 ) o t a p e ( V I C - 2 0 ) a n e x p l a i n e d i t h 1 6 0 - 1 9 2 p a g eb o o k , e a c h d e m o n s t r a t e i m p o r t a n t c o n c e p t s o B A S I C w h i l e p r o v i d i n g u s e f u l , e n j o y a b l e s o f t w a r e .P r o g r a m s i n c l u d e :

P l a y e r c o m p o s e s o n g s f r o m y o u r k e y b o a r d ,s a v e , l o a d a n e d i t f o p e r f e c t m u s i cM i c r o C a l c d i s p l a y c a l c u l a t i o n p r o g r a m t h a tm a k e e v e n c o m p l e x o p e r a t i o n s e a s yM a s t e r o n o t w p e r s o n g u e s s i n g g a m eC l o c k c h a r a c t e r g r a p h i c s f o d i g i t a l c l o c k

V I C - 2 0 w i t h t a p e b o o k j u s t $ 1 9 . 9 5C - 6 4 w i t h d i s k & b o o k ( a v a i l . S e p t . ) j u s t $ 1 9 . 9 5

L o o k f o u a t h I n t e r n a t i o n a l S o f t w a r e S h o w

T o r o n t o , S e p t e m b e r 2 0 - 2 3

M I C R O C a l c f o C - 6 4T h i s o n - s c r e e n c a l c u l a t o r c o m e s w i t h d i s k e t t e a n 4 8 - p a g e m a n u a l o f f e r i n g w i d e v a r i e t y o f u s e f u ls c r e e n s , a n g r e a t w a t o l e a r n B A S I C e x p r e s s i o n si y o d o n ' t a l r e a d y k n o w t h e m .

U n l i m i t e d c a l c u l a t i o n l e n g t h c o m p l e x i t yS c r e e n s c a n b l i n k e d a n s a v e d o d i s k / c a s s e t t eB u i l d l i b r a r y o c u s t o m i z e d s c r e e n sP r o v i d e f o r m a t t e d p r i n t e r o u t p u t

D i s k e t t e 4 8 - p a g e m a n u a l j u s t $ 2 9 . 9 5

F o t h F r e s h e s t B o o k s , B u D i r e c t !N p r e h a n d l e d b o o k s w i t h b e n t c o r n e r sB o o k s c o m e d i r e c t t o y o u r d o o rN t i m e w a s t e d s e a r c h i n g s t o r e t s t o r e2 4 h o u r s f r o m o r d e r r e c e i p t t s h i p m e n tN s h i p p i n g / h a n d l i n g c h a r g e sN s a l e s t a ( e x c e p t 5 M r e s . )C h e c k , M O , V I S A / M C a c c e p t e d ( p r e p a i d o n l y )

T h C o m p u t e r i s t B o o k c a r tP . O . B o 6 5 0 2 , C h e l m s f o r d , M 0 1 8 2 4

F o f a s t e r s e r v i c e , p h o n e : 6 1 7 / 2 5 6 3 6 4 9 .

Page 85: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 85/88

C O M M O D O R E O W N E R SJ o i n t h e w o r l d ' s l a r g e s t , a c t i v e C o m m o d o r eO w n e r s A s s o c i a t i o n . W A

A c c e s s t t h o u s a n d s o p u b l i c d o m a i n p r o g r a m so t a p e a n d i s k f o y o u r C o m m o d o r e 6 4 V I 2 a n d P E T / C B M .M o n t h l y C l u b M a g a z i n eA n n u a l C o n v e n t i o nM e m b e r B u l l e t i n B o a r dL o c a l C h a p t e r M e e t i n g s

S e n d $ 1 . 0 0 f o P r o g r a m I n f o r m a t i o n C a t a l o g u e .( F r e e w i t h m e m b e r s h i p ) .

M e m b e r s h i pF e e s f o 1 M o n t h s

C a n a d a $ 2 C a n .U . S . A . $ 2 U . S .O v e r s e a s $ 3 U . S .

T . P . U . G . I n c .D e p a r t m e n t " M

1 9 1 2 A A v e n u e R o a d , S u i t eT o r o n t o , O n t a r i o , C a n a d a M 5 4 A

L E U K N O W W H I C H M A C H I N E Y O U S

0 0 C H O O S E C O M A LU S E R S |

( 1 d i s k b a s e d c o m a l v e r s i o n 0 . 1 4C O M A L S T A R T E R k i t — C o m m o d o r e 6 4 - " S y s t e m D i s k , T u t o r i a lD i s k ( i n t e r a c t i v e b o o k ) , A u t o R u D e m o D i s k , R e f e r e n c ec a r d a n c o m a l f r o m t b o o k .S 2 9 . 9 5 p l u s S h a n d l i n g

( 2 p r o f e s s i o n a l c o m a l v e r s i o n 2 . F u l l 6 4 C o m m o d o r e 6 4 C a r t r i d g eT w i c e a P o w e r f u l , T w i c e a F a s tS 9 9 . 9 5 p l u s S h a n d l i n g ( n m a n u a l o d i s k s )D e l u x e C a r t r i d g e P a c k a g e i n c l u d e s :c o m a l h a n d b o o k 2 n E d i t i o n , G r a p h i c s a n S o u n dB o o k , D e m o D i s k s a n t h c a r t r i d g e ( s e l l s f o o v e rS 2 0 0 i E u r o p e ) . T h i s i w h a t e v e r y o n e i t a l k i n g a b o u t .S 1 2 8 . 9 0 p l u s S h a n d l i n g ( U S A C a n a d a o n l y )

C A P T A I N c o m a l R e c o m m e n d s :T h C O M A L S T A R T E R K I i i d e a l f o h o m e p r o g r a m m e r . I h a s p r i t e a n g r a p h i c s c o n t r o l ( L O G O c o m p a t i b l e ) . r e a lb a r g a i n — S 2 9 . 9 5 f o f u l l d i s k s a n u s e r m a n u a l .S e r i o u s p r o g r a m m e r s w a n t t h e D e l u x e C a r t r i d g e P a c k a g e .F o S 1 2 8 . 9 0 t h e y g e t h b e s t l a n g u a g e o a n b i c o m p u t e r ( t h e s u p p o r t m a t e r i a l s a r e s s e n t i a l d u t t h i m m e n s e p o w e r o P r o f e s s i o n a l C O M A L ) .

O R D E R N O W :C a l l T O L L - F R E E : 1 - 8 0 0 - 3 5 6 - 5 3 2 4 e x t 1 3 0 7 V I S A o r M a s t e r C a r dO R D E R S O N L Y . Q u e s t i o n s a n i n f o r m a t i o n m u s t c a l l o u I n f o L i n e : 6 0 8 - 2 2 2 - 4 4 3 2 . A l o r d e r s p r e p a i d o n l y — n o C . O . D .S e n d c h e c k o m o n e y o r d e r i U D o l l a r s t o

C O M A L U S E R S C R O U P , U . S . A . , L I M I T E D5 5 0 1 G r o v e l a n d T e n , M a d i s o n , W 5 3 7 1 6T R A D E M A R K S : c o m m o d o r e 6 o c o m m o d o r e E l e c t r o n i c s L t d ; C a p t a i n c o m a l o C O M A L U s e r s C r o u p , U . S . A . , L t

e s t i m a t e d

P r o d u c t s f o t h C o m m o d o r e 6

W a t e r l o o S t r u c t u r e d B A S I CA l r e a d y w i d e l y u s e d o t h C o m m o d o r e P E T ,t h p a c k a g e a u g m e n t s t h s t a n d a r d B A S I C w i t h :

S t r u c t u r e d P r o g r a m m i n g S t a t e m e n t sp r o g r a m s c a n b e w r i t t e n w i t h p r o p e r s t y l e .P r o c e d u r e s e l i m i n a t e t h u s o G O S U B ;i n s t e a d C A L L n a m e d p r o c e d u r e sA d d i t i o n a l C o m m a n d s i n c r e a s e d e a s e o u s w i t h A U T O , D E L E T E a n R E N U M B E Rc o m m a n d s

E a c h p a c k a g e c o n t a i n s :c a r t r i d g e c o n t a i n i n g s o f t w a r ec o m p r e h e n s i v e t e x t b o o k c o n t a i n i n g b o t hp r i m e r a n a r e f e r e n c e m a n u a l

P r i c e : $ 9 9 . 0 0 ; $ 7 9 . 0 0 f o a d d i t i o n a l p a c k a g e s i s a m e o r d e r

W A T C O M P a s c a lT h i s i n t e r p r e t e r s u p p o r t s t h f u l l A N S I s t a n d a r dP a s c a l ( w i t h o n o m i s s i o n ) a n f e a t u r e s :

i n t e g r a t e d f u l l - s c r e e n e d i t o ri n t e r a c t i v e d e b u g g e rs u p p o r t f o p r i n t e r , d i s k a n c a s s e t t eg r a p h i c s l i b r a r yp e e k a n d p o k e f u n c t i o n s

E a c h p a c k a g e c o n t a i n sc a r t r i d g e a n d i s k c o n t a i n i n g t h e s o f t w a r ec o m p r e h e n s i v e t e x t b o o k c o n t a i n i n g b o t hp r i m e r a n r e f e r e n c e m a n u a l

P r i c e : $ 1 4 9 . 0 0 ; $ 9 9 . 0 0 f o a d d i t i o n a l p a c k a g e s i s a m e o r d e r

O r d e r i n g I n f o r m a t i o nO r d e r f o r m s a n d / o r a d d i t i o n a l i n f o r m a t i o n m a b o b t a i n e d f r o m :

W A T C O M P r o d u c t s ,4 1 P h i l l i p S t r e e t ,W a t e r l o o , O n t a r i oC a n a d a , N 2 3 X

( 5 1 9 ) 8 8 6 - 3 7 0 0T e l e x : 0 6 - 9 5 5 4 5 8

A d d i t i o n a l t e x t b o o k s a r a l s o a v a i l a b l e . S e m i n a r so P a s c a l a n B A S I C a r o f f e r e d r e g u l a r l y .

Page 86: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 86/88

T h T e c h / N o w j J o

P A Y S$ 4

p e p a g e f o a r t i c l e s

W e ' r e a l s o l o o k i n g f o p r o f e s s i o n a l l y

d r a w n c a r t o o n s !

S e n d a l m a t e r i a l t o

T h E d i t o rT h T r a n s a c t o r

5 0 S t e e l e s A v e n u eM i l t o n , O n t a r i o

L 9 3 P

I s s u e *

V o l u m e E d i t o r i a l S c h e d u l eT h e m e C o p y D u P r i n t e d R e l e a s e D a t e

G r a p h i c s a n d S o u n dT h T r a n s i t i o n t M a c h i n e C o d eS o f t w a r e P r o t e c t i o n P i r a c yB u s i n e s s a n E d u c a t i o nH a r d w a r e a n P e r i p h e r a l sP r o g r a m m i n g A i d s U t i l i t i e s

F e b lA p J u A u g lO c t lD e

M a 1

M a 2 J u l 2 3

S e p l 7N o v l 9J a 1

V o l u m e E d i t o r i a l S c h e d u l eC o m m u n i c a t i o n s N e t w o r k i n g F e b M a 2 L a n g u a g e sI m p l e m e n t i n g T h S c i e n c e sH a r d w a r e S o f t w a r e I n t e r f a c i n gR e a l L i f e A p p l i c a t i o n s

A p J u A u g lO c t l

M a 2 J u 1

S e p 2 1N o v l 9

A p r i l

J u n eA u g u s t

O c t o b e rD e c e m b e rF e b r u a r y 1 / 8 5

A p r i l 1 / 8 5J u n eA u g u s tO c t o b e rD e c e m b e r

A d v e r t i s e r s a n d A u t h o r s s h o u l d h a v e m a t e r i a l s u b m i t t e d n l a t e r t h a n t h ' C o p y D u e ' d a t e t b i n c l u d e d

w i t h t h e r e s p e c t i v e i s s u e .

T H W A I TI O V E R

T h c o m m o d o r e 6 4 C O M A L 2 . C a r t r i d g ei b e i n g p r o d u c e d f o n o 8 d e l i v e r y .

F u l l 6 4 R O C a r t r i d g e — 3 0 K F r e e U s e r M e m o r yE m p t y s o c k e t f o r u s e r E P R O M ( 8 K , 1 6 o 3 2 K )L O C O 1 c o m p a t i b l e t u r t l e g r a p h i c s ( w i t h a b b r e v i a t i o n s )

E a s y S p r i t e a n i m a t i o n — L o a d , S a v e , L i n k S h a p e sI n t e r r u p t d r i v e n M u s i c — F u l l c o n t r o l o f S I u s e r d e f i n a b l e f o n t s — L o a d , S a v e , L i n k F o n t sT h r e e d i f f e r e n t s c r e e n d u m p s i n

H i - R e s G r a p h i c s , M u l t i - c o l o r G r a p h i c s , T e x tE r r o r H a n d l e r , E x t e r n a l P r o c e d u r e s , T r a c e C o m m a n d sP r o t e c t e d i n p u t , B a t c h C o m m a n d F i l e C a p a b i l i t yE a s i l y d e f i n a b l e F u n c t i o n K e y s

( i . e . , F w i l l R U a n p r o g r a m f r o m d i r e c t o r y )B u i l t i L I N K c o m m a n d f o M a c h i n e C o d e R o u t i n e sH E X a n d b i n a r y a c c e p t e d — A S C I I c o n v e r s i o n b u i l t i

A l p r e p a i d a d v a n c e o r d e r s r e c e i v e f r e e :c o m a l h a n d b o o k , S e c o n d E d i t i o n ( i n c l u d e s C a r t r i d g e )I n t r o d u c t i o n t 2 . 0 B u i l t i P a c k a g e s B o o k

( G r a p h i c s , T u r t l e , S p r i t e s , S o u n d , F o n t , . . T W d i f f e r e n t d e m o d i s k s ( 1 5 4 1 f o r m a t )w h i t e c u s t o m m o l d e d c a s e f o r d i s k s a n b o o k

A L F O R O N L Y $ 9 9 . 9 5( $ 1 7 5 v a l u e — n e a r l y h a l f p r i c e )D u t h i g h d e m a n d o r d e r s w i l l b f i l l e d o f i r s t c o m e b a s i s .S e n d c h e c k o M o n e y O r d e r i U D o l l a r s p l u s S h a n d l i n g t o

C O M A L U S E R S C R O U P , U . S . A . , L I M I T E D5 5 0 1 G r o v e l a n d T e n , M a d i s o n , w 5 3 7 1 6

p h o n e : ( 6 0 8 ) 2 2 2 - 4 4 3 2v i s a a n m p r e p a i d o r d e r s m a c a l l t o l l f r e e : 1 - 8 0 0 - 3 5 6 - 5 3 2 4

e x t e n s i o n 1 3 0 7c o m m o d o r e 6 i t r a d e m a r k o C o m m o d o r e E l e c t r o n i c s L t d

M I D N I T ES O F T W A R E G A Z E T T E

T h

P A P E RF i v e y e a r s o e e r v l c e t t h P E c o m m u n i t y .

T h I n d e p e n d e n t U . S . m a g a z i n e f o u s e r s o C o m m o d o r e b r a n d c o m p u t e r s .

E D I T O R S : J i a n E l l e n S t r a s m aS a m p l e I s s u e f r e e o r e q u e s t , f r o m :

6 3 M A P L E M T Z I O N . I 6 2 5 4 9 U S

Page 87: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 87/88

B a c k I s s u e sI S S U E 1 — J A N . ' 8 $ 4 . 0 0T h 6 v t h P e a n u t ! T h c o p u t e r a s c o m m u n i c a t i o n s d e v i c e !P r o t e c t o ' s B i l l B a d g e r i n t e rv i e w e d ! A n r e a d y t o e n t e r : t h M u l t i D r a w 6 g r a p h i c s s y s t e m !T h I n t e r r u p t M u s i c M a k e r /E d i t o r ! P e e k a M e m o r y ! P r g r a m m i n g S e q u e n t i a l F i l e s !

D o n ' t p u n c h a n o t h e r k e w i t h o u t a c o m p l e t e c o l l e c t i o no A h o y ! a n t h p r o g r a mm i n g s t r a t e g i e s a n p r o d u c ta n a l y s e s e a c h i s s u e p r o v i d e s .

O r d e r w h i l e s u p p l i e s l a s t !

E - • . . . — § 3

Y < h : i iM £ _ . ■ °

I

I S S U E # 2 — F E B . ' 8 $ 4 . 0 0I l l u s t r a t e d t o u r o t h 1 5 4 1 d i s kd r i v e ! S y n a p s e ' s I h o r W o l o s e n k oi n t e r v i e w e d ! U s e r s g r o u p s ! A r t if i c i a l i n t e l l i g e n c e ! A n r e a d y t e n t e r : M u s i c M a k e r P a r t I I N i g h t A t t a c k ! P r o g r a m m i n g R e a t i v e F i l e s ! S c r e e n M a n i p u l a t i o no t h C o m m o d o r e 6 4

T o \ i m < h m h s i .» N I K S

< \ \ V MK K A I t T I I I S ?i k n o i :P R E S ST H E S E K K W &T t R X T I I K R K i K

I S S U E # 3 — M A R . ' 8 $ 4 . 0 0A n a t o m y o t h 6 4 ! P r i n t e r I nt e r f a c i n g f o t h 6 a n V I C !E d u c a t i o n a l s o f t w a r e : f i r s t o s e r i e s ! C o m m o d a r e s ! A n r e a d y t e n t e r : S p a c e L a n e s !R a n d o m F i l e s o t h 6 4 E a s yA c c e s s A d d r e s s B o o k ! D y n a m i cP o w e r f o y o u r 6 4

I S S U E # 4 - A P R . ' 8 4 $ 4 . 0 0P e t s p e e d a n d E a s y S c r i p tt u t o r i a l s ! P r i n t e r i n t e r f a c i n g a n e d u c a t i o n a l s o f t w a r e g u i d e c o t i n u e d ! L o w e r c a s e d e s c e n d e r so n y o u r 1 5 2 5 ! L a s e r d i s c ! T h D a l l a s Q u e s t A d v e n t u r e G a m e !A n r e a d y t e n t e r : A p p l e P i e !L u n a r L a n d e r ! N a m e t h a t S t a r !

I S S U E # 5 — M A Y ' 8 4 $ 4 . 0 0T h F u t u r e o C o m m o d o r e ! I s i d e B A S I C p r o g r a m s t o r a g e !C - 6 4 S p r e a d s h e e t s ! M e m o r yM a n a g e m e n t o t h V I a n 6 4 E d u c a t i o n a l S o f t w a r e G u i d ec o n t i n u e s ! A n r e a d y t e n t e r :M a t h M a s t e r ! A i A s s a u l t ! B i o -r h y t h m s ! V I 2 C a l c u l a t o r !

S e n d c o u p o n o f a c s i m i l e t o A h o y ! B a c k I s s u e s , I o I n t e r n a t i o n a l I n c . , 4 W e s t 3 4 t h S t r e e t — S u i t e 4 0 7 , N e Y o r k , N 1 0 0 0 1

P l e a s e S e n d M T h F o l l o w i n g :C o p i e s o i s s u e n u m b e rC o p i e s o i s s u e n u m b e rC o p i e s o i s s u e n u m b e r

N A M EA D D R E S S

E n c l o s e d P l e a s e F i n d M C h e c k o M o n e y O r d e r f o

( O u t s i d e t h U S p l e a s ea d $ 1 . 0 0 f o e v e r y c o p y )

C I T Y _S T A T E .Z I C O D E .

Page 88: The Transactor V5 05 1985

8/7/2019 The Transactor V5 05 1985

http://slidepdf.com/reader/full/the-transactor-v5-05-1985 88/88

T h C o m p l e t e C o m m o d o r eI n n e r S p a c e A n t h o l o g y

w i l l l o o k l i k e t h i s :