53
D D VOLUME, ISSUES&9 AN AR ESCO PUB L ICATION MA RCH IAP R I L 1980, $4.00 {ENT,N OF CONTENTS* EDIT0RIAI... Tom Swan..... .....2.08/Q9.03 REA,DER T/Or., ..:....Subscribers. ..... .2,08/Og.O? CH]P-B CHIP-BE. . . . . . .G Detj-11-j-eux. . . . . . . . . .,2,58/Q9.L5 Invert..... ...Robert T-,indley".. .2.O8/O9,IB Programming Hints......r.....H C Wil-1 IV.. Software Changes & Other Good Stuff George Ziniew!"^.. . . . . .2.08/A9.24 GA}IES IIFE....r . ..... Tom Swan..... .....2.o8/o9.2? Programming Hints. . . . ; . .H C Will IV. . ; . . . . . . . . .2.08;'/09.29 SPACE WARS Speeded Up. ., . ., . .Tom,Swan. . ., . . . . . .2.08/.09.29 SIMPLE SIMON Adaptatiorr. . . . . .Tim l,ongcor. . . . ., .2.0.8/.09.30 FIIP-A-R0UI[D..... .,????????????..... .2.O8/O9.30 MUSIC VIP Keyboard...... ..Doug Wolf ..... ....2.08/09.34 BASlC VIP Tiny BASIC Machine T-,anguage Subroutine Irittle Loops r,, r .'. More rinv BASrc Maehine tansuas; SHiffi::ii::. . .z.o'/os.u3 MACHINE IANGUAGE Extended Display Subroutine..C H SCRT Jump Table. r . . .. ... .. ...I,eo .\ *Due to the huge number of articles in.this.issuer the table of contents is continued on the back of thj-s page 2,OB/og ,oL

SHiffi::ii::. . .z.o'/os.u3

Embed Size (px)

Citation preview

Page 1: SHiffi::ii::. . .z.o'/os.u3

D D

VOLUME, ISSUES&9 AN AR ESCO PUB L ICATION MA RCH IAP R I L 1980, $4.00

{ENT,N OF CONTENTS*

EDIT0RIAI... Tom Swan..... .....2.08/Q9.03REA,DER T/Or., ..:....Subscribers. ..... .2,08/Og.O?CH]P-B

CHIP-BE. . . . . . .G Detj-11-j-eux. . . . . . . . . .,2,58/Q9.L5Invert..... ...Robert T-,indley".. .2.O8/O9,IBProgramming Hints......r.....H C Wil-1 IV..Software Changes & Other Good Stuff

George Ziniew!"^.. . . . . .2.08/A9.24

GA}IESIIFE....r . ..... Tom Swan..... .....2.o8/o9.2?Programming Hints. . . . ; . .H C Will IV. . ; . . . . . . . . .2.08;'/09.29SPACE WARS Speeded Up. ., . ., . .Tom,Swan. . ., . . . . . .2.08/.09.29SIMPLE SIMON Adaptatiorr. . . . . .Tim l,ongcor. . . . ., .2.0.8/.09.30FIIP-A-R0UI[D..... .,????????????..... .2.O8/O9.30

MUSICVIP Keyboard...... ..Doug Wolf ..... ....2.08/09.34

BASlCVIP Tiny BASIC Machine T-,anguage Subroutine

Irittle Loops r,, r .'.More rinv BASrc Maehine tansuas; SHiffi::ii::. . .z.o'/os.u3

MACHINE IANGUAGEExtended Display Subroutine..C HSCRT Jump Table. r . . .. ... .. ...I,eo.\

*Due to the huge number of articles in.this.issuer the table ofcontents is continued on the back of thj-s page

2,OB/og ,oL

Page 2: SHiffi::ii::. . .z.o'/os.u3

TABIE 0F CONTENTS (continued)

}I,ARDWARF:Keyboard Reset | . . i . . . . . . . . . . Steve Med.win. r . r . . . . . . . ,2 ,08/Qg . 5Lliny BASIC Disconnect Switch' Randy Holtr.,.....r.,,.,2,08/09.51,Expanded RO-lt{ Monitor.. r . . o . .Randy Holtr . . . . . . . . .,,,,2,08/09.52

MISCET,I,ANEOUSA Tretter To PIPS IIT Owners.Tom Swan...r....r..:....2,08/O9,tzChanges To. VIP-FIOP. . . , . . . . . Carmelo0ortes . . r . . . . . . . .2 .08/09 ,13Set Caffy/Clear Carry! r.....Tom Swan'.... e.,. r., r...2.08/.09.36Correctj.ons For Back Issues.......... ..... 2,08/09,42Rrblisherts Noter r...,.. r...Terry Laudereau... r. ..,,2,Q8/09,42

USER NEWSNew York Atnateur Cornputer Club... ... . .. .. .. .,., .. . ..2,08/09,36

ADVERTlSINGNon-Corunereial..,....... ..... ,,.2,08/09,50ARESCO "Going Out Of, (Hardware ) Business Sale" . r ! . . ,2.08/Q9 ,5ORCA... .. .. ,... . ...... ... ,.,2.08/09,06

See also pages t4, 26, 31, 32., and 33

Entire Contents of vIPER Volume 2 (L979h980) is eopyrighted cby ARESC0, Inc. r P 0 Box 1t42, Colurnbi-a, MD, 2L044.ARESCO, Inc. is not affiliated in any way with RCA, and RCA isnot responsible for the contents of this newsletter. VIP is aregistered trademark of RCA Corporation.

THE VIPER is published ten times per year by ARESCO, Inc. fiOjGolden Hook, Colurnbia MD 210&lt, and rnailed to subscribers on thelast day of each month except June and Deeember.Subscription pri-ce is $ZO for all 10 issues (a11 past and firtureissues) of the cument vo]-ume. Non-USA subseribers should, add$10 for alr-mail del-ivery, .

Second. Class Postage paid in Columbia MD 2LOl+5. USPS zJo}-JjoISSNr 0L99-t566. POSTMASTER: Please send all address ehangesto ARESCO, P 0 Box ttl+zr Columbia MD 2t044,Readers shouLd NOT correspond with RCA concerni-ng VIPER nateriaf.

z,o]/og,oz

Page 3: SHiffi::ii::. . .z.o'/os.u3

EDITORIAL ''THINK DIGITAL''

by Tom Swan

I've been sitting here staring out the window, occasionallyadding my entry in a paper airplane contest wit\ a littLe b9ydownstairs who was hurt playing soceer; If only the big ciruelatree were a few feet more to tfre right and if onfy f coulA get alittle nore lift, I bet I could keep a tiny paper plane up forover a minute considering how high we are from the ground.,Then I asked myself a question I ask at least 20 times a day."OouLd a computer help?-" We1l sure. YoffiId have to ca16u1atepaper size, weiglrt, lift, d.esign, things like that and maybe acomputer could help lead to a superior paper airplane. 0n secondthought, I have more important things to d.o so I suppose I'11stick with the desigr my brother David showed meo Sti1l a VIPcould graphically plot wing shapes, etc. It's an intriguing idea.I, am sure there are plenty of VIPers and other computernikssitting in front of iheir-video screens mentally scratching theinsides of their craniums for something to do witn the things.Just as I an positive there are thousands of writers staring outtheir wi.ndows wond.ering what.to say next. '(Can you hear meclearing my throat just now?)What's a good way to come up with progranming ideas? The best w&5rrI think, is to ask that question "Could a computer help?" Ask Iteven if it seems silly. Look sideways and upside doran at things.But always "think digitaf" and keep TIIE QUESTION in the back ofyour mind. Next time a paper airplane flies past you'll findyourself running for the run switch, a light bulb (f,nOf) burningbrightly above yourNaturally I think the VIPER is an excellent source of programminginspiration too. That's why we're d.oing what we do, but to reallykeep the light bulb lit, we need to hear fpom SourStarting tod.ay, I'11 keep a list of ideas sent in by readers to bepublished in fuIl a couple of months from nowr If everyone sendsin one, idea for a program that they don't have the time or ex-perience to write for themselves, werd end up with a digital pooJ.of id,eas. just waiting to be keyed hexadecimally into memory. Ithink this would be preferable and for sure more creative andproductive than for me or anyone to write the whol.e list, fhen,if y9g find an idea you'd like to tackle, w€ can publish theresults hereoRemember, think digitalt

2 . AB/09 .03

Page 4: SHiffi::ii::. . .z.o'/os.u3

I read Phil Sumnerrs letter this month (see Reader T/O) with greatconcern" Phil- wrote to say he noticed a shift from generalinterest articles in the vrPER toward PrPs rerated material.Since f arn the author of the series and am now editing the VIPERas well, I fear that Phil and other readers may get the erroneousimpression that Tom Swan is somehow "taki-ng over."In no way is this true. I certainly didnrt accept'the position ofeditor with any intention of furthering my own special interests,fhe reason I got involved with the VIP in the first place wasbecause it ains at an audience generally interested in learningmore about computers whatever a personts special interest nay be.The VIPER will eontinue to focus the bulk of its articles on thataudience.There is another side to the question. I have noticed severalpast issues of the VIPER whicli were slanted toward other specialinterests, so much so that they were not of much use to me eithertFor exampler a hardware packed newsletter does Little for someonewho occasional-ly forgets which end of the soldering iron to hold,I am arl incapable fumble fingers with a circuit design and articlesthat discuss electronics in detail just arenrt my cup of tea" Butthe articles deserve to be published,The sarne holds true for other concerns. Last month|s featureswere definitely slanted toward owners of the Tiny Basic Board.The 0ctober issue was particularly hardware oriented. There havebeen musj.c issues. Others may have been weighted heavily towardLS}Z maehine language businesb and I seem to remember a time whenIl".Elf computer_held the gpotlight. (And VIPER readers nippedthat one in the bud properly! )

But whatts the answer? Should we refuse to publish an articleunLess it is total-ly general in nature? I hope not ! VIPers area diversified lot ana-tne newsletter must necessarily reflect theva{ied interests of its readership, The fact is r there will alwaysbe some material in any publication which some readers may notfind interesting or useful or even comprehensibleo To someoneelse, that very sailre article may contain answers to questions longsince given up as lost causes. Damned if you do and damned if youdonrt publish itoI do agree, howeverr that no speeial interest -- hardwar€rassembly language or PfPS should be allowed to gain the upperhand. The purpose of this editorial is to assure Phll and othernon-PIPS readers that I will pay speeial attention to includinggeneral j.nterest material in ea6n anA every issue of the VIPER; -

Each issue should have something potentially useful to €verlorrerAIso, I am a great believer in the adage that the facts speak forthemselves. To that end, I conducted my own survey of the lastfour issues. Just' how much material has been publ-ished whichrequires some special knowledge, hardware or book in order to beused? I define general interest as any article containi.ng software

2 ,oB/09 ,oLt'

Page 5: SHiffi::ii::. . .z.o'/os.u3

that wiLl rwl on an un:nodified VIP without a ke3i',board or otherplug in peripheral. (I did not eonsi,der memory; liuritation'sinceI+f VfpS ire practically the standard rlowr ) A special interestarticle is the opposite of that, artd of course PIPS relatedarticles are of an obvj.ous nature. Reviewsr r€adors letters andadvertisement were not included. Thoug[ most of these are probablygeneral in interest they are not alwalrs' general in subject andwould, only confuse the results. Here are the results of thesurvey fon VIPER, Vol 2, issues 4,516, and 7.

per cent of total r 75"Q/r.per e ent of total . - 52,Q/gper cent of total r. "!,6dT0TAI, fr-ffi

There seems to be approximately JOy'o of general interest materialand 501" of special i-nterest material in the last four issues

"(52,6y'o vs, 4?,4% to be exact") In the February issue aloner theresults arer

PIPS related articles rGeneral interest rOther Special interest r

TOTAL -

PIPS related articlesGeneral interestOther Speeial interest

TOTAL

- L per eent of- 3 per eent of- I per cent ofF5

total r 20%total F 60%total- r 20%TOTAL - 6T7'

310

6E

The percentagesit is a case ofof five.Ird appreciate some feedback from other readers on this. What doyou ttrink of the balance presented in VIPER and how should thebaLance be kept? How mucir on one subject is too nuch? Or 4g youwant to cut out g!! special interests here? Let's hear yourconments and try to arrive at a workable solution.To PhiL Sunner, thanks are in order for pointing out a wealsreqs inour publishing policies. Though we are not engaged in any activeshift toward any special interest groupf it is true that thebalances are leit swinging in the wind. If the wind doesn'thappen to bLow your way then you're out in the cold. and that'sWfOfI$o

are less significant for a single issue because20 per cent or nothing for a single article out

rya4t tohappy to.E but we

c onf ident

Ore final comment is to renind everyone that I don'twrite fiost of the material nyqelf. We are more thanpubtish a3-1 the general interest articl-es we receivehave to receive them to publish them.

We all look forward to hearing your comments and arethat the outcome will 'be a better newsletter for all l

2.OB/OT,O5

Page 6: SHiffi::ii::. . .z.o'/os.u3

r ThevlPhObhy@mpuler;Start programming forbnly $99.

Assembled* and tested.Features:o RCA 1802 Microprocessor.. 1K Bytes static RAM.Expandable on-board to 4K,Expandable to 32 K Bytes total.o 512 Byte ROM operating system.o CHIP-8 inter,pretive language ormachine language programmable.. Hexidecimal keypado Audio tone generator.o Single S-volt operation.o Video output to monitor or modulator.. Cassette interface-100 Bytes/sec.o lnstructiori Manual with 5 video gamelistings, schematics, CHIP-8, much more!

ldeal for low-cost control applications.

Expandable to full VIP capability withvP-1 14 Kit.*User need only connect cables (included), aS-volt power supply, and speaker.

-IIIIIII,IPlease send me the RCA COSMAC VIP items indicated.

tr VP-111 New low cost Microcomputer(See description above) lgg

tr VP-l14 Expansion Kit for VP-1 1 1*lncludes3K RAM, l/O Port and connectors... $ Ze

B VP-711 VIP-The originalVlP Microcomputer(See description above)

tr VP-44 RAM On-Board Expansion Kit-Four2114 RAM lC's. Expands VP 711memory to 4K bytes $ s6

tr VP-590 VIP Color Board-Converts VIP tocolor. Four background and eightforeground colors

tr VP-595 VIP Simple Sound Board-Provides256 programmable frequencies. Forsimple music or sound effects.lncludes speaker $ g0

tr VP-550 VIP Super Sound Board-Turns yourVIP into a music synthesizer! Twoindependent sound channels. On-board tempo control. Outputs toaudiosystem . $ lg

tr VP-551 4-Channel Super Sound-lncludesVP-576 expander, demo cassetteand manual. Requires VP-550 and4KRAM ...$ Zl

tr VP-570 VIP Memory Expansion Board-Plug-in 4K RAM memory $ gS

tr VP-580 VIP Auxiliary Keypad-Adds two-player interactive capability. 1 6-keykeypad with cable. Connects tosockets on VP-590 or VP-585 ....... $ ZO

tr VP-585 VIP Keypad lnterface Board-lnter-faces two VP-580 AuxiliaryKeypads to VlP. $ tS

Completely assembledand tested.All the features of the VP-1 1 1 plus:o A total of 2K Bytes static RAM.o power supply.. I Bit input port.o 8 Bit output port.

