Electronic Boardgame

I am trying to make a 2-Dimensional, tile based, electronic board game. I want a microcontroller to know where the users pieces are on the board. I am very new to electronic projects and know only the programming side. So this is my project to learn and I want to make A LOT of mistakes.

I feel the easiest and safest solution would be to use connection pins on the bottom of board game pieces to complete a circuit in a key matrix. The board will have a hole in each tile where the connection pin will go through. The below URL shows how its done for keyboards and shows the solution for the “ghosting problem” when simultaneous keystrokes are performed. This probably can be adapted for my usage.

http://pcbheaven.com/wikipages/How_Key_Matrices_Works/

Note: The board game requires this technology and will give feedback to the user via speaker after some basic AI is done on the microcontroller.

What are your thoughts on 12x12 - 16x16 grid? Is it too expensive? Alternative solutions? Problems? Safety concerns? Not enough pins on the microcontroller solution? Any feedback is appreciated.

Thanks,

Please elaborate on any terminology or referenc es that you may find that is helpful.

masterspin:
Problems?

Maybe. Are all the tiles to be placed on the board identical ? That is ... the game only needs to sense that a grid position is occupied and not also occupied by a specific tile ?

I think I understand your question. The microcontroller needs to know which tiles are occupied by a user. Only one user can occupy a specific tile at a time.

Note that tile and grid-position are interchangeable terminology I may have been using.

So, to restate differently. I want my microcontroller to know which grid positions are occupied.

masterspin:
So, to restate differently. I want my microcontroller to know which grid positions are occupied.

OK, let me restate my [u]potential[/u] for a concern. I imagine a game where players place pieces onto your grid. Does the micro have to know what pieces, as in Checkers where there are red and black pieces, occupy what grid positions ? Now in a simple N player game where each player always places just 1 piece onto the grid and it's always strictly in turn ... then your scheme should work. For Checkers it'll always be red then black then red then ... so the "value" of a piece (red/black) on every grid position can be known from the order of plays.

But if the pieces have varying values (think some odd form of Chess or perhaps Dominos) or if it’s not always 1 piece per turn per person, then the micro has to be able to determine grid position and piece “value”. Then you need more than your matrix scheme.

So w/o knowing the games you might play, I can’t say if your concept is sound, or not.

As for running out of pins … one easy way to expand the numbers of inputs is via shift registers.

https://learn.sparkfun.com/tutorials/shift-registers

Ok, now I understand your question. There is only one type of piece on the board. The game is also turn based like Monopoly. I imagine when all turns are over for all users, a button will be pushed to indicate to the microcontroller to perform its AI functions and to analyze the grid positions. The microcontroller does not care which piece belongs to what user.

Awesome! Shift registers sounds just like the thing I need. Now that I know shift registers exists, why do I need this matrix scheme? I could use one pin as output on a microcontroller connecting to chained shift registers. Then have each grid position (input) connected to it’s own position on a shift register. Each output on a grid position can then connect to one input pin on the microcontroller.

There would be more wires but I think I would save because I don’t need to get a diode for each grid position to prevent ghosting like in the matrix scheme. Maybe they have smaller thinner wires too…

What do you think? ***

Thanks for your quick response!