Daily Apple

Vintage Mac Blog

Yesterday I started up a new blog over on MacGui, the Vintage Mac Blog.

I’ll be using it for my Macintosh writings keeping the Daily Apple for the Apple II.  I have a project or two for my Vintage Macs that I’ll be working on in addition to my Apple II projects.  I’ve posted a link to it in the links.

 

Posted in Macintosh, Projects Tagged with: ,

Basic Games, Disk Image

In the past whenever I needed a directory added to a disk I just booted up the utilities and created one.  I knew there was a way to do it under ProDos, but never bothered to look it up.

While I was setting up the disk image for Basic Games I needed s couple of subdirectories.  I figured it was time to look it up, so out comes my copy of The New Apple II User’s Guide.  Two minutes later I had my answer.  CREATE.  I created my two subdirectories, loaded and saved animal into the correct directory and uploaded the disk image, so I could link to it on this page.

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

Murphy’s Law, Challange Accepted

As you can see I challenged Murphy’s Law by saying I was back at it.  Challenge Accepted, I lost.  Eighteen days without a post.

I haven’t had a minute to even turn on my Apple II in the last two plus weeks.  I have managed to check in on the message boards.  The idea of using the unidisk processors to multi-process is very clever.  An update to ADTPro is never a bad thing and all the developments around using the Raspberry Pi with the Apple II is kind of exciting.

In continuing with the games from the Big Games Book, I’m going to keep a posted disk image up to date.  I created a bootable ProDos diskette with two directories BOOK and MODIFIED.  The BOOK directory will be used to store copies of the games that are closest to the book version.  Any changes beyond that will be stored in the MODIFIED directory.  As of now I haven’t made any changes to animal to warrant the MODIFIED directory.

 

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

Animal, Observations

I have couple of observations about the animal program.  It is fairly short, about 70 lines.

It was designed to be used with the caps lock on (or only upper case input).  To clean up this version I will need to either change the lines I converted to upper and lower case back to all upper case or modify the program to work with upper and lower case input.

Another thing I noticed is the first question expects one of three answers: yes, no or list.  The program handles yes and list but nothing is done with the no answer.  The no answer is for the end game.

The coding is pretty straight forward, but they use a creative binary tree to store the data, which in this case is the animal questions and answers.

The version I played in high school had a much larger group of animals stored in it and I believe they were stored on disk.

 

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

Hour of Code

The set of examples I went through was the tutorial for beginners.

In it you write code by placing program blocks in the proper order.  As you go through each example the different programming concepts are explained and you get to try them out.  When the example is done, you can click on a link and it will show you the code in JavaScript you would generate with the code blocks.

I’ve never done any JavaScript before and this example was fun and educational.

Even if you choose not to try any of the learn to code section, I recommend checking out the web page “Hour of Code” which I have posted a link for.

 

Posted in Posts, Programming Tagged with:

Grace Hopper

Today’s Google doodle reminds us about Grace Hopper’s birthday, she would have been 107.

She was not directly involved with the Apple II, but was very important to computers in general.

Below the search is a link for a video about an Hour of Code.  The video introduces an initiative called an “Hour of Code” which is to promote computer science for Computer Science Education Week (December 9-15).

I went to the web site and went through one of their hour of coding examples.  It was kind of fun.

 

 

 

Posted in Posts

Animal Debugged

I finished debugging to the book.

It was asking the “Is it a ” question, but displaying the question for the animal instead of the animal name.  It took a while before I found the problem.

In line 190, I used the variable a$ rather than the subscripted variable a$(k).  Once I found and fixed that it works just like the book showed.

 

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

Games Past, Animal, Entry and Debugging

I finished typing Animal in today.  When I was typing it in the only changes I made were to the text that was displayed.  I changed it from all upper case to upper and lower case.  The second half of the code was the most complicated with multiple parenthesis, quotes, double quotes and slashes.

Then it was time to start debugging.  My first priority it to debug the program to the book.  By that, I want to make it run like the copy in the book does, with little or no modifications.

The first thing I noticed was there were no question marks after questions.  Some versions of BASIC display a question mark for every input statement.  Others, like AppleSoft only display the question mark if there is no prompt included in the statement.

I fixed the first question (prompt) at line 130 to include a question mark.

This first question (Are you thinking of an animal ?) has three answers: yes, no and list. Yes starts the guessing part of the game and list gives a list of the animals the program knows.  If the answer is not LIST or Yes you are asked (Are you thinking of an animal?) all over again.

I tried to list.  The program starts of only knowing two animals Fish and Bird. Of course the first time through it just listed the first letter of each animal. I looked at the section of code that handles this list (600-680) and found that line 640 handles printing the actual items in the list.  The last part of the line looks like NEXT I, but by changing it to NEXT Z makes it print the whole animal name.    This time around it prints FishBird.  Double checking the code show nothing obvious, so we’ll come back to it later.

When playing the game the next question that comes up without a question mark is (The animal you were thinking of was a) is at line 240, so I went in and changed the prompt to include the question mark.

That was all I had time for today.

 

 

 

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

Games Past, Animal

I’ve decided to try to recover some of the games from my past.  These games were written in basic and I’ll be using AppleSoft.

David Ahl’s Basic Computer Games was published in several different editions.  The first I saw was the Digital Equipment Corporation Edition.  You can find scans of these books at the link for Basic Computer Games.

Many of the games from this book were on the PDP 11/70 that I first learned on.  The ones I have the strongest memories of were Animal, Hammurabi, Lunar LEM Rocket, Stock Market, Super Star Trek and Tower.

Tonight I started typing in Animal and got about half the listing entered.  The nice thing about this book is the programs are written in a pretty generic version of BASIC so they should require little or no conversion in order to run.

Tomorrow I’ll finish the listing and test it out.

 

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

LambChops on the Apple //c

I moved Lampchops to my Apple //c today.

When I tried to boot the first diskette I got scattered characters over the screen.  I tried to reboot it and got the same results.

I went back to ADTPro and moved another copy to a different diskette and when I tried to boot it, it showed Apple //c and sat there.

I was starting wonder if my drive was off, but tried to copy it to a diskette I have used recently.  When I booted it up, the computer actually did something.  It quickly booted up to PREPARING LAMB CHOPS… and then there was disk activity which is much more apparent on an actual Apple //c (lights and noise) as opposed to AppleWin which just shows on a tiny green dot.  There is something kind of reassuring about the noise of the disk drive when waiting for a program to load.  You know something is going on while you wait.

The game play is much more enjoyable on the real Apple //c with a color screen.

Posted in Apple //c, Games Tagged with: ,