Memory Game is card game in which multiple cards are laid face down. The player should flip two of the cards face up on each turn. This game can be played with one or more players. The objective is turn over pairs of matching cards. If non-matching cards were turn face up, then both cards will be flipped face down again. If the two pairs were matching, then the cards will be kept face up and the player will gain a point that will be added to their respective score. Rules of these games may vary from a version to another. They can also have more complex scoring rules.
In our project we will design a small memory game of three different versions. Each version will have its own set of rules, all of which are defined in the appended project specification.
Our task is to implement a simplified version of the memory game on a PIC16F84A micro-controller using the MPLab assembly language. The project should conform to the entirety of its description without any compile or runtime errors.
The personal challenge was to develop the project using as few lines of code as possible. Accordingly, the entire project was implemented using only 442 compiled lines of code, subject to improvement on the long run.