I lO port connector.o System expansion connector.. Built-in speaker.o Plastic cover.Three comprehensive manuals:o VIP lnstruction MafiUEl . 20 videogame listings, schematics, much more.o VIP User's Guide-operating instruc-tions and CHIP-B for the beginner.o RCA 1802 User's Manual (MPM-2018) - complete 1802 referenceguide.

nG,n-ITIIIIItr VP-560 VIP EPROM Board-lnterfaces two

2716 EPROMS to VIP I g4

tr VP-565 VIP EPROM Proqrammer Board-Programs 271lEPnOUsWith software.. $ gg

E VP-575 VIP Expansion Board-Provides 4. buffered and one unbuffered

expansionsockets . $ Sgtr VP-576 VIP Two-Board Expander-Allows :

use of 2 Accessory Boards in eitherI /O or Expansion Socket.

tr VP-601 ASCII Keyboard-1 28-characterASCI I Encoded alphanumerickeyboard $ eS

COSMAC VIP lets you addcomputer power a b6ardat a time.With easy-to-buy options, the versatileRCA COSMAC VIP means even moreexcitement. More challenges ingraphics, games and control functions.For everyone, from youngster to serioushobbyist.

Built around an RCA COSMAC micro-processo[ the vlP is easy to programand operate. Powerful CHIP-8 inter-pretive language gets you intoprogramming the first evening.Complete documentation provided.

Send the coupon now...Complete the coupon below and mail to:RCA VIP Customer Service, NewHolland Avenue, Lancaster, PA 17604.

Or call toll lree (800) 23$0094to place your Master Charge or VISAcredit card order. ln Pennsylvania,catl Vfi) 397 -7661 , extension 31 79

-II-I--IItr VP-61 t ASCII / Numerrc Keyboard-Sameas VP-601 plus 16 key numerickeypad ....:.. $ AO

tr VP-620 Cable:Connects ASCII keyboardsto VIP $ ao

tr VP-700 VIP Tiny BASIC ROM Board-BAStCcode stored in 4K of ROM.. $ gg

tr VP-710 VIP Game Manual-Listing for 16exciting games. . ... .. . ... $ l0

E VP-720 VIP Game Manual-tl-More excitinogames (Avaitabte 2nd qtr '80) ....... $ lO

tl MPM- CDP1802 User Manual-(tnctuded2018 withVP-711):... ....,.. $ 5

E Pleasesendmoreinformation.......

Enclosed is $- for items checked plus shipping & handling charge of$3.00.Add your state and local taxes Total enclosed $I enclosetr check orEl money order or, charge mytr VISA/Bank AmericardEl Master Charge

Credit card account No.Master Charge lnterbank No Expiration date:-Signature (required for credit card orders):

Name (please type or print).

Street address. City

State & Zip: Telephone. ( )

Make checks payable to RCA Corp. Prices and specif ications are subject to changewithout notice.

2 ,OB/09 ,06

Page 7: SHiffi::ii::. . .z.o'/os.u3

Dear VIPER - My recent telephone conversation with you confirnedmy suspicj.ons that the parity bit from the new RCA keybodrdcreates probJ.ems. in fom Swan's ASSEMBI,ER-3o Your suggestion tocut the MSB lead will fix the problem but I have an i.nherentdislike (chicken-heart) of cutting foil on printed, circuits.Applying the following software changes to fom's EDI[0R-21,modification for keyboard 1 or 2 will also do the job,

Fgf Mojifipation #1

Addressoo 3L0o 3z00 33

For both Modifieations

For Modificallo.n #Address

\

Branch to 0O 2D 3000c8 002F- c8r spare - 00 2F 00

SHt ;Set MSB to 0SHRSTR ;Put comected code in staekPHI ;Put in RB.1BR iBranch to 0083

30CB00

Addres s00c80o ca00cA00cB00cc00cD

FEF55zB83oB3

The program is taking the input byte that is in D register andshifting it left to drop the MSB. It is thenshifted right torestore-the original daia except that a / is placed in the MSB'

Since the original byte was stored in the stack (ne;, thecorrected byte needs to replace it and this is done at address00cA.It is possible to make this modification by adding only 3 bytesbut it .requires some rearrangernent of the existing program

I assume you have the modification from RCA on adding a DPDTswltch-to the Tiny BASIC board so that CHIP-8 can be used. withoutpull,lng the board. I did make that modification (driltea holes,cut foilr laid down with a wet rag on my head) and it works verywell. - Bob DeHaven

Dear Bob -'RCA pulled a switcheroo on their ori-ginal design andny modifications were constructed on the prototype RCA keyboardthat Rick Simpson sent me. The same problem may show up in my"Step by'Step" article and elsewhere when ASCII codes are comparedin software. In the lnterest of keeping standards standardr Iwill continue to use nonnal ASCII codes in my programs that neqdthem. Another possible fix would be to logical]y AND all inputcharacters with hexadecimat $?f to set the most significant bit tozeroo Frankly, I dontt see the purpose of the parity bit anywayrand if you are not squeamish about eutting a foil trace, I suggest'you do j-t. [om

2,OB/Og.,O?

Page 8: SHiffi::ii::. . .z.o'/os.u3

Dear Rick and Temy:I had hoped to write this letter in an optimistic mood, withconstructive comments, inputs of my own, or maybe even a newarticle (yes, I'm still- thinking of that!). But over the lastfew months, I have read each new issue of VIPER with a growingsense of dissatisfaction; with the arrival of the February issue,those feelings turned into dismay.Whether you reali-ze it or not, the VIPER has largely turned intosomething that I. cannot use, and neither ean other people likerl€o As a relative beginner, I passed up the opportqnity for thePIPS seriesi I wasntt interested in becoming a programmerr andin fact am just now l-earning machine language progranming. Butnow I find that the VIPER is shifting so that PIPS FOR VIPS isa necessity if Irm to use the VIPER material. The perfectexample of this is the Ki]Ier Robots game, which uses many ofthe routines from PIPS. But I canrt use it, and neither cananyone else who didn't buy PIPS.I think you have some hard decisions to make. Either continue ,

as you seem to be going, turn the VfFER into a programmer'snewsl-etter, and accept the inevitable shrinkage in circulationas people decl-ine to renew. Or sh.ift the VIPER back to nmning,a respectable amount of general interest articles and informationthat are usable to all your readers, not just the programmingelite. By definition, this would mean that some articl-es andprograrns must be revisi.ons or extensions of previously publishedmaterial (Vfpnn or RCA manuals) r or they must be complete andself-containedq Care to put the vote to your readershrp??Note that you run the same risk in printing programs for theaccessory boards such as super sound. That would also botherrrrer but I havenrt noticed enough of that to be real1y objectionable.There usually was somethi.ng in that issue for me also. I guessmy basic beef is that the something for me has gotten l-ess. andless lately.Enough of ine negative stuff -- time to think positive. Ibasically like the newsletter in its present form, with contentsout front and'regular features. I do have reservations aboutTom Swan as the editor the newsletter may lean even more towardprogrammers as a result; the newsletter's also in very real d.angerof becoming a one man showt and I basically feel that editors.should mainly editorial-ize and only occasionally write. But I'mmore than wil-ting to wait and see how it works out.To get back on the positive trackr l-et.me hit you (and whoeverelse you care to invite to the "party") with a couple of ideas(or downright challenges, if that's what it takes to get someoneinterestedl.

1; "It's about time that the VIP became useful for somethingother than a toyr galrei or hobby. The next most logicalthing to d.o with t[e VIP is to make it into an educationaldevice, especi-a1Iy for math -- why not now? The softwaremultiply anO Aivihe routines are avaiLabLe; so are routinesfor disbfaying any combination of di-gits " Conversion ' ,

2.OB/O9.oB

Page 9: SHiffi::ii::. . .z.o'/os.u3

between hex and decimals may be a problem when handlinglarge numbersr but that "problem" should be solvable.Handling of negative numbers may be more of a problem.Why cantt some of our elite programmers put such a packagetogether? 0r maybe put at least part of it together, suchas handling negative decimal numbers?

2, There is a definite d.earth of logically writtenexplanatory material on machine language prograrnning, Whycanrt someone put together a manual on the topic? Themachine language equivalent of the VIP User's-Guide thatTerry did? I would be very willing to collaborate on sucha nanual I think I can contribute in some waysr and canact as a trial filter for most of the rest. And if youwait long enough, I might be able to do the whole thing,Some of the natural- pieces for such a manual are surfacingin my work nowi Irm the Astro Electronics instructor forthe Microprocessor System Design laboratorf cours€r Rickis probably familiar with C1I/CL1L' the fundanentals coursetwhat I rm teaching is CL56, which goes much deeper into alot of interesting topics r Ij-ke machine language, Individualpieces of the manual could be published in VIPER as they aregenerated, then they could all be collectedr reorganizedl andedited to produce the manual. I have the first draft of sueha piece nowr something caIled "A Universal Machine LanguageBranching Technique"r whj.ch discusses a handy softwaretechnique that every real progranmer larows but every beginnerhas to find out the hard way. And there are other potentialtopics rieht behind it.

This letter has gotten too long alreadyr Xet! For the next orr€eI won't wait so longl Thanx for everything - Phil Sumner

Phil - You're absolutely rigfrt. And. we hadn't even noticed. theshiftl It is people like Vou, who give us substantial constructivecriticismsr offering new ideas & solutions, that keep VIPER ontrackl Thank $ourI see VIPER as an information exchange. People write about thingstheyrre interested in. We "pretty it up" and make a lot of copiesrthen send copies to anyone who is willing to share the printing& mailing costs. - Terry

Dear VIPER I have a'VIP with 4X A Color, I am also a ha,u radiooperator. I would like. to interface the VfP to a circuit to be-aLle to recej.ve morse code and display it with the VIP. I am notsure where the output of this A/D converter would connect to theVIP. My larowledge of machine language is not all that good to beable to convert their coding to the VIP. ff you or anybody youknow of could help me on this it would be greatly appreeiated. Iwould thlnk this could be of great value to many VIP users as wellas.the many ha.rns that could be interested, Ihank $our Ted Bratcher

2,OB/og,09

Page 10: SHiffi::ii::. . .z.o'/os.u3

Dear Ted - Sorry but Irm not a ham (though some would disagreel)In your letter you also ineluded a c-opy of a circuit taken fromnEUlri-r-'gazine". Because I assume that diagrarn is copyrighted bythe publisher of REMark, I did not include it here as ygu requ-ested.Sti11, if any readers respond with similar interests, ff1l be happy

,t!,,,,,1,i,1,8,,,fiF,l,,,,W,I,',ll'fi,f,ll.iL,,I*f,ll",l1li,il,:,,,,.,,ff**\i,,,li[,"S*lifr'?:L**#l[::i::ii:r:i

Dear VIPER I'm very impressed with your publication. I soonSopg to publish my Vfp-fBOe mini-assembler- in the VIPER.The assembler is designed. to work in a standard VIP using thehexpad. This means that hexadecimal op cgdes must still beused.. Ihis plus the lack of a4y macro capability means Ihavenrt written a true assembler. My mini-assembler wi1I,

,-however, allow the writing of (Ahhhh) futty relocatable sourcecodel fhe assembler will-support the use -of labels and/orabsolute addressing. AII branches and subroutine caIls tolabels will be resolved. In addition, code can be assembledto run any'place in RAM using a simplified ORG directive. Keepup the good work. - Steven Blasni-k (P,S, Tom Swanrs rel.ocatablePC change was beautiful! )

...P..e_+f....$.!_-e.y-e..t...:...![e....Lp.p.h...f9ry.?.r9.....!.-o_...r._e_9.9.lylng..y-.og.f ...1F.p_-e_T.npl9.f :....:...T.o..*

Dear VIPER - San Hershts Editor is especially nice but should berelocated to the highest page ryith a iump to it a! 0200! - Thenyou can rUn a progran in CIIIP-8 by loading all but the first twobytes at O2O2, chebking and editing then replacing the junp-to ato2oo with the first two bytes and run. (Maybe it would take along branch and four bytes, but you get the idea) r

Alsor I have a VIP for sale. It includes 2K RAM' Tiny BASICTinproved RESET-RUN switch, 2 digit hex display on outport port,I bit binary LED display for output, Cortes audio output ?.np,switch for,Tiny BASIC, all cables for TV & cassette, AC powersupply, a stack of documentation 3 to 4 inches thick (inCtuairrg .g}I-Vfpnn issues), & original shipping cartons" A11 this for aSZ-oo cashier's check. -One more thi.ng. Tiny BASIC needs an OUT statement/command" (a11BASICs are weak on this, I think). Who says you'lI'neVer warrt toget somethj-ng out on the output port? I donrt favor any sehemesfor POlGi.ng around with machine language routines to accomplishthiso I'm working on a hardvrare fix for it" Anyone interested?.

2,OB/og.to

Page 11: SHiffi::ii::. . .z.o'/os.u3

Dear VIPER I arn experiencing some difficulty with my \IP-700.Tiny BASIC. Sometimes my machine nms through a 60-Key loopwithout a key being depressed. I wond.er if any of your readershave had a similar problem and found. a solution?Keep up the good work and thanks for any he1p. .- Jerry Krizek

Dear VIPER - My'system is a home brew t8O2 resenbling the ELF'however, I have made modifications to it as well as the CHIP-8such that my machi-ne is indistinguishabJ-e from a VIP o I saw myfirst VIP a few weeks ago and was pleased with nyself as to mysimulation.Your newsl-etter (magazine) is a constant source of enjoprent bothfor me and non-computerist wife" At some point I will send-youmy oHIP-8 version -ot

oNE-DTMENSIONAI LIFE (nnn, Jzlzr p68 (i9?8))and PAPER, SCISS0RS, STONE.

I have implemented. Charlie Mc0arthy's (Vfpnn, May '?g) Hi-resolutiongraphics and was very pl-eased with it. I hope to see some softwaresupport in Vol-ume-?-or to eontact Mr. McCarthy directly. - WilliamGiLbert

Dear trlilliarn - At one time I had contemplated writing a CHIP-8version of LIIE but ended with a machine version because of speed"Thanks for your Jetter and we look forward to seeing your prograrns r

Tom

Dear VIPER In the Nov. t?9 VIPER (2,o51 , Tom Swan reviewed TinyBASIC and commented. that there were no provisions for machinelanguage additiorls. I received one of the early boards (it onlycost me $Z9t ) and had the same frustration. I called RCA, talkedwith Joe Rudy, and discovered that there re. a way to get at leastlimited rnachine language capability. Andy Modla of RCA PrincetonLabs had written a way to achieve thisl I called him and got theinstructions with the r.mderstanding that he intended to send itto VIPER to be pubJ-ished..

I have used this approach with my Tiny BASIC board, and it workstI get the feel-ing that these directions could be modified toprovide a multipLe number of machine language subroutines, but Ihaven't had tim-e to look into i-t. Perhaps someone out there mightwant to dig into this further. - Randy Holt

Dear Randy - Someone Ellready has I See the article "More TinyBASIC Machine Language Subsi'by C.D. Smith in this issue. - Tom-

Dear VIPER - Having 3scentlf installed. a home brew RAM board., andstomping on a fair-share of hard.ware bugs in the proeess, I thi.nkthe following modifications to the Memory Test Progra"ur in the VIPManual (VIP-300, p.32) may be useful to 1802-ers iri testingerratic memori-es.

z.oB/09 ,11

Page 12: SHiffi::ii::. . .z.o'/os.u3

Changlng the error-trap to provide a dynamic, r4ther than static,display can reveal "iffy" address lines. fhis change flashes theerror location continuously" and the tone is suppressed sincehavlng hardware problems is annoying enoughloo6c o? FB Fr 30 6c (rast byte @ oo?1)In ny case, this revealed nultiple simultaneous access within the1K under test I it can be determj.ned from the screen which IVIA

lines are fadlty.Not trapping errors is also us'eful in observing overall behaviorin the tK under testr x€v€Bling faulty add,ress linesr, un-€h&bledchlpsr oF chips not write-enabled' or which fail to respond tosignals. These failures are observed as vertical solid linescoiresponding to the bit-width of the chip (4 uits tor 2714s, Ifor 21O1sr etc.) for enable problems. Dead address lines willshow as horizontal lines; a combination of enable and addressproblems will show as squares or cross-hatch. To disable thetrap, change 0054 to '38'.Fortunately, my board is rururing nicely, thank youi with the ex-ception of t-2114 with a bad bit, all problems were bad connections'either sold.eredr or the more insidious pin-to-socket contact"- P. V. Piescik, Cuddly Software

A LETIER TO PIPS ITI OWNERS

from Tom Swan

Welt, it's humble pie time. ltrlhen I wrote the Reversi type gameVIP-FLOP for PIPS FOn VfpS III, I thoueht I knew how to-pfaf tfregame. I have a good friend who used to teIl me, "Tom, !flglassume that you lorow anything." (Roy -- you were rigfrt-Eg4ln.)Not having the box version down here in Burro Land, I relied ona sketchy Creative Computing article and one match played at acomputer show as the basis for the game rules. As many of youhave rightly pointed out, I made one lovely boo-boo. My headhangs d.own in'sharne and I print here one of Terry laudereau'sfarnous "sighhhh's " a long'n .

My mistake was to assume that moves only need to be ad.iacent toany piece in order to be counted as Iegal. The correct rulesrequire that at least one opponent piece be flipped for the noveto be legal. When there are no 1ega1 moves possible, the playermust forfeit the turn.Now for the good n€ws.CARMELO CORTES TO THE RESCIIE !

(con't)

2,OB/O7,A2

Page 13: SHiffi::ii::. . .z.o'/os.u3

Dear Riek and Terry,

I,'ve enelosed my correeti ons toineluded a routi-ne that allowsa turn when there are no e-eqlUnfortunately, beeause of lackeomputer to suggest a move foryou are f orfeiting your turn

"

I hope Tom comes up with a better change than mj.ne, this waycan have ny forfeit and computer advice too!Thank youCarmelo Cortes

Thanks, Carmelo, The modifications listed below work fine andthe only improvement I can think of is to, as you suggestr makethe forfeit automatic so that Key C will work as before" I'11give it a t"y, and if I have any success, publish the resultsnext month.They say "To err is human." Sometimes I wlsh I was a computer!(Guess which one.)

CHANGES TO VIP-FLOP

03 6c5n7o

-L

0390--

o3EAF2

o3F5FE

4E FF15 lnT3 BC

T3 EA

4A FF 13 F2 ?426 c4 13 66

Dll D gz

FFD3FB9F8D1F

NBD3

F8F8

FF A6 56 Dll// 55 b+FB FF A6

rreFF13cB3ufinBlT3 B2

'lF 13

o3D2 13rF

0 877 F5

oaic BD8ll AEBc 32.eu fls9C 32A4 FBAC aA

o aFeFE

II

ogElEg

F5

E6

f,zFBgEFBFBlz82

E1DC

AD F8zlt A33fl e4BF 3z9n 563A 853fl F5

A3 Dl DC FB E5 A3

AF FB FFg+ FB Ft2t+ A3 D3gA FB 9t57 1E 8E8F FB Fz

the VIP-FLOP game. Also I rveyou or the computer to forfeitmoves left.of room you ean no longer ask the[ou. Now when you press KeV C t

?,08/og, 13

Page 14: SHiffi::ii::. . .z.o'/os.u3

PRELTMTNARY ffing Point BAslc lnterpreterfor the Vp-711 Mlcroeomputel

VP-701 BASIC is a full-sized BASIC interpreter for the VP-711 or Expanded Vp-111 MicroOomputer. This BASIC includes features that up till now were onlydreamed about by .VP-711 owners: one and two dimensional arraysi stringvariables string f unctions; machine language subroutine calls; plus FLOATINGPOINT MATH with trigonometric and transcendental functions.

VP-701 BASIC contains over 70 statements and functions including customtailored commands for use with the VP-590 Color Board and the VP-595 SimpleSound Board. VP-701 BASIC provides video mapping of 16 characters by 11

lines.

VP-701 BASIC is RAM-resident, requiring a minimum of 16K bytes of memoryfor the interpreter plus RAM for program area. VP-701 BASIC comes oncassette tape and includes a user guide.

NUMBER RANGESFloating Point: t 1.7014 x 1O t S,32 bit (approximately 6decimal digits)

lnteger: t 2,147,483,647, 32 bit (10 decimal digits).

VARIABLE TYPESNumeric (Simple) A-ZNumeric (Dimensioned) A(1) - Z (256,256)

DIM Statement required. i.e. DIM A(100, 10)Size of arrays are limited by memory.

String A$ - Z$Up to 96 characters each.

FLOATING POINT VS INTEGERAll numeric variables default to floating point. To definevariables as integer use DEFINT X statement which sets allvariables through variable X to integer. To change variablesback to floating point reissue the DEFINT command.(DEFINT with no variable resets all variables to FLT. PT.)

During input VP-701 BASIC converts all numeric entriesinto an internal format to facilitate program exocution.

GRAPHICSVP-701 BASIC also contains special commands to utilizegraphics and color.

The video display is arranged as a rectangle having 64elements horizontally and 128 elements vertically. Thegraphic commands COLOR and SHOW have their origin(0, Ol at the upper left-hand corner of the screen.

The PLOT command has its origin (0, 0) at the lower left-hand corner to facilitate an easy transition from ordinarycartesian coordinate geometry to the video screen surface.

RcA Microcomputer productslNew Holland AvenueLancaster, PA 17604

COLORWhen used with the VP-590 Color Board, VP-701 BASICcan program the video field for color. The color statementby itself will sequence through 4 background colors. Whenparameters are included after the color statement, theforeground colors can be set to the colors listed below. Thecolor field is broken Ltp into 8 blocks horizontally and 4mirrored 32 bit blocks vertically.

COLOR CODES0 - Black1-Red2 - Blue3 - Magenta

VOCABULARYABSASCATNCALLCHR$cLcCLDGLSCOLORcosDATADEFINTDEFUSDIMDLOADDSAVEENDEODEOPEXITEXPFIXEDFNUMFORFREQ

4 - Green5 - Yellow6 - Cyan7 - White

GETGOKEYGOSUBGOTOHITIFINPUTINTINUMKEYLENLETLISTLOGMEMMID$NEW.NEXTPEEKPIPLOADPLOTPOKEPRINTPRINTAT

PRINTER ONPRINTER OFFPSAVEPTREADREMRESTORERETURNRNDRUNSGN I

SHOWSINSQRSTEPSTORETABTIMERTIMETONETVOFFTVONUSRWAIT

2.O81O9.14

Page 15: SHiffi::ii::. . .z.o'/os.u3

I

CHIP- 8E

by Gilles Detillieux

It seems that everyone has oome up with extensions to CHIP-8.Many of these would be very useful but obviously they could notall be incorporated in a 5t2 byte i-nterpreter. This gives riseto many incompatible systems. ,The approach I took was to rewrite the interpreterr taking thefollowing points into considerati.on r

1) It should be cornpatible with all- prevj-ously writtenCHIP-8 programs" Execution should. begin at 0200 and allinstructions should remain unchanged. (with the exceptionof BMMM and 004e which are rarely if ever used in anyCHIP-8 programs*. )

2) It should be readily adaptable to various ISOZ machines.

3) It should incorporate T/O instructions.tl) fhe ad.ded. j-nstructions shoutd be useful enough to warranttheir implementation in the interpretero Less useful ones(or those used less often) can be handled as machinelanguage subroutingF.

My interpreter, which I call CHIP-ffi (for extended), features thefollowj-ng new instructions r

OOED STOPReplaces filIer at location 00ED with instruction23 DEC R3. Since R3 is the program cowrterrexecution stops at this point.

ot57 WAIT FoR TIME IIPExamines content of timer and exits once timer equals00

OOFz NO OPERATIONUsefuL for deleting instructions in a program.Executes a D4 SEP R4 at 00F2, which makes it returnto fetch the next instruetion.

O18B SKIPUnconditionally skips next two byte instruction.

sxY,t SKIP IF vX>vY ,^+:^* ir r,r, ISkips next two byte instruction if VX is greater thanvY.

*So far, the only CHIP-8 program I have seen which uses aninstructj.on not a.rraiLable in CHIP-8E is "VIP Bowling" in the VIPGame Manual. This prograrn contains a BJJA instruction at 0538,In this case, the new F01B instruction can directly replace it.

2.OB/O9 , L 5

Page 16: SHiffi::ii::. . .z.o'/os.u3

sXY2

sxY3

BBMM

BFMM

FXO3

FXlB

FXI}F

FXE3

FXET

MI = VX rVYTransfers variables X through Y to memory. Workslike FX55o

VX rVY = MfLoad variables X through Y with data from memory.Works tike FX65.BRANCH BACKSIARD MM BYTESGo to current instruction location minus MM; (SeevrPER 2 ,01 . 11 )

BRANCH FORI/fARD MM BYTESGo to current instruction locationVIPER 2 ,01 . 11 ) ( nn00 and BF00 areloops )

OUIPUT = VXContent of VX sent to output port l.SKIP VX BYTESSkips amount of bytes indicated by content of VX.If VX is 00, the next instruction is executed.(suustitute for old BMMM)

TIUIE = VX; WAIT FOR TIXM UPSets timer value of VX then waits at OI5I r-rntiltimer is 00 'VX = INPUIWaits for st-,robe at EFE thenport 3.VX = IIIPUTReads content of input portstrobe.

\

plus MIvl , (Seenon-terminating

reads c ontent of input

3 without waiting for

The listing for CHIP-8E, (tisting t), is for the VIP" For use witha different ISOZ system, modification will- be required"If you are using the system described by Bobby Lewis, make thechanges shown in listing II.If you have a kelpad at input port 4, and an IN button, (like theEIF II and SIIPER ELF) make the changes shown in listing III.If you have = keypad at input port 4 which provides a key-pressedstrbbe at ffi make the changes shown in listing III, using 3E insteadof 3F and 35 instead of 37,If your keypad is different than the systems mentioned abovet VPUwiLl have to rewrite instructions FX0A at locations 010A to 0114'and EXgEr/A1 at Locations 019F to 01ADo

I hope this version of CHIP-8 wilt satisfy the need.s of most people r

and perhaps introduce a measure of standard.ization for extendedCHIP-8 interpreters.

. Listing I CHIP-8E

o0oo c4 gt BB FF 01 82 96 F8 CF A2 F8 oo 45 F8 02 85oolo F8 81 81 F8 &6 A1 90 Bl} F8 1D A4 30 E0 E2 69 96oo2o B? E2 94 nC 05 F6 F5 F5 F5 32 t+2 FE FC 45 AC 45oo3o Fg Fo A6 05 F6 15 n5 F6 F9 F0 A7 4c s3 0C A3 D3

(Cont. )

2 . OB/og.L6

Page 17: SHiffi::ii::. . .z.o'/os.u3

oo4o 300050 7 5oo5o 65007 o 5200 80 AD00go 32ooAo L500Bo 3z0oc0 3200D0 F80 080 98ooFo 4zo 1oo o40110 220 120 8A0 130 oAo t4o Fco150 88o16o 1Ao17O 1401 80 38otgo D4o lAo r'50180 0Fo 1co 07o lDo Dll01E0 F2o lFo F9

1F0001o7A79B3oB5c5FFBFA5+5DCr4AA54gB3A3AB8Ll,5

n53AD2L955rb

0001o6gAA33oA7FB$D4F225o4A8FEAF73FOFOe5t5B6

3ED3p456p4F7

45D79FFEFBgD85F8FBn5F8D4A3T2AAo4FF3A5B5nD4o76zn65689o4A5

83 45 30 3E oo FAOO DA 01 AE 01 9T01 01 o5 FA oZ BEFE FE F1 AC 9N BCDoAS%BTBZ3215 BD g? Z6 B? zEoo Ec FB Do a6 9301 A? 46 F3 5C 0201 A? o6 F3 5c zcB? 56 rz p4 Lt,s 56FF AF g4 5F BF 32t5 85 22 73 95 52n5 I z6 plr 98 5656 D4 o5 BB p4 o69A 7C 00 BA Oll 001A 1A EA FB FF AEoA 1E 33 4z Fc oA5r D4 22 85 52 FBrz D4 zz 86 52 FBLz ob Lt,s Z6 ?6 i345 n6 F3 3A 82 t530 Bc 78, 22 87 52z6 33 49 36 BB p4o? 55 D4 AF 22 FBFB FF A6 gb ?E 56AE 93 BE 99 EE r43F E3 3? E5 n5 5n95 ?C oo 85 z5 o4

F3 01 83 01 8B 01cA 01 EA 01 D1 00FA 3F n'5 r'5 r'5 zzBF BA AF I+5 FA OFz? 4r' BD 9E AE BEBF 9D 56 16 9? 56BD 32 Do zD o6 Fza? 32 c9 1c o5 FzBc Fc oB Ac 38 AA45 n5 rlr 56 o& oozF 30 E5 23 4z,B545 A5 85 FA oF 85FB BT BC F8 95 ACDrl n6 t5 30 EE n581 BA O6 FA OF AAo6 FF 5Lt, 1F 33 38BE ?3 BF 5A o4 o6A7 07 5A 87 F3 17A7 oA 57 87 F3 L7TE o? 38 8ll n5 FTo4 45 n6 F3 3A 88A? 33 5e 30 58 t+5

BB ol} oo oo 45 FA?3 8F F9 Fo 52 n6LI 5 AA 86 FAOFBAz6 n6 r4 ng 56 L+5

E5 85 FC 01 85 38A5 95 ?F oo 3A r'6

Listing II CHIP-8E Modifications(for system desciibed by Bobby Lewis, VfPER, March '?9)

( CttIP - B patch no longer required )oooo FB 070 011 0E0108 0E0124 0Eo 1A2 6Zo 1A5 7?o 1A9 3F

0 0000011oo 140 10401 2A0 141

:: OX

r- a

n5 3FII

3FAA

tisting III CHIP- m Modif ications(fdr ELF II and, SUPER nlF. )

(ox is display page)(High ad.d,ress- for Interrupt routine )(frow address for Interrupt routine)

oB 3? oD 6c FA oF 56 P4 oo(High address for Pattern table )

zz 6d, o5 F3 rz FA oF 33 BE 30 85

2 ,oB/09 ,L?

Page 18: SHiffi::ii::. . .z.o'/os.u3

II\MERT

by Robert Lindley

The vrP will seLect nine randon digits, one through nine, anddispray them. These numberi are not d.uplicated, 6ach appearselactry.once. Th" _object of the game is to try to get !-our lineof digits in order before the vrp puts its rini: in drdel.A possible starting display might be: \

If you press key 6, the new display is:YOUnm

As illustrated, everything from the left end of the row to thegiven key number is inverted. Al-so the vrp seleets its owninversion. The serectioh made by the vrp uses arl efficientalgorithm, but it does not take full advantage of natural orderoIn the case of a tie -- you win.The program was coded in a sirnple straight forward mannerr Themain program is first and is mostry cal-rs to subroutines to dothe work. There is one r.mique thing in the program, it uses apai-r of subroutines (sgw ana nnsrn) to save and restore thememory poj.nter. Thi-s neatly solves the problem of using onepoi.nter for both data array reference and display refererlcer

27936 Br5t+ YoU27936 Br54 MEINVERT

639?zBr54972368r54INVERT6

/z/il6z'/t+

/6ilBiledcilEL/T2*761B1A1C1E

SIART r

l,lEXT I

6Ll.// --221E -r2266 --T{z --22BB E-3\6f, D-r2:,/g -r22DC F-23/2 --.A3F8 --n26 --2376 --A4gg --n26 --12/6 --Alll B --

LISTING

Sigrral first pass of gameDo RNDMDo SHINVDo SHROIUDo WINLSTest for start new gameGo to SIARIDo GETINDo S}IR OI/'I

YOURDo DOINVDo MYCHSMINEDo DOINVGo to NEXTrEMPRNDMI

?,o\/og .1 B

Page 19: SHiffi::ii::. . .z.o'/os.u3

-*r

Fzzl22 R1tz4z52B2A2C2E R2t

/23/32It+l638 R3:3A3c3E

/zt+g4z4446&BllALl,C

llE/25/

5254565B5A5c5E

/26/ sHrNVr6z6t+666B6e6c5n

f,27/7zZ4?67B74,7C7E

ilzglg2BllB6BB trtINl,S:BABCBE

ReturnX screen locationY screen locationVB=1 means player winsGo to MYI/UIN

6//ilFg 557 //t3,//sI2226//fl5Me,eilss? tlt3Lr/I22E6r,fuccgFA41 BFClEF665Ltflllr238ALliBFBlEelssA3F8FBlEFl 55A&1 BFClE6lf,/Ffr 55?nf,ty,/sI23Bddnn'6b//6n$A3DADDE5?D66A3E/DDE5?Dl6e3n5DDE5?D/6A3C2DDE5?Dg6A3ECDDE5?Dl6A3F2DDE5ilf,nn6:Dgfl5n1B3BgTL2A5

--l

I-r

II

II

--r-

--r

ri

-rI

-l-

-I

--II

--I-

----a

--III

L-

rlr

--I-

----Il-

-ar

--IT

Ir-

I-r

---r-

-a-

II

Start loop e olultPut / to 9 in array tempIncrement loop eountExit on 10 eountGo to R1Set z,ero to storeStart. loop at next loeation?,ero out array locations A toIncrement loopExit on 17 countGotoRZ \

Start loop c ountGet random # / to Ffemp - restore array originAdd offsetFeteh random amay el ementTry again if zero in arrayGo to R3MIIYE - Computer amayAdd offsetStoreYOUR - Player arrayAdd offsetStoreTemp r Scratch Pad arrayAdd random offsetZero to mark as selectedStoreIncrementExit loopGo to R3Return rX screenY screenI

loopon 10 count

9 random # selectedl ocat i,onlocation

-rr N

-=V

--E

IIR

--T-I

-n

-T

----

2,OB/O9 ,r9

Page 20: SHiffi::ii::. . .z.o'/os.u3

/zgl929Lt'

969BgAgc9E

/zalA2ahA6 MYIUIN I

ABAAACAE

/znflB2nlle6BBBABCBE

/zclC2 T'IXIT I

c4c6CB SHYOU g

CACCCE

/znlD2o4n6DBDADC GETIN IDE

/znlE2nlln6EB INPUT IEA'ECEE

/zplF2rllr'6FBFAFCFE

i- Do SHYOU-- hI

--I

22CBe3o4DDE5?Dl6A3DADDE5?Dl6A3EgDDE5acn/I2C23c6t/lna22CBA3CBDDE5?Dfl6sw/DDE57Dfl6A3CEDDE57Dg5A3C2DDE 5rddA//E/ggEEA3AADDE5?Dg6A3F,f,DDE5?Dl6aSe6DDE5zndc/lsn5D2B6nMuLtilgT2EBr4z9DDE5pzds|z'fr/1zEB8320z 266Gttr/824232/fl128 B

F3 zgDDE5Bt+34

D-0

--S

-r-

--l

-I

a--

-tE

-F

--

-t-

--------

Ir-

---I

-t-

--

---t-

-t-

-tF

--t

F-

-r-

-t -t

ITI

N

Indieate end of gameGo to TUXIT \

VC= f means computer winsReturn for no wi-nnerDo SHYOUL

E

Wait for key - start new gameErase screenReturnY

-rr 0

--U

ReturnX screen positionY s ere en pos it ionDo not erase on first passGo to INPUT

Erase prior inputttlait for input keyTry again if zeroGo to IIYPUTv3-v2Add 5

Skip if key (Go to INPUT

Show eurrent

10

input

2,OB/og . 20

Page 21: SHiffi::ii::. . .z.o'/os.u3

itti6z'gLt,

i6fl8gA/c6E

F3'tgT2*fi181A1C1E

/tzl222t+z5?B2A2c2E

/t3/3zIt+t63B3A3c3E

/t+g4zLl,Ll,

46ll84allc4E

lt5/525Ll565B5A5c5E

/xg5z6456585A6c5E

SHR0h[ r

DOINV r

D01 r

D02 r

DISPN I

DSr

ReturnX screenY sereenYOURDo DISPN

Do SHYOUX screenY sereenMINEDo DISPN

pos itionpos it i on

pos itionpos ition

66nn'6bdd6E'd/A3F82355BB cd?D/222C86D/g6AilBMla23567Df,2A3BCDDE5?D/643C2DDE5gFNEg39z6tlF?$IflnnF11Er/5sA41 B

F11EFfl 55sltlt3zA52/F7 rgr? AgLTTFFalll BF21EFf,65ilteEF11EFg 553LgLD;11,fl/finn6c6L6t'/tF11E/tezf,l9EFf,656t9z5/tf,6CFflFg29DDE5?Dfl 5?$L

--M

r-E

--r-t

----I-

-----I

--I-

-I

-I

---r-

I-

---r

---I

-----I

---F

---------t-

-a-

--a-

-I

---a-

II

T-

---tI

--I-

-Ir

FI

III

a-

--

ReturnDo save r save memory pointerStart loop counterInerement eounterDo RESTR r restore memory pointerAdd array offsetFeteh eI ementTemp - amay originAdd array offsetStore in scratch arrayExit on number matehGo to D01vz=/Increment array pointerInerement dest j-nation pointerDecrement array pointerTemp amay originAdd offsetFetch array elementDo RESTR - restore memory pointerAdd offsetStore elementf est f or end of count downGo to DOzReturnSet wirrner flagSet array pointer - loop countAdd offsetDo SAVE r save memory pointerDo RESIR - restore memory pointerFeteh array elementDo SAVE r save memory pointerTest for number matchReset wirrrrer flagShow array number

Increment loop c ount

2,Oa/09,2L

Page 22: SHiffi::ii::. . .z.o'/os.u3

ltz fl7z?4?6 MycHS r

78 MY:7A7C7E

/tBflB2B4B6BBBABCBE

/sgl9Z SA\E I

9394e5979B99gA

98gc9D9E RESTR:9F/vlA1A3e&A5t6A7ABAgAA YrACAE

/n/ o:B2e&s6 u:BBBABC M:BE

/tclc2 E:cltC6CB Lr

3LgAL35Ef,6nn$/A73FFALl/BF3rnFil6 5g;/tlL37 Bul/ALtdSe{esFg6 5g;/tlWM/lnnE296BFFB eflAFgA

5F1FBA

5Fo4E296BFFB elAFllr'BA4r'AAn&fl/BBsilzdz,dz'flfu?/88BBBBwggBBBBBBBB? BggBBDBA BBBBBl/FB86rdriaF,BddBltil

---I

-F

-----aI

-I

----ts-

E-

-E

----E-

E-

-----E

E-

-l-

EI

--I-

-r-

-------F

--T-

-E

E-

E-

-----E

E-

Test for end of arrayGo to DSReturnP oint to top of arrayDecrement pointerMIIVE - array origrnAdd pffsetFetch elementLook for sequence mismatchGo to MYV1 =vflMIIVE - array originSkip over el ement zeroFetch el ement oneLook for mismatchInvert at next s equential #ReturnSEX 2GHI 6PHI FLDI 9/PLO FGHI ASTR FINi' FGLO ASTR FSEP I+

SEX 2GHI 6PHI FLDI 9/PLO FLDA FPHI ALDA FPLO ASEP 4

z,ag/og, zz

Page 23: SHiffi::ii::. . .z.o'/os.u3

/lcAccCE Sr

/3DiD2\- Dll WrD6D8DA IrDCDE

9n/ N,8,2Eltn5 v:E8EAEC RrEE/rlFZ TrFllr'5.

,qa ffiffi:

PROGRAMMING HINTS

by H.C. Will IV

"Patching" is a term used by programmers when they wish to get'something they missed into their progran. This is accomplishedby doing a jr.mp (or call) to a location where the missinginstructi,ons are stuck in. This is useful when you mS.ssed oneof the first instructions.After conpleting a progran' save it on tape and then use one ofthe VIP drawing prograns to create a message or picture that youwant to be -displayed. Reload your program artd save it and thedisplay page on tape. From then on, whenever you load thatprogra"n from tape r Vour message or picture will be displayed atthe end of the load. Remember, when designing your display, thatyou must leave room at the bottom of the screen for the monj.torto display the ad.dress and the contents of that address. Sincethe display page must be saved along with the program in one shot,'this method will cause all recordings done this way to be the sanelength (i.e. 8 pagbs for a ?K nAU Vtp).Hint - when you aoirt lqlow how many pages to load of a progran ontape, try load.ing 15(f) pages, Even if the progran is only oneor two pages long, the entire length will be properly read j.n.Stop the tape when the tape light and Q signal come oDr - Tom

8d8dea//7 8Bg?lil8F/F/8BB8A8A85///?gzg2,il2,fl? ///88C 8A89888//B888

\frffiF 8BBFSAdedlflFBzflzdzdz'fl//

2,OB/09 , ?3

Page 24: SHiffi::ii::. . .z.o'/os.u3

SOFTWARE CHANGES AND OTHER GOOD STUFF

by George Ziniewi ez,

BMMM in CHfP-B

To a1Jow any variable to be the index for01A4 from FB to EZ

A5 F/ to BD

Then using John Berurett r s FXF2 code in Volyou can eontrol the starting variable forand. let any variabl-e be added to the BMMM

The following sequence will work I

FXF2 -- RD.O=VXBMMM -- ttlhere X = variable to index wlth

the braneh r change :

I , j-ssue 10 ( page ? )FX 55-65 instruCtionsad.dr€ss r

EYE, E]E CAPTAIN .

Give the Figure Shooting atseoring a hit by giving him

02AC from 7C to ?4

Moving Target better chanc es of.an ele r

CHIN UP !

Correct the faee in Dot Dash

oll0C from 84. to 86

REVERSE VIDEO

Here is a MLS (Machine language subroutine ) to swap aIl- bits whiteto black and vice versa. Just caLl with the instructton /U// whereM is the page address of the IIILS. The routine can be entered intoany memory page beginning at byte /f.

r Load display page ( s ) startrload. # pages (of or aZ)

rload display start address

; Get display byte

/vt// 98 REvvD r GHr RB01 BC02 FBOll AD05 FB07 AC0B 0c

01

00

REVV1 !

PHI RCLDr #tPLO RDLDI #OPLO RCLDN RC

2,OB/O9 , 24

Page 25: SHiffi::ii::. . .z.o'/os.u3

Irrtlg FFOB0cODOE1011721,1+

FB5c1C8C

3A2D8D3ADl+

08

08

xRr #$FFSTR RCINC RCGIO RCBNZ REVVlDEC RDGIO RDBNZ REVVlSEP nII

i InvertlPut baek

; Loop till done

I All pages done?;Return

;" ";-;;"

;;;;" ;;;; ; ;";;,,

f) A hardware Reverse Video for fuLl sereen instantaneous reversal.It will use three chips and four bytes of software.

Z) CHIP-8 courpatible music (approx" 30 bytes) with the slmtax;A_l point to music string/f,_; Bo to music MLS. No displayoff commands required and. one byte incLudes frequency and durationending the string with f,F, A 60hz interrupt beat providesinteresting effects. AIso, there are 15 preprogra^uuned frequenciesin the look up tab1e.

3) CHIP-8 single-dualjetc. TexLdisplay with control connands.(Less than e pages incl-Uding charaoter-map). Included wil"l be l+5

characters with home, line feed' carriage returnr tone, delayrwait for keyl and user defined controls,

4) Time Lapse Controller for electri.ca1ly operated movie cameras.

5) Simple control for up to 8 electrical- appllances.

6) Adventure style galae where you hunt for treasure.

7, Sinple CHIP-8 Character Designer

8) Color 0rgan, Standard CHIP-8 color control, real Kalied.oscope.

9) MLs tibraryEDITffi'S N0mr Georger you really have some good ideas. Thanksfor the modifications and the above inspirationst - Tom

2.OB/O9 ,25

Page 26: SHiffi::ii::. . .z.o'/os.u3

vP-551

Four Channel Music SynthesisFor The COSMAC MicroComputer

Four-Channel Super SoundExpansion Package

NFour lndependent Sound Channels

Note Frequency, Duration & Envelope Control

Data Cassette Wlth Two Music Programs

Four OctaYe Range

Versatlle Four-Channel Soltware

\r-i

The VP-551 Four Channel Super Sound Package includes a VP-551 circuit board, a VP-576 TwoBoard Expander, a data cassette with two music programs and an lnstruction Manual.

You will be impressed with the music playing capability of the COSMAC MicroComputer SuperSound with this added four channel synthesis. Each channel can be programmed for frequency andnote env€lope independently. You can create four part harmony or a melody with chordaccompaniment or the illusion of several instruments playing at once. Tempo is adjustable with anon-board potentiometer.

The all new four channel software allows you to transpose your songs up or down over a two octaverange a half step at a time with just the stroke of a key for each half step! But that's not all . .. programup to eight songs at one time and select any song, select any sequence or randomly play any of theprogrammed songs. You can continuously repeat the songs or you can play them through once.

The caref ully written, well organized manual shows you how. lt includes a source code listing;musictables and addresses, and as an additional bonus, the classic, Fuga of Bach, as a programmihgexample.

Operation of Four Channel Super Sound requires your VP-71 1 or expanded VP-11 1 MicroOomputer,your VP-550 Super Sound board and any stereo systern.

2.O8/O9.26[RG/L yj:l*fl'puter

Page 27: SHiffi::ii::. . .z.o'/os.u3

ITFE

by Tom Swan

Plenty has been written about the game of IIFE. For referencessee Scientific American, 0ctober t97O where the gaae firstappeared in Martin Gardner's.column on page t?O, (f was luckyto find a mint condition copy of this issue only last year tuclcedaway in a corner of a used book store" I held ey breath as Ipaid the too-good.-to-be-true price of 5AQ or so,) If you canfind a copy, check out the RCA ad on page 55, It's a publicrel-ations thing about "... a monster. The computer." entitled"Are they for us or against us?" Computers d.o "exactl1i'what theyare told, " says the ad, 0h yeah?John Conway invented LIFE. Computers proved that Conway's simplerules of living and dying have practically unlimited researchpossibilities. Each cell in the two dimens j.onal world is surroundedby up to eight neighbors. The cond.itions of those neighboring ee1lsplus the cell und.er consideration determine whether that eell willlive, die or be born on the next generation of all cells.The rules are!

1 ) Survival if a living cel1 has exactly two or three neighborsit will go on living

2) Deaths if a living celI has four or more neighbors it willdie from overcrowding. If a living celI has one or no neighborsit will- die of loneliness. (Can you stand it?)

3) Births if a non-livi-ng (empty) cell is surrounded by exactlythree neS.ghbors, a living ceII will be born in its place. Elseit will go on non living in the next generation.

The VIP display is the world of LIFE. In this version the worldis actual.ly spheri.cal with each edge and corner joining the opposite.This provides complete wrap around, and some unfortunate collisionsoccasi.onally. White bits iepresent living cells while dark bitsare the non living or empty oD€s.

Whgn ygu. flip to run, any pattern previously placed into memory page$0400-$04FF will be acted on according to the rules of LIFE. Youare actually seeing two separate pages because $o5oo-$o5fn is usedfor page switching to smooth out the animation. The program willrun with 2K of nemory of rnor€.You may enter patterns using the write mode of the VIP operatingsystem- to depoBit cells into the world at $o4oo. A better way isto use ong of the video drawing prograrns. The one in the VIP manualwill do, but you must enter the folLowing change so that the drawingis d.one on page 4.

0238 fron 0J to 04

Even better would be to eombine the two progr&rlsr but this has givenus hours of fun in this forrn. Actually I forgot about this progranand just found it on the bottom of a pile of papers. It was ny

2 ,OB/Og . 2?

Page 28: SHiffi::ii::. . .z.o'/os.u3

first machinethe VIPER was

language programhaving its birth

written about the same time thatpains, springing into I,IFE.

0000 go10 B620 3t30 00tlo A?50 FF6o FF?0 D680 3t9O FEAO FEBo 3tCo DllDO FEEo AllFo 76

LISTING

83 A5 AA AC AF FB 81 81 FB 46 A1 FBBD FB OI} B? BA BB BE F8 05 BF FB FFA4 FB 11 A5 FB 01 AD FB 2C A3 D3 6g5F BF FB FF 3A ?E AF BA FF og A7 DDDD BA FF 01 A7 DD BA FC or A7 FB oB07 A7 FB oB AD DD BA FC 09 A7 FB oBoB A7 BA FC oB AE 95 FE FE D6 B5 FBF8 15 A6 oE D6 FB 35 All oA D4 FB 5tA4 o? D6 oE D6 oA D4 FB 5t A4 Dll FBD6 OE FE D6 OA FE DI} FB 5T AI} D& FBFE D6 OE FE FE D5 OA FE FE DIl, FB .57

A4 o? FE FE FE D6 oE FE FE FE D6 oAF8 5I All Dll FB 3t A4 07 FE FE FE FEFE FE D6 oA FE FE FE FE D4 FB 5t A4o? z6 ?5 z6 ?6 D5 oE z5 z6 z6 ?6 D6Z6 D4 FB 5r A4 D4 F8 jt Atl 95 D6 FB

o2A23BBAADADT5A&3r3TA4FEn6D4OAT5

Bz n4E2 FB1F FBFC .07DD BADD BAt6 07o& FBa4 0?All o?DI} FBFE FEOE FEFB 3t76 Z6t6 07

oloo Z6 Z610 15 F6zo 4o 1A30 00 004o 9A T350 30 2A

0158 - olFF

0 200 D3 a?10 D3 FE20 00 0030 D3 FE

D6 FB T5 A6 OE15 1C FB 5t All30 35 oo 0o 0o0o oo F8 00 8373 5o ?z BA B?00 00 00 00 00not us ed.

Z6 z6 Z6n& FB 3r00 00 FB00 00 00BE BB FO

15 38 rLFC 01 3300 00 0000 00 00OO AA AF

0c 00 0030 10 oo00 00 0030 30 oo

Z63B1F00gF

::

n6all0000BF

OABAB300FB

r'6 95 ?E 85 30 oo oZ FE 3038 t5 1C FE 38 L9 1C FE 3800 00 00 00 00 00 00 00 0038 35 1C FE 38 39 t5 FE 38

03 0010 1C00 0030 1C

oz5o D3 85 FB oo 32 58 Bc FB oz 32 6o6o 0F FE FC 01 5F FB 00 A5 AC lo 50

Bc FB 03 3A 5noF FE 30 64

2,OB/09 ,28

Page 29: SHiffi::ii::. . .z.o'/os.u3

PROGRAUIMING HINTS

by H.C, I1UiII IV

Record (in voice) on tape, before each program, the pr.ogran narne,number of pages and the place where documentation and/or directionscart be found (tfris aids in the location and use of taped programsand the VIP Monitor overtooks peoples voices)..When debugging CHIP-8 programs put a D//f instruction in place ofa current instruction to see if it is being executed. If theinstruction is being executed, junk will appear on the scr€€rrrThis i-nstruction can also be followed by a "jump to itself"instructi.on. This type of debugging aid is helpful when tryingto find out which instructions are being executed, if they arebeing executed and in what order they are being executed. Italso aids in finding out whether "SKIP" instructions are "SKIP"ingor not. A jump to the beginning (or end) of the prograrn can alsoprovid.e the same results. An even more interesting implementationof this debugging tool is to call an assemb-l,y language subroutinethat in turn does a jurnp to the monitor (89f,9) so that you canlook at where the CHIP:-8 variables are stored. This "tool" isreferred to as a breakpoint.

SPACE WARS SPEED UP

by Tom Swan

The following modifications to Space Wars in PIPS FOR VIPS Iwill cause the phasor fire to go faster. It also speeds up thetarget's ability to take evasive action, so watch out!

038E 1582--

o3Bl+ I58B

osie FB oo7A AC AF

o5B2 05?684 663F85 Dgo88 0576BA OOEE

; Go to Patch #t

r Go t o Patch #Z

BF FB r IULS TOGGLE subroutine switches0F FB ; CHIP, B interpretQr betweenD4 oo ; h Lgt/I ow speed,.

r CALL TOGGLE MLS - switch to high speed;Patched instrueti-on from phasor sub; Return from Patch #t - go f ire phasorsr CALL TOGGLE MLS - switch to low speedr Return from subroutine ( instead of iumping

back

2,OB/09 , 29

Page 30: SHiffi::ii::. . .z.o'/os.u3

SIMPI,E SIMON ADAP TATI ON

by Tim Longcor

There was a printing error in the original code of the SimpleSimon game by Pete Kellnerr'VoI 2, Issue 2t at Location 032C.It should be 5780 instead of 3780, After I got the prograrnrunni-ng' I decided I would add skill Ievels and a time limitfor responding. \

At the beginning of the game hit key 1 through 4 for whateverskill level you would like to try" The winning sequences are8r L4, 20, ana 25 respectively. - If you take longer than 4seconds to respondr you will Iose. The speed of the game nowincreases after every fifth note rather than every note" Therest of the program operates the same as the origi.nal.

0200 1332

o 20 B I20C

o21A 22BA

0230 ry\ C

0232 23rc0234 r2o4

0274 12?602?6 D6B

o2BA 55rr'o2Bc F5r5

O2AA T2B2

o2B2 F 5o7o2B4 35oo0286 r2gg

0288 I2C0

02D6 1382

0332 FooA0331t 690A0336 4ooro33B 69oAo33A 4o 02o33C 6goEo33E 4o 03o34o 69LL+WLt z 4oo4Wt+t+ 6g1AWt+6 22Eoo3ll8 6600o34A L2O2o34c 57 90o34E ooEE

03 50 23ro0352 65050354 ? sFF0356 22t+oo35B 35oo035A 135403 5C FooA035E 4ooFo36o Izoa0362 4ooE0364 23200366 13 5c0368 4z o 5o35a 660 5o36c 4zoAo36n 660A037 o 47op03? 2 66oFo3?4 42il+

03?6 56fi037 B vZtg03?A 56Lgo37C B15oo37E 811E03 Bo r27 Ao3B2 23too 3 84 r2oo

FLIP=A-ROUND

This game shows the numbers 1 througlr p in a random sequence.The object is to arrange them in order from Left to right inthe l-east nunber of tries. An example of how the program worksis as followsl Suppose "2?Il+85396" is the starting sequenceoPressing key J will give you "84t725396o" Note tfrat only tnefirst five numbers "f1ip-a-round." After a few triesr fou willbegin to catch orrr

o2oo 6o oo 6I oo 6z oo A3 oF F2 55 A2 F210 F9 55 6A oo CB 03 CC 06 BB C4 llB oo20 FB 1E F0 6 5 lro 0o !2 711, A3 06 FA 1E

Fg 65 A2 FCT2 T4 A2 FC7A 01 Fo 55

2 .OB/O9 ,30

Page 31: SHiffi::ii::. . .z.o'/os.u3

oz3o 6ollo FE50 BB6o Fo70 FB80 FAgo L2AO L2Bo 30co 6zDo FllEO D1FO T2

FC FB 1Eoo rz 4o0o A3 05FF 3E 0055 A3 rz01 T2 EE05 T2 EE09 L2 EEAC FO OAo6 Fo 6509 72 C405 A3 TT01 02 03

F0 55BC EOFE 1EL2 54FB 653r 0235 a622 BA00 E0F0 zg6L 28Fo 65o& 05

3A og6n oAFo 65A3 o6A3 o672 EEL2 EE6o oo12 00D1 256z 18F0 zgo5 a?

rz LuBc D5A3 17FB 1EFB 5532 0316 0?6t lro00 E077 05A3 10D1 25oB og

5e 00 223F 0o 127D 01 FDFB 65 A37A 01 A312 EE 3312 EE 37F1 18 706U. oo 6rZb 01 A3Fo 65. Fo00 EE 22XX XX XX

00 A2oA 4nEo 6n55 7E1E FB33 30EE l4EE 38a7 rz0D A31E l4z5 77llo oo

BA&o1ET2OFol+OB01o9o6z9BAxx

ASCI I encoded keyboardsas low as $esl

The RCA VP-601 keyboard has a 58 key typewriter format foralphanumeric entry. The VP-61 1 ($t S additional.) offers the same type-writer format plus an additional 1 6 key calculator type keypad.

Both keyboards feature modern flexible membrane key switches withcontact life rated at greater than 5 million operations, plus two keyrollover circuitry.

A finger positioning overlay combined with light positive activation keypressure gives good operator "feel", and an on-board tone generatorgives aural key press feedback.

The unitized keyboard surface is spillproof and dustproof. This plus

the high noise immunity of CMOS circuitry makes the VP-601 and VP-61 1

particularly suited for use in hostile environments.' The (eyboards operate from a single S-volt, DC power supply, andthe buffered output is TTL compatible. For more information contact

rrGflRCA Customer Service, New Holland Avenue,Lancaster, PA 17604.

Or call our toll-free number: 8(Xl-233-0094.'Optional user price. Dealer and OEM prices available.

2,OB/O9 , 3L

Page 32: SHiffi::ii::. . .z.o'/os.u3

PRELIIVIINARYvP-3301

INTERACTIVE DATA TERMINAL

M icroprocessor GontrolledColor Graphlcs

Low CostASCII Encoded

Programmable & Resldent Character $et

loop with six switch selectable baud rates. Switchsetgctable configuration control includes line/local,upiier case only, f ull/half duplex, data wordformatting, plus two control code options.

A built in tone generator, used for aural keypressfeedback, can be programmed for end-of-line bell,error messages or even music.

The terminal utilizes modern flexible-membrane, keyswitches with a light positive activation pressure.Contact life is rated at greater than five millionoperations. A finggr-positioning overlay combinedwith the positive keypress action gives good operator"feel". The unitized keyboard surface, impervious toliquids or dust particles, combined with high noiseimmunity CMOS circuitry make this unit particularilysuitable for use in hostile environments.

The base band video output can be directlyconnected to a 525 line color or black and white videomonitor or with RF modulation to a standard coloror black and white TV set. A wall receptacle type 5 volt650 mA power supply is included.

IRG/il THffifl'PUtEr

This professional quality terminal is suitable for awide variety of industrial, educational, business andpersonal applications requiring interactivecommunication between computer and user.Microprocessor intelligence and LSI video controlintegrated circuits bring performance, features andflexibility at low cost

The character display format, 40 characters by 24lines or 20 characters by 12 lines, is softwareselectable. Each character or all characters may bedisplayed in one of eight colors (or gray scales onB/W display). Display background may be one ofeight colors (or gray scales on B/W display). Thereare 125 resident displayable characters or you candefine your own characters - Greek letters and otherforeign alphabetg, graphic symbols, large graphicsbuilding blocks, playing card suits, unique characterfr:nts, arrd "little green men". Reverse video featurecreates visual emphasis on single or multiplecharacter, words or lines.

The terminal communications interface is industrystandard asynchronous RS-232C or 20 mA current

2,OB/09,32

Page 33: SHiffi::ii::. . .z.o'/os.u3

VP-3301 lnlrrtctlvr Dete TrrmlnelSprdllcrtlonl - [PnllmlnrryJ

KEYBOARDFormrt 58-key typewriter format - includes two user-dofinablekeys (Switch clorures).

Kry Swllchor: Flexible membrane, polycarbonate material.

Rollovcn Two key.

Urr Drllneblo Kryr: Two SPST switches (30 V, 0.1 A, 1 W max.).

Kcy Lllr: Greater than S-million operetions.

Audlo: Onboard speaker gives aural keypress feedback. Alsoprovides bell and error indication. Programmable frequency.

Codr: ASCII (American Standard Code for lnformationlnterchange).

Cherrctrr Sol:Standard Ugper/Lower Gase - 128 codes generated:

95 printable characters33 control characters

Upper Case Only (Switch Selectable) - 102 codes gonerated:69 printable characters33 control characters

Brrrk Kry: Causes continuous transmission of binary state zero.

DISPLAYScnrn Formrt Software selectable, 24 lines of 40 characters or 12lines al 2O characters, one page of data.

Chenc'lcrFont 5 x6 dot matrix in a 6 xSblock, descendersforlower case characters.

Roldmt Cherrc'lor Sot S2-upper and lower ceee alphabeticcharacters, 1 O-numerals, 32-punctuation and math characters, 31 -control characters (Switch selectable control character display forprogram m in g convenience).

Urr Drflnrbh Chrnclon: Any bit pattern in a 6 x 8 characterblock may be set with a command control sequence. A total ol 125characters may be defined at one time.

Cunon Blinking revorco video. May be set to mid-blinking orturned olf with a command control soquenco.

Rovcno Yldoo: Control character turns rovorse video on and offpermitting one or multi character, word, or line rgvgrse video.

Chrrrclrr Color/lntrnrlty: Choice of 8 colors or I levels of grayscale.

Beckground Golor/lntrndty: Choice of I colors or 8 levels of grayscale.

Srrlel Vldro: Composite color video line, NTSC compatible. 1.0 Vp-p ipto 75 O termination.

Vldro Connoclon Female, RCA phone plug.

USER CONTROLSwltch Selcctrbfr: Baud rate, current loop/RS-232C, line/local,upper case only, full/half duplex, parity bit-even, add, mark, orspace, 1/2 stop bits, control execute ON/OFF, control displayON/OFF.

Control Chrnclcrr: Back space (cursor F), linefeed (cursor l),upline (cursor t ), fore space (cursor-r), carriege return,horizontal tab, bell, clear screen, home cursor, delete, reversevideo on, revsrse video off.

Commend Control Srqurnc.l: Character color or gray scale,background color or gray scale, locate cursor, clear to end of line,clear to end of scFeen, define character bit pattern, keyboardON/OFF, display format (40 x24/20 x 12), cursor ON/OFF, displayON/OFF, define command control delimiter, tone generator.

RCA MicroComputer ProductslNew Holland AvenueLancaster, PA 17604

INDICATORSGlur to Sond: LED on when "cleer to send" trus, acts as power onindicator when "cloar to send" not used.

Brll: 250 m sec. audible tone.

Erron Beeping audible tone indicate input or output overrun.

DATA FORMAT - TRAl{SilITllcthod: Asynchronous; serial-by-bit; serial by character.

Codc ASCII; 1 start bit, 7 data bits, 1 parity bit (odd, even, mark, orspace), 1 or 2 stop bits.

todo: Switch selectable: half or full duplex, line/local.

EIA Delr Rtlc:110,300, 1200,4800,9600, 19.2K baud; switchselectable.

CL Drtr Rrlr: 1 10, 300 baud; switch selectable.

Gontrol Slgnrlr: Request to send (output signal), clear to send(input signal), EIA RS-232C compatible.

DATA FORMAT - RECEIVEtcthod: Asynchronous; serial-by-bit; serial by character.

Codc: ASCII; 1 start bit,7 data bits, 1 paritybit-ignored, 1 or2stopbits.

todc: Switch selectable.

EIA Drtr Reto:110,300, 1200,4800,9600, 19.2K baud; switchselectable (Clear to receive signal must be used for data rates )300 baud).

CL Drtr Rrlr: 110, 300 baud, switch selectable.

Chereclcr Relc: 508 character-per-sec max.

Control Slgnelr: Clear to receive (output signal), EIA RS-232Ccompatible.

COM MUNICATIO}IS INTERFACEEIA: RS-232C compatible, t 12 V nominal output signal voltage.

Currcnt Loop: 20 mA to 60 mA max, voltage capability 30 V max.

todr: EIA or current loop switch selectable.

Connrcton 25 pin, female, subminiature "D"-type"

PHYSICALSlrc: 13.1" L x 7" D x2" H.

Shlpplng tilclght 5 lbs. approx.

POWERlnput: 5 V DC @ 650 mA nom. from included 120 V, 60 Hz wallreceptacle type power supply.

Swltch: Power ON/OFF,

ENVIRONlTENTALTcmprrllurc:

Operating: 0 to 50o CStorage: -40 to *85" C

Humldlty: 90% RH @ 30o C, non-condensing. I

Vlbretlon: 3-axes - .3" p-p, 5 to 14 Hz39, 14Hzto2KHz

Shock 3-axes - 50 g, 11 m sec, 1/2 sine wave.

Printed in U.S.A./3-8OvP-3301

2.Og/09.33

Page 34: SHiffi::ii::. . .z.o'/os.u3

VIP Keyboard by Doug Wo1-f

This program turns your VIP into a four octave keyboard. The program usesthe Sinple Sound Board VP595. It uses CIIIP-8I which ls CHIP-8 wiith the followingchanges:. starting at 01A4: 86 FA 01 3A AC E5 63 D4 E7 45 FA 01 3AF2 63 D4, and starting at 01F2: 3F EZ 68 3F F5 D4. To cover four octavestwo keys are used to either increment of decrement the octave presently used bythe keyboard.

The keyboard:L23c456D7898AOBF

is equivalent to:D/l x Ell ellDEFGA B C (htgheroetave)A# X C/l (l-ower octave)

V0=frequency selectVl=key input 1, no noteV2=octaveV3=key input 3

Variables

V4=key input 4 V8=key input 8

V5=key input 5 V9=key input 9

V6=key input 6 VA=key i.nput AV7=key i.nput 7 VB=key input B

VC=key input C

VD=key i.nput D

VE=key input E

VF=key input F,(note duration)

When MI=00 no note is pJ-ayed (no keys are pushed).Tables of notes start at 29O. The four octaves are in sequence. Each

octave is in this order: 00, D#, xX, F/1, D, E, F, A, B, C, A/1, Cll, gtl, e.

InitLaLLze Values

0200 6101 V1=010202 6200 V2=000204 6303 V3=0302A6 6404 V4=040208 6505 V5=050204 6606 V6=06020C 6707 Y7=A7020E 6808 V8=080210 6909 V9=09AZLT 6A0A VA=OA02L4 6808 \IB=0802L6 6C0C VC=0C0218 6D0D \ID=OD021A 5E0E VE=0E02lC 5FFF VF=FF0218 6000 V0=00

Scan Keyboard for Notes

I=290If (Vl*hex k.y) skipT=29LIf (v:#hex k"y) skip

0220022202240226

A290E 1A1

F 118

E3A1

2,OB/O7. 3+

Page 35: SHiffi::ii::. . .z.o'/os.u3

0228 F31E T-293022A E4Al If (V4#hex key) sklp022C r41E I=294022r. E5A1 lf(vs#hex key) skip0230 F51E T=2950232 E6Al If (v6#hex key) skip0234 F6LE T=2960236 ETA1 If (v7#hex k.y) skip0238 F71E T=297023A ESA1 If (V9#hex k.y) sklp023C F81E I=298023E E9AI If (V9#hex key) skip0240 Fg lE T=2990242 EAAl If (VA#hex key) skip0244 FA1E T=29A0246 EBAI If (\m#hex k.y) sktp0248 FB lE T=298A24L EcAl If (VC#hex k.y) skip024C FCIE T=29C0248 EDA1 If(VD#hex key) skip0250 FD1E T=29D

Scan Keyboard for Octave Change

0252 EEAI rf(\rErthex key) skip0254 1278 Go to 0278 Subroutlne to lncrement octave0256 EFAI If(VF#hex key) skip0258 L284 Go to 0284025A, F21E I=I*V2 Select octave

Check for No Key Pressed

O25C F065 VO=MI Get toneO25E 4OOO lf(v0rl00) skip0260 L27O Go to 270 Subroutine for No Key Pressed

Sound Generated

0262 8100 Output port=VO0264 FF18 Tone duration=VFA266 L220 Go to 0220

Subroutine for No Key Pressed

027 0 6100 V1=000272 Fl18 Tone duratl-on=Vl027 4 6101 V1=01 Reset Vl,O27 5 I22O co to 0220

Increment Octave

0278 422A rf (v2*2A) sktp027L L22O Go to A220027C 72AE Y2-Y2+0E0278 EEAI If (VE*hex k.y) skip0280 L27E Go to 0278 hlalt for key release0282 L220 Go to 0220

2,OB/O7. 35

Page 36: SHiffi::ii::. . .z.o'/os.u3

Decrement Octave

0284 4200 If (v2#00) skip0286 L220 Go to 02200288 72FZ Y2=Y2+820284 EFAI If (vF#hex key) skip028C 128A Go to 028A Wait for key release028E 1220 Go to 0220

Note Table

o2go 00 B0 00 94 BB A6 9D FD

0298 DE D2 EB C6 84 8n 00 5802A0 88 49 5D 53 4E 7 e 6F 6802A8 7 5 62 41 45 00 28 BB 240280 2E 29 26 3E 37 34 3A 310288 20 22 00 ls 55 12 16 L402c0 13 lE 18 19 lD 18 10 I 1

The New York Amateur Cornputer Club has annor.rnced the creation ofa regular "Computer Faj-r and Flea Market" to be held on the firstSunday of each month.Conputing systems exhibiting applications software, computercompany vendorsr r€pr@sentatives from local computer clubs' wiLl-be there. Meetiogsr lectures and tutorials on hardwarer softwarerbusiness systems and beginneret classes wil-l also be held"

PLACE r Irving Plaza12 Irving Plaee (corner of East 15 St. NYC.)

TIIIEr 11am.to 5pm. Lectures from 1pm.ADMISSIONT $1,50DATEST March 2, April t3, May 4, June 1

For more information,r contact Daniet at 212-263-3003 or phone theNew York Amateur Computer Club at their "Hot Line" number 864-4595.

sET cARRr/ILEAR cARRy

by Tpm Swan

The 1802 rnachine language instruction set contains no instructionsto dlrectly set or cLear the one bit carry register DF. Normally,the procedure is to rotate a zero or a one Uit from D into DF buiof course this will change the value in D. A sirnpler and shortermethod is given beIow. -

To clear DFr ADI $OO ;Add 0 to anything sets DF = OTo set DF r SMI $00 ;Subtraet 0 from anything sets DF = 7

Notice that only DF is changed by either of these commands thevalue in the D register is not disturbed.

2,OB/09,36

Page 37: SHiffi::ii::. . .z.o'/os.u3

VIP TINY BASIC MACHI$TE LANGUAGE SUBROUTINE

by Andrew A. Modla

SeveraL vlP computer hobbyists have expressed a desj,re to callnachine language prograns from TINY BASIC. Although hooks tomachi.ne language programs were not desigred into TINY BASIC dueto space limitationsr there is a way to execute machine languageprograns. The technique fakes a new statement tree and whenexecuted by BASIC, call-s the machine language program.Statements have the following internal formatr

Binary line No. i!aa

Length ofStatement

! Statement ;i type code !

D End ofStatement

2

The machine language program resides in the source statement area.To eonstruct a machine language progratn, do the following steps:

f ) Clear the statement area by tlrying NEW.

Z) Enter the following two BASIC statements:1 G0r0102 REM

3) Holding down Key E enter the VIP operating system by turningon the RUN switch.You will be modifying memory as follows:

SS

ourc e itatement !

ADDRESSffiL2T3L2T4

LZI| to 12321233

L2341zFF

DATA1300 fhis is the new free memory addressED l,ine 2 statement lengthCll Machine language statement tlpe4E PrintabLe Character E (fiffer)0E Causes inner interpreter to enter machine

languageYour machine language program starts here

0D End of statement code

The machine language program must end with DO 03 08 99 whichcannot extend. beyond. location 12FE. This means you have L99decinal bytes available for your machine language subroutine.00 and 0D cannot be used in your ML program. To load 00 intoD use 9t (cnr 1).

ll) Holding down the baekspace key on your ASCII keyboard, turnon the run switch. This proeedure prevents the loss of yourBASIC prograrn.Add the following line r

3 REltrRNYour BASIC program begins with line 10.You call the machine language program with a GOSUB 2.

2 , OB/O9 ,'3'?

Page 38: SHiffi::ii::. . .z.o'/os.u3

fhe following information is useful forprograms r ,

maehine language

f) The Ml, subroutine program counter is register 5.Z) Use only registers R?, RA, RB, RC, RD, RE, and RF

3) R5.1 contibe "rt"""ii""tlt8olage

address of the variables and must not

4) fhe display starts at location 1OOO (one page)

5) The'variables A-Z start at location ttU? (two'bytes per variable)6) The aruay A starts as the free address in 11BE

7) The stack occupies the last page of memory and the low orderportion may be used for storage. (Page address RZ.1)8) The BASIC source program starts at IZOA,

LITTLE LOOPS by Tom Swan

PRII\M TIIIIE

They just finished building a bul-lring right below our windowit's painted bright red and yellow and orange, and it's the

icing on the cake of our now brown Mexican countryside. Herethey do not have bloody Spanish bullfights 'chey are more likerodeos though there is far more drinking, taco eati-ng, laughingand shouti-ng in the stands than ther:e is action in the ring. -This has absolutely nothing to d.o with this month's column,unl-ess you want to compare a Mexican's interest in rodeos withmy interest in BASIC language programming. Every eouple of weeksthey have a rod.eo, then everybody goes back to normaL. Everyonce in a while, I write a program in BASIC (even on our new "baby"in the house, a^n APPLE II, I'm more interested in machine languageprogiamrning. ) Problem is, I seldom go back to normaL.I donlt want to sound too "ho-hum" about BASIC. It offers a goodway to learn prograrnming and judging from the number of read.ersletters and articles this month, a lot of you own VfP Tiny BASICBoard.s. iHtp-8 is also an excellent languige for cutting-yourprogramming,teeth. Though it lacks the readability of a d.ocumentedBASIC program, it is more suitable for use on a VIP computer. .

the following program is straight from an algorithm (that means aprocedure or plan for a programming task) from Vol 1 of The Art of'Computer Programming by Donald E. I(nuth r page 143, It generatesa list of prime numbers as many as you ask for up to the limitsof your il€rrorlr variables size, and patience. One interestingline (#ttto) gives the remainder after a division provi.ding thefunction X MOD Y which is not in Tiny BASIC's vocabulary. You mayleave the REM's (remarks) out without affeeting the programNotice that the little b's with lines through them are spaees (b).

writing

2,OB/ag, 38

Page 39: SHiffi::ii::. . .z.o'/os.u3

But what lf you don't have the BASIC board? In that case you willnscd to progran in either 1802 machine language or CIIIP-8 probably.In fact' that brlnge ne to the point I would llke to make. Therearc tont of BASIC programs out "there" and only a few klLos ofCHIP-8 prograns (we're doing our best to change that). .BecauseBASIC ls fairly easy to read and. understand, even if you don'thave the board, you should try to pick apart a few BASIC programs.One thlng that may surprise you is how easily a BASIC listingtranel,ates into CHIP-8| At first this may seem to be awkward,eepecially if CHfp-8 j.s new to your Here are a few suggestionsto help.

BASIC - PRINTCHIP-8- Printing numbers is not difficult but words are

another thing. Those of you with PIPS FOR VIPSVol- I can use Messager to translate PRINT statementsto CHIP-8. Otherrlrrise just leave the PRINT lines outor simplify them graphically using DXYIII instructj-ons.

BASIC - Less apd greater thalcHrP-B-

VF:-:-33"tli'iil:*i::J: ;::';u:tt"; Ti.rTnSl J33l*r""(x:Y).

BASIC - Subscripted variables (e.g. A(N))CHIP-8- Define a memory.area.to hold the aruay of nr:mbers

ti:ii:ll:i: $i'I,ffi}' "# 3?l:ixii*H?i;?ii:,

instruction which sets Yi = A(N)

Insert Y/ = VX into A(N) *tiil-toSS instruction,BASIC - MuLtiply and divideCHIP-8- \rlpite- sirbroutines in CHIP-8 or machine language for

these functions.

l^lith these four suggestions and your VIP manual, you should be ableto convert PRIME IIME to CHIP-8. One problem still remains,however' When you PRINT something in BASIC, everything else scrol-lsgP to naEe room for the new line. That is not.so easy to simulatein CHIP-8, so next month I suppose I have my work cut- out for me!Good lucklPROJECfS r

1) Convert PRIIUE IIME to CHIP-8.

il Speed up the BASIC LISTING by using TVON, TVOFF instructions.After all primes have been calculated, print out a neatly formattedlist from the amay (A(N) instead of one at a time.

z,08/09 , 39

Page 40: SHiffi::ii::. . .z.o'/os.u3

510203035llo4S4g5o555B596o7aBO

90g4e599100110111TT2T13r74I20t30t4or49t5ar59t6or69170180999

Contestr First person to write to me with an explanation of what"cHrP-8" means wins a free cHrp-B game (undocumeniea uut wiitj-nstructions) never before publish6d. in ""*" of postmark ties,the first correct answer t iee wins. r figured it o;t-::-'"""-v6"e(Even Rick Simpson doesn't ffi* ---at feas{ that,s what he told me!)NorTerryr $ou are not eligible.PRIXE ,TIXIE LISTING

REM REQUIRES VIP TINY BASICCIS \PR]NT ''HOW MANY PRIMES ''

INPUT XIF X<2 T}IEN 10PRINTPRINT ''OK. HERE GOES! ''REM FIRST PRIIM IS '2'A(1) = 2PRINI "1 = 2"REM J IS NUMBER PRIMES FOUNDREM N IS ODD cANDIDATES (T-,TTn IGNNEDY AT THIS poTxT)N=jd-l_

J=J+1A(J)=uREM OUTPUT PRIIUE NUMBER;RiN'i

- ;; ;l=i;;- n( } i -'---.

REM TEST FOR DONEIF J=X TItrN 999N=N+2REM NOW DIVIDE CANDIDAIES BYREM PRIMES FOUND (A(K)'S) SO FARREM Q IS THE QUOT]ENTREM R IS THE REMAINDERK=2Q=N/A (K)R=N-Q*A(K)REM PRrnm PossrBLE? (ny'o)IF R=0 TIIEN 110REM PRIII{E? (Qs=pRnM DIvISOR)IT Q(=A(K) THEN 80,REM N IS NOT PRIIUEli=r*fc0T0 130END

LAST MONIH''S ANSWERST

f) Wipe Off Modifications -- Auto Speed Up (plus auto restart onKey 0 at end of game.) Load CHIP-8 lnlipe Off and normal CHIP-8 aslisted in the VIPmanual then enter the fol-lowing.

00Ac Ec - - Switch to Hi- speed CHIP - B

0218-I

0234

a;iz

67OA, ;V7=0A Optional -- # bal1s = 10 for higherchallenge

1300 INII Jump to initialize V8,V9 each baLl

t3t} TIIUE Jump to speed eontrol during play

2.OB/O9 , 4O

Page 41: SHiffi::ii::. . .z.o'/os.u3

ozgc-I

oac Ioi6o rNrr r

o2olto6

o3o IOA0cOE

031 0T21,4$1B1A

o32B RSTRT I

'242C2E30

0202oza5020c0?*0284a2cc

1308 CHNGE

1328 RSTRT

5 804 I V8=Oll6goll I V9=obFFOA ;ttlAIT1?:'6 RET1

FFOA ;WAIT3F00 ; SK=0I32B RSrRT0080 ;ERASET2OO BEGIN

?ao6 ;v0+5 --TIOZ ;V1+OZ -rLt 6Dc ; sK/oc --

CHNcET 48oo ;SK/o1318 C23900 ; SK=01316 c1

6g04 ;v9=04TBFF rVB-1t31B C2

C1 r 79FF Y9-ICZr A?CB BAIL

I29E RETa

031 C TIMEr FBI 5 ;Tf=VBlE T1 I FF07 i VF=TI20 3F00 ; SK=022 ttrE irr2I+ A?CD PADDL26 rz44 REr3

Jump to increase speed each paddlehit

Jump to restart on Key / -- end of game

-- V8=speed--vaIue=starting speed-- V9=increase--va1ue-fpaddl-e hits to increase-- Patched instruction from 0234-- Return from INIT patch

If speed / O, jump to O3OCIf speed = O, (friehest speed) Jump to exitff increase 1 0, then jump to speed upIf increase / O, jump to d.ecrement Vp

(no speed up)-- Reset V9 = fpaddle hits to each increase

Speed up ball by factor of 1Jump to exit

-- Decrement V9- no speed up this paddle hit-- Patched instruction from O29C-- Return from CHNGE patch

TIIIER = value of VB (auto decrement)-- VF= current timer value-- When timer goes to 00, skip to exit-- Else loop to test timer again-- Patched instruction from OZUZ-- Return from time patch

-:- Wait for any key to be pressedIf Key /, stip to start new garne

-- EIse loop back for another kelpress-- Erase sereen--prepare for new game

Jump to begin new game

the Wipe Off ball to speed up once everyflies at top speed. There are four speedthese para:neters, change the values ofAlso please note that the change to

I prefer a shorter 10-ba11 game, butof turns you wish.

Spacing between each columnSpaeing between eaeh rowChanse s c or€- -DC = 120 maximumDat a7 o zCC= Do t s / o ICD=P addl e

NOTE I Ihese changes eausefour paddle hits until itchanges overall . fo varythe following loeatioh,s .Ioeation OZ1E is optionalyou may select any number

o3010303 r 0 3IIo3og

In addition to the changes above, the following create a d.ifferentaction filled game. (NOTE: Addresses are not sequential. Be gureto enter the changes at the right addresses.)

LOCATIONS OF INTEREST

Starting speed of each ball (0O=fastest)-- Number paddle hits. to each speed change

(Value at A3O3 must equal vaLue at 0311 )-- Top speed of balls (0O=fastest)

SI]PER DENSE WIPE OFF VARIATION

5A0A r VA=0A r- Change to 10 rows of dots5g0B tVB=08 -r Change to II columns

9oEo

2,OB/O7, 4L

Page 42: SHiffi::ii::. . .z.o'/os.u3

\

2) UIIS TOGGL I

F 800BFFSACAFOFFBEC5FD4

NEXI MONTH r SCROLL UP

e ompletelJ relocatable

TOGGL r LDr $ooPHI RFLDr $ACPLO RFLDN RFxRr $ncSTR RFSEP R4

FOR THE

; Set RF to $O0AC--address; inside DXYIV instruction; in CHIP- B interpretera,

; Get byte e $ooAC; Flop from $nC to 00 , or 00 to $nC;Put back to change speed;Return

MYSTERY TOUR

Video 0perating System" byin the schematic. The correetdisplays are! pins # 4 and#5 of the top display isprinted s ehematic .

CORRECTIONS CORRECTIONS CORRECTIONS CORRECTIONS OH NUTS CORRECTIONS

VoL I ISSIIE Lt, oCT . 19? B PAGE II "NonJoseph Cza jkowski contains an errorp in c onne e t ions f or the HP 50 B2-? 340#A to ground; pin #5 to enable. Pinineorrectly hooked to ground, in the

vOT, 2 ISSLE 5 NOV. 1979 PAGES 2,05,16 and 2.05,!9 "FootbaLl" byFrarrk Awtrev c ontains glut^',*gmT,lt ";l"fi"rors !

'/W/ ' ia/z not relz

Thanks to Tim Longcor for weeding theSe little buggers out.

Just a quick note that may be of interest to other Elf'ers whoenjoy the VIP modifieation in issue #9 April 1979. In additionto the emor previously brought to your attention l,oc " 8104should be 3E not JF - Irve discovered that some of the longerprograns in the RCA game manual crash because they get into theCHIP-8 display page relocated at page 7, To correct this changethe instruction at l,oc. 0CF0 from FB07 to F808. A11 works wel-l-noWo - Walt Pinner

APOI,OGIES

we had hoped to never have to do a combined. issue - but here isjust exactly that. f had pneumonia for three weeks j-n Februaryand early.March - and no sooner did r recover from that when m!$SqSnter (who lives in California) had a real catastrophe itt n6"life and I had to fly back to be with her for the next two weeks.so the result wasr no newsletter in March. sure hope this bigfat issue helps make up for it all. Terry

2,OB/Og , 4Z

Page 43: SHiffi::ii::. . .z.o'/os.u3

MORE IINY BASIC MACHIIIE I,ANGUAGE SUBS

by C. D. Smith

Recently you received a procedure from Andy Modla for adding anachine language subroutine to the ROM based VIP Tiny BASIC'(Part number W-?OO). I have enclosed a procedure I developedusing Andy Modlars memo to allow calling sever4l machinelanguage subroutines. I intended it to be self explanatoryhowever, if you have any questions about its use please contactme through the VIPER.

IM0001 . .0002 r r0003 , .0004 r.0005 r.0005 ..0007 o .0008 ..

VIP TINY BASIC MACHINE LANGUAGE SUBROUTIIYE

C .D. SMIIH BO-01-OB INITIAI RELEASE

BEGIN BY INITIALTZING THE STATEMENT AREABY ENTERING

0000 i0000 t0000 t0000 t0000 t0000;0000 t0000 t0000 t0000 t0000 i0000 ;0000 i0000 i0000 t0000 t\- 0000 i0000 i

ffiffi1I23LlTryLTr234I234I23LIr234

Lzt+5 iIzLt6 t\.- 1246 t

0009 .o NEI/U

0010 o o

0011 r o

001'2 . .oo13 r ,00il+ .,

1233 0E r oo22 CODE r '#on

TGOTOlO2 REM A MACHINE TANGUAGE SUBROUTINE.

NOTE ! Tlm ABOVE THREE STATEIIENTS I\,IUSI BEENTERED EXACTLY AS SHOhIN.

RESEr/TffiY E/RUN

OOt5 ..OOT6 .. E)ffiCUTE T}IE VIP OPERATING SYSTEM BYo0I7 r r0018 o r

0019 . . MODIFY MEMORY AS F0I,LOI/US0020 . ,002I

0023 . o

a024 0 r

0025 . r0026 ..0027 !.0028 ..

oRG #t233

T}IE USER PROGRAM CALL STARTS HERE

N0TE 3 USER PROGRAM CAI,L MUST NOT CONTAINETTHER A #OO 0R A #OD,

LDI A, o (tPC ) rPL0 FSEP F

T4L[ 0029 r. . r . . . . o r ! . I . .La.)a , \twa.7 . . . . . .

tnt+ F812BFI 0030 VIPUSRT LDI A.1(IPC);PHI F1237 FB3BAF; 003tI23A DF; 0032I23BI23BL23B

0040 .

0033 ..' 0WLt VARZ=#IID70035 .,

I23B F811BE r 0W6 fPL23E F8D9AE; 00377241 r+EB 548A5 t 00 381245 D5; oo39

Cr tDI A"1(VenZ);PHI ELDI A.0 (VARZ ) IPI.,O ELDA E;PHI 5;LDA E;PLO 5sE" 5

00M .,OOI.I,2 .. USER PROGRAM CAtt ENDS HERE

2,OB/O7, 4l

Page 44: SHiffi::ii::. . .z.o'/os.u3

LZLl,6TzLI6r246LZLl,6L2l+6Lztr6T2L+9724AI24BT24BLZll,Br24eTaLIBIzLl,BI24Br24eL24e11 BETTgOLT9OTT9OTT9OTTgOL2T372r4Lzr 5T2T 5L27 5T2T 5r2r 5rzr 5Lzr 5T2T 5T2T 5T2T 5r2r 5Lzr 5L27 5r2I 5Lzr 5T2T 5r2I 5'T2T 5I2r 51,2I 51,2r 5T2T 5r2r 5r2r 5I?7 5Lzr 5r2r 51 400tho3t$o6

o&o3o B;OO././)oDi

a,a,a,t,I,I,a,a,

iF811BF ;FBDgAF;gr5F1F;

a,I24Bia,a,a,a,a,

38tcUia,a,a,a,a,a,a,ata,t,,tI,I,a,I,a,O

,a,a,I,t,I,a,a,a,a

,

oo43 ..oo44 .. NOTE: YOUR MAcHINE IANGUAGE PRoGRAMoo45 .. MUST END IIrTH A tONc BRANCH TO ENDING :ooll5 r o

OOI+Z gRG rr

oo48 ENDrNcr sEP 4,#0308oo49 cnr 90050 LDN D005r o.oo52 . r BASIC CoNTINIIES FRoM IIEREoo53 0. \

oo54 BASIC: ORG *oo55 ..oo56 o r MoDrFy NEXr BASrc STATEMENTOO57 . O TOCATION AS FOTLOWS0058 ..oo 59 onc #r r 8noo6o IvExT ! ,A(gAsrc )oo6t o.oo6z .. MODIFY STATEMENT 2 I,ENGTH AND TY?E0063 .o AS FoLLowsoo64 o.oo65 one #tzt3oo66 IENGTH !,A.0 (nAstC-r,nucgit)oo67 TIPE z ,ffcVoo58 . o

oo69 , o RESTART BASrc By Rnsnr/nacrseecnr/nutt0070 ..OOTT I ' ENTER A RETIIRN STATEMENT AS FOLLOVfSoo72 ..oo73 .. 3 RETURNoo?4 .,oo75 .. FoLIohIED By A BASIC PROGRAMoo76 . .OO77 . . r . . . . . . . r . . . . . . . . . . . . . . . . . . r . . . . . . . . . . . . . . . . r .0078 ..oo79 .. EXAMPLEooSo o.0081 r. 5 REM LET Z=ADDRESS 0F SUBRoUTII\E(BASE rO)0082 ro 10 Z=5!2Ooo83 o, 15 cosuB 2oog4 o. zo PRINT z0085 . o 25 G0T0 100086 ,o 30 ENDoo8? o o

0088 r. THIS rs rlIE TEST nr'4 nouttun0089 , . FoR THE HoME EI\nrIRoNX[ENT MONITOR.0090 , . Tlm STATE oF EF4 rs TESTED AND VARIABT,EOO9T I I Z IS SET TRIIE IF EF4 Is TRIIE AND sETOO?Z .. FALSE OF EF4 IS FALSE.0093 . rooglr .RG 5120oo95 EFTEST : LDI A. 1 (VARZ ) ;PHI Foo96 LDI A.O(VAnZ);PLO Foo97 cHI 1;STR F;INC F

2,OB/O9 , 44

Page 45: SHiffi::ii::. . .z.o'/os.u3

t4o9 3FOE I1ll0B F80111ll0D 5Fl14oE co 1 zt+6 t!+Lr t0000

oogE00 gg01000101 EFEXfT r

0102

BNI} EFEXITrDr #otSTR FtBR ENDTNGEND

Extended Oisplay Subroutine \

by C. H. Anderson

CHIP-8 calling sequence!AMMM: Point rrlt' to data set describing object to be displayed0300: Ca].l extended displal' machine J-angruage routineFxFy: VxrVy coordinates fo: the object

Data format: starting at MMMNB: Number of bytes on each lineNL: Number of linesData: NB*NL bytes describing object

Register Al-location:R6.O: CHIP-8 variable pointer; shift foop counterR7 : Used to hol-d bits in shift operationRA : Memory pointer for data block, CHIP-8 ,J, pointerRC : Display memory pointerRD.O: Loop counter for bytes displayed on each lineRD.l: Storage for NB, number of bytes on each lineRE.Or Counter for lines, initialized with tU,

RE.1: Storage for number of shifts (Vx ,AND,, 07)RF.O: Storage for the starting value of RC.O on each LineRF.l: Hit Flag; initialized to 00, changed to O1 on hit

Ttre stack is used to store the carry ovef bits_of each sbiEt gperation.0300 , 22 s Decrement Stack

0 30103o7OA

0 30E10LsLA1D

| 45 A6:06FA07S06FA3F!F6F6F6

BE

52

E2 AC7E BC

AFBC

: R6 points to Vx: V>@07=XL; put into RE .1s Vx@3F; ensure ob ject is on display: divide by B and store on stack

45o6FBBC9C

A6FEo0FE7E

FEBFACBC

R6 points to VyA*Vy put into RC.OClear Hit Flag;0O+carry put2* (4*Vy) put into RC .0Put high bits of B*Vy into

in RC'.1

RC .1

0320: BC F4 AC24r 9C 7C 0C

Add vx/8 into RC.0rput it into RF.0Add 0C into RC .1

Store NB in RD. LStore NL in RE.O

0328: 4A BD2A: 4A AE

too

Page 46: SHiffi::ii::. . .z.o'/os.u3

Extended Display Subroutine ( cont)NEW LINE O32C :

2El,CONT LINEO331 :

34:36:

0338LOOP 3A

3D40

SHIFTEI\TT IIT

9DF8

FB9E4A

3097B726B6

AD00 s2

00 A7A6874TF6 8776 A7

3A 3A

Put NB into RD .0 ( counter for bytes )Clear stackClear R7 .0Put XL into R6 .0 ( shift counter)Data byte put into R7 .1GotO SHIFTENT \Shi f t contents of iR7 . 1 to rightShift carry over bits into R7.0R6- 1

If R6.0 is not zero goto LOOP

WRITE

o344474B4B4E51

F4 8797ECF2FB97E2

32o1F3B7

4EBF5C52

: Add carry over f rom last byte to R7.1:SetXtoC: Test for hit, if not goto WRITE: Hit Flag =0L: Write byte to di splay with: Store new ca rry over b te

''XORon st u"U

;ound )

doesn't/changev

(Increment RC to next byte on line, test for and correct X wrap a

0354:8C FC 01 Ac : RC.0+01rdo it ttris way so Rc.l58: FA 07 3A 60 : @O7rif not O goto CONT' 5C: 8C Fr OA AE : Move Rc.O up one line on displa

CONT 60:2D BD 3A 31 : RD.0-01rif not O qroto CONT LINE(write last carry over bits on ]-ine)

0364: 87 : Get carry over byte65: EC FZ 32 6C : Test for hit, if not goto WRITE269: F8 01 BF : Set Hit Ptaq to O1

wRrTEz 6c: 87 F3 5c : write to display with "xoR'!'6Fr E2 : Reset X to 2

(Move RC to next l-ine, test for and correct Y wrap around)O37O: 2E BE 32 87 :NL-L, if 0 goto EXIT

74t BF FC Og Fc eF : Get first value of RC.O onto next linerstore new RC.0

79r 9C 7C O0 BC : RC.l+carry7D: FF 10 3A 2C : -(0C+04), if not 0 goto NEW81: 9C FF 04 BC : Reset RC to top of display85: 30 2C : Goto NEW LINE

line r rrrovein RF .0

LTNE

EXIT

Upon returning from the subroutine I=I+(2+NB*NL)+1.With DXYN f=I

0387: FB FF A6BA: 9F 56BC2 L2BD: 00 D4

I R6 points to VF: Store Flag in VF,: Increment stacki Idle; Return

There are no limit.ationsNB is larger than 0B orwill write over itself.

on the values for NB

if NL is longer thanor NL. However, if

the display the object

The routine will work wit.h Ben Hutchinson's( vrPER vr r , p9 7 ) with the f ollowing changes ,

with a NoP ( E2 ) r have at 031 3 .

0 30e z gei_ 0 35E 19; _937 6_1 0 ;The four pages ofto start at 0C00.

1ZBH by 64v circuitwhich are facifitated

memory asslgned to the Al-splay a7e assumed

To change to a new page address (pCa), replacez.oB/09.U6

Page 47: SHiffi::ii::. . .z.o'/os.u3

0C with PGA at 0326. Inaddition, for the y wrap around to workit is necessary to chanqe the value at 0378 to pcA+04.

Extended Display SubroutineOptions-Comments

Calling sequence and data format options: '(1) Fx and Fy can reside in the data setrpreceeding NBNL,

by changing 45 to 4A at 0301 and 030E.(2) NB and NL can follow FxFy in the program by changing

4A to 45 at 0328 and 032A.(3) There is room to set Fx to a fixed vaLue in the subroutine.

0301: F8 Fx A6 06 FA 07 BE 46 FA 3F F6 F6 F6 52'82(nop).The variable VY must then be the next CHIP-8 variable afterVX (VO and V1 for exampl-e) .

This routine will work with the original CHIP-8 1 page displayor the 2 page display if the value at 037E is changed to PGA+01

or PGA+O2 respectively, where PGA=the top paqe of displgy memory._*There are times when it is desireable to superimpose the data blockon top of what is al-ready present without erasing anything. To do

this change F3,XOR, to FlrOR, at locations 034F and 036D. It isinteresting to experiment wittr the other logical and arithmeticoperations at these locations.A more useful option is to simpl-y write the object over whatis already on the screen. This is illustrated in the accompanyingexampJ-es. To impJ-ement this option put a NOP instruction such as

5c or EC at locations O34F and 036D. NB is l-imited to 07 with this option.The IDLE command 00 located at 03BD stops aLl action until aninterupt is called and hence can slow down a program. It can bergpltced yith a relufn D4.

When the 4 page interrupt such as Tom Swan described in VIPER(2,06.O4)is used ttre program will continue while the display acLion is occuring.It is possible that the program will ctrange the disptay memory beforeit gets displayed, usually toward the bottom of the scre€rr. This may

cause funny things to happen such as odd blanks appearing, especiallywith the IDLE removed. Sometimes this can be cured by synchronizingthe program to the interrupt with judiciously placed IDLE caLl-s. Thisj-s done with a machine language routine consisting solely of OO D4

t.hat i s called brr the CHIP- B prosram .

2 , OB/O9 .4?

Page 48: SHiffi::ii::. . .z.o'/os.u3

rf the number of bytes in the data block is more than about 16 thenmotion becomes jumpy because each byte must be shifted over 7 times :when the lower 3 bits of vX-are Ll-L and not at all when VX ends in 000. '

Extended Display Subroutine( Examples )

These sample programs use Tom Swanrs HI-RES bHIP-B routines(VIPER 2.06,04) and will run with 2K of memory. They use theoption that V0 and Vl are the coordinates r so be sure to make

that change before entering the programs. The first writes and

erases the object with the standard XOR option. The seconddemonstrates the smoother flicker free motion obtained usingthe overwrite option. The object is one of the many interestingones I have found that can be made with the bar shaped dot.

0244: 6010 6110 A2B0 0300 6E00 7EA2 EEA1 125A 4E0A l24c L24E025A: A280 0300 4EO2 71-FF 4EO4 70FF 4EO6 7001 4E0B 7101 l24B

Data describing object (2 bytes wide-14(Hex) lines high)0280 z 02 14 00 00 03 00 0F 00

BB: 1E 0o 3c oo 7c 0o 7F Fo Move the object around

9o: 7F F0 7F 0o 7F oo 7F FB using kevs 2-4-6-8 '

98: 7F FB 7F 00 7F 00 7F FOA0: 7F F0 7F 00 l_F 00 0F E0AB: O0 00

To change this program to ttre overwrite mode first put. EC at 034Fand 036D, then change the jump aL 0252 from 125A to l25E so itskips the erase commands ttrat are no longer required. Note that theobject has rr0' bits surrounding it on all sides and it is onlyallowed to move by increments of 1so that no rtlrr bits of theprevious frame escape being erased

Chicken Crossing the Road Routine:Leave the extended display subroutine in the over write mode

and try the fol-lowing animated sequence that uses the feature thatthe I pointer is not reset after calling the subroutine.

0244: 6303 6000 6169 A2B0 0300 6160 60FF 6205 A2BA 03000258: F315 F4O7 34OO 125A 7001 -72FF 3200 1256 L252

Data:O2BO z Q7 01 FF FF FF FF FF FF FF FF ..road02BA: 01 09 06 7D 3E 1C OB 18 24 42 63 ...Frame #10295: O1 09 06 7D 3E 1c 0B 0B L4 24 36 ..+202A0: 01 09 06 7D 3E Lc 0B 08 OB 0B 0c ..#302AB:01 09 06 7D 3E lc 08 0B 18 L8 lc .,#40286: 01 09 06 7D 3E lC 0B 0B L4 24 36 ..#5 same as #2

VariabLe V3 set at 0244 determines the speed of the action.

2 ,OB/O9 .48

Page 49: SHiffi::ii::. . .z.o'/os.u3

SCRT JTIMP TABI,E

by Leo Fo Hood

In the PIPS FOR VIPS, I noticed that use is mad.e of the Stand,ardCalI and Return subroutines. Below is a short progr€rm that whenused with the SCRT allows subroutines to be accissdd with a tablelgg!:tp. This iump routine is useful to me in implementingadditions to my disassembler progrerm, The routine fakes tf,ereturn address in Register 5 and jumps to the desired routinethrough the nornal subroutine return program. The originalcalling locatj-on is of course saved on tne stack prior-to the jump.The pertinent cod.e for calling the JITMP prograrn i-s included, butnot the actual table since thtt is depen-itenI on the applicaiion.

27Co 96c1 73c2 86ca 73c4 48c5 52c6 90c? 14c8 86c9 ll8CA A5cB D5

JUMP SUBROUTIIVE

JUMP r cHr R5STXDGLO R5STXDI,DA RBSTR R2GHT ROADDPHT R5tDA R8PTO R5SEP R5

272223252628'292A282C

*** 2E3L3z3t+35373839383c3E

2741

***2730

GHIADIPHITDIPI,0

I{EXT r GtOSTRtDNXRIBZSDF7,-

Gt0ADIPI,0GHIADCIPHIBR

JilIP ! SEPIIBR

EXAMPTE

RO

#arR8#50RBRBR2R8#zr#oo

#nRB#ozR8R8#ooRB#zg#o? co#al

R8

90FCB8F8AB8B5208FB32F53288FCA8987CB83oD430

o7

5o

7FDO

3E

,02

00

2go7o3

t R0 c ontains addres st of relocatable coderRB used for indexr to table

tRB used for temporary storaget of command code

i7F is end of tabl er D0 is location of Error routine; Compare command eode tor table entry branch if equalt If eommand not foundr jump to: llext entry

', '!

t"n,tttr

; CalI JTIMP

tWhen routine has finished r returnwill be to this location whichbranehes to beginning of thero_utine .which is not showrr.

; (Soruyl )2,OB/09,49

4B

c0

tDA

Page 50: SHiffi::ii::. . .z.o'/os.u3

NON-COMMERCIAI ADVERTISING

FOR SAIE3 Keyboard, Rad.io Shack 2??-L17 with I/O boara andconnectors for VIP. F. H. Bremer, L75 W Albanus Street,Philadelphia, PA 19t2o (Zt5) 455-6576

FOR SAI,Ez VP-550 Super Sound Board with manuaL and cassette.lnlorks fj-ne, but it isn't what I thought j-t was. . $40.00Jerry Krizek (?Lj) 338-2696 after J:00 PI\4 California time

FOR SAIE: VIP, VP-590 (Color) and VP-550 (Supersound). A11the manuals, Volumes 7-, 2, and 3 of PIPS FOR VIPSr and approx-inatel-y 25 game tapes. $400. I got an APPIEI Bob Brock,(301) 730-0922 before 9100 PM Eastern Time.

* NOTE: We will print smaLl "want ads" such as these for.free, but they rnust be strictly non-eonmercial. They arefor your information orrly, and we can't vouch for theiraccuracy or legitirnacy. The ad.vertisers listed here areVIPffi subscri-bers.

*ATTENTION*

ARESCO is attempti-ng to get out of the hardware retail- business,so wetre selling our stock of VIP products. Here's an inven-tory of the material- we have on hand, along with the priceswe're asking for each piece. Theycll be sold on a fi-rst-come,first served basisr so you might want to caII in your ord.erwith a Master Charge or VISA number. NOW! RCA

VP-?LL COSMAC VIP Microcomputers $tzg 199B0 gg22 VP-111 Microcomputers.. Same as VIPr but user

must install I/O ports' system expan-sion capability' and 5v power supply. '

27 303 VP-595 Simple Sound Board.2 vp-3510 Sup-er Sound. Board s 44 49t vp-S?o Mehory Expansion Board Z6 952 VP-585 Keyboard. Interface Card. for hex keyboard +3 L5t vP-SZS Exiansion Board 49 593 vP-5?6 Two-Board Expand.er L7 202 vp-SeS EPROM Programmer Board 80 995 vP-620 Cable: ASCII Keyboards to VP-71I L7 ?o5 vP-?Oo Tiny BASIC ROM Board 35 39.In addition, we have about 50 sets of Volume t of the VIPERTwhj-ch we can sell for our absolute printing & postage cost of$12.00, and a few VIP manuals.. r........We have a few looseback issues from Volume I VIPER, so if youtre missing an i-ssue,give us a ca1l. Our cost per issue i-s $1 .20.

ARESCO will not be publishing a vol-ume 3 VIPER, due.to circum-stances we cannot control-. If there is anyone out there whowoul-d like to take over the effort, 1et us know about Your andwerll let you know who the past subscribers 3.r€. Our tharrksto all- of you for your support! See you in May! - Terry

2.OB/O9 .50

Page 51: SHiffi::ii::. . .z.o'/os.u3

KE]BOARD RESET

by Steve Medwin

I've made a siurple modification to the RCA ASCII keyboard thatturns the "User #1" key into a reset key" This al1ows you toreset the VIP without flipping the run/reset switch"All you need, is one resj.storr art edge-card board for theexpassion interface a;1d some wire. A schematic follows.

user 7 eontaetson keyboard

+5v

EXPANSION INTERFACE

To use r The reset/run switch must be left in run. Then toreset the VIP, just press artd release the User #1 key.

TINY BASIC DISCONIYECT SWITCH

by Randy Holt

When the Tiny BASIC board is inserted into the VIP ExpansionInterface connector, it doesn't permit the VIP to execute CHIP-8or machine larrguage prograrns. I disliked always taking the boardout to run other progransr so I made the modifications describedbeJow. The double-throw, double-pole switch will operate inBASIC in one position and will permit CHIP-8 and. machine languageroutines'in the other position. Change the positi-on of theswitch onlv when the VIP is in the RESET mode.

0n component side of board, cut track between CD4515 pin 10 andthe diode, and between connector pin X (8ooO) and CDP1833 pLn 2tas shown on the diagram. Solder wires as shown to the DPDT switchusing plated-through holes wherever possible. I affixed theswitch to the upper-right corner of the Tiny BASIC board.

I{-l

-RUN

MVIP

2 ,OB/09 ,5L

Page 52: SHiffi::ii::. . .z.o'/os.u3

TINY BASIC DISCONNECT SWITCH( continued )

(oeorspr"cH)omAcll

BAsrs

OAACH

afi rtlcF ,'IEPE

EXPANDED ROM MONITOR

by Randy Holt

Wouldnrt it be nice if you could replace the stZlAyte VIP ROMMonitor chip with a 2048-byte EPROM that would then p.ermitextra ROM space fof a more sophisticated monitor and/or beused to store some of your favorite subroutines? It turns outthat with just J cut tiacks and the addition of ll wires to theVIP board, you can have this capabilitylThe VIP ROM Monitor chip wilt stiLl operate in the U1O socket;and when a 2715 EPROM is installed, it will exist in the stand-by(tow power) mode unless it's addressed" The VIP EPROM Programmercard can be used to prograrn the 2?t6.

IAdld)

carTSACf,.HSI'

r1

2,OB/09,52

Page 53: SHiffi::ii::. . .z.o'/os.u3

conponent slde

tracks

rL

uto

RevlsedSehenatle I

EXPAIIDED ROI{' }IONITOR

here

solder s lde

na0nAl,,,A2vlIt^A+,tA6naONA?A'Ato43+{ry

sldc, cut traeks

eut the track

wlres as follows I

fron +5VDC to U10-18

fron U10-12(CND) to

(

^e)(A10)

togetherother

+I2t

t2a

tbtstlr, "::3

2.OB/09 .53