Casio CFX 9800G Emulator

You can run the emulator here.

pR-palm rendered on my trusty old CFX 9800G

At school, I had a Casio CFX 9800G colour graphing calculator. It had a simple programming language and I used to while away some more boring lessons by writing games and drawing pictures. This was back in around 1998.

I kept the calculator. From time to time, I would find it in a drawer and look over my old programs. The battery-backed memory had lasted more than ten years on standby, but I realised that it wouldn't last forever, and that made me sad. In a fit of nostalgia, I resolved to copy the programs onto a PC, where they could live forever.

Now I just needed a way to run them. Casio have released an official emulator for the "fx-9800G USB" (you can download it here), but that's a slightly different machine. Although it's a more advanced model, with a slightly better programming language and more functions, it's only black and white; the screen is also slightly larger. So none of my old programs ran correctly on the emulator.

I searched for quite a while for an emulator for the colour calculator, but in the end I gave up and wrote my own. Here it is.

If you want to read the source code, or read more of the technical details, then visit the GitHub repos for this project.

(I also patched the old programs so that they run OK on the black-and-white emulator, corrected for the different screen width. The details are on GitHub, if you're interested.)

The Programs

The programs I still had stored on the calculator are:

p0-poisson.txt

Calculates probabilities in the Poisson distribution, and keeps a running total. An uncharacteristically legitimate mathematical program.

p1-powerseqs.txt

Solves for the coefficients of cubic or quadratic sequences, given the first few terms.

p6-mandl2.txt

p6-mandl2 A rendering of the Mandlebrot set

p7-bse.txt

This is a (somewhat dark) simulator where you play a cow culling business during the BSE cull days.

p8-master.txt

This is my re-imagining of a game I used to play on the BBC Micro. (It's much worse than the original!) You are in charge of a village and have to decide how much rice to plant v.s. eat each year.

p9-casino.txt

A slot machine simulator. The payouts are fairly generous, so it's easy to become a millionaire (with patience).

pC-dice.txt

This is an implementation of a dice betting game I saw in a computer game on the Acorn. It was a medieval themed game; I don't know if this is a traditional dice game, or was made up for that computer game.

pD-mastermind.txt

This is an implementation of the Mastermind guessing game. The computer will think of 4 numbers 0-9, and you have to guess by entering a four digit number. The computer will answer with the number of "hits" (exact matches by digit) and "halves" (the right digit in the wrong column).

pE-cccp.txt

A rendering of the USSR flag.

pF-fibbonachi.txt

Generates the fibbonachi sequence.

pK-island.txt

pK-island A pretty picture.

pM-banner.txt

The Nazi flag.

pN-union-jack.txt

The UK flag.

pO-tricolore.txt

The French flag.

pP-swiss.txt

The Swiss flag.

pQ-poly-area.txt

Computes the area of a regular polygon.

pRho-star.txt

Draws a star.

pR-palm.txt

A pretty picture.

pV-fireworks.txt

An animation of fireworks.