HEART 2014 Design Contest: Rules
1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | a | b | c | d | e | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1 | ||||||||||||||
2 | ||||||||||||||
3 | ||||||||||||||
4 | ||||||||||||||
5 | S | |||||||||||||
6 | ||||||||||||||
7 | ||||||||||||||
8 | ||||||||||||||
9 | ||||||||||||||
a | S | |||||||||||||
b | ||||||||||||||
c | ||||||||||||||
d | ||||||||||||||
e |
|
Allowed | Prohibited | ||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
o | o | ||||||||||||||||
o | o | o | o | ||||||||||||||
o | h | h | o | h | h | ||||||||||||
k | o | h | h | k | o | h | h | ||||||||||
k | s | k | s | ||||||||||||||
k | s | s | s | k | s | s | s | ||||||||||
k | k | s | k | k | s |
Rules of Blokus Duo
Board
Blokus Duo is played on a 14x14 board, as shown in Fig.1.
Tiles
Each player has 21 different-shaped tiles (Fig.3). Any rotations of tiles are allowed as Fig.4.
Move Restrictions
- Basic rule:
- To start, both players have a set of 21 tiles above. Tiles has color to identify the player (i.e., player A has green tiles and player B has red tiles.) Each player places one tile at one time.
- First move:
- Players must cover one of the cell marked "S" in Fig.1, at (5,5) or(a,a) on their first move.
- Corner-to-corner contact:
- Newly placed tile must have at least one corner-to-corner contact with a tile of the same color. Additionally, newly placed tile must NOT have edge-to-edge contact with any tile of the same color. With any tile of different color, edge-to-edge contact is allowed. For example, The right-hand-side situation in Fig.2 violates this rule between "k" tile and "o" tile in red.
Scores
Game continues until both pass, one player plays all tiles, or one player makes an invalid move. Then the players' scores are calculated.
- Basic score is negative, given by (0 - total # squares of unplaced tiles).
- If a player played all 21 tiles, the player gets a bonus score of +15 (the bonus is +20 if the last tile is 'a' monomino).
- An invalid move results in immediate loss of game.
Monomino: | Domino: | Trominoes: | Tetrominodes: | |||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
a: | b: | c: | d: | e: | f: | g: | h: | i: | ||||||||||||||||||||||||||||||||||||||||||
Pentominoes: | ||||||||||||||||||||||||||||||||||||||||||||||||||
j: | k: | l: | m: | n: | o: | p: | q: | r: | s: | t: | u: | |||||||||||||||||||||||||||||||||||||||
0: | 1: | 2: | 3: | 4: | 5: | 6: | 7: | |||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Communication Protocol
1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | a | b | c | d | e | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1 | ||||||||||||||
2 | ||||||||||||||
3 | ||||||||||||||
4 | ||||||||||||||
5 | ||||||||||||||
6 | ||||||||||||||
7 | ||||||||||||||
8 | ||||||||||||||
9 | ||||||||||||||
a | ||||||||||||||
b | ||||||||||||||
c | ||||||||||||||
d | ||||||||||||||
e |
|
FPGA boards must equip RS-232C (D-Sub 9pin) interface to communicate the host PC. The boards send their team ID (to start the match), their move in each turn, and receives the opponent's move in each turn via RS-232C link.
The details of the communication protocol will be available later.
The four-letter code
The FPT2013 Competition Blokus Duo protocol will use a simple four-letter code to represent a move, between the FPGA boards and host PC.
The four-letter code represents [X, Y, Tile type code, Tile rotation pattern]. The "X and Y coordinate" is written in 1-9 and a-e (lower-case) as in Fig.1 and 5, to point the "center" of a tile to be placed, filled in gray in Fig.3. "Tile type code" indicates the player's tile in Fig.2, in a lower-case alphabet. The last letter stands for the tile's orientation, as in Fig.4.
Fig.5 is an example of the four-letter code "a4t3" alone on the board.
"0000" is a special four-letter code that means "pass."
Communication Protocol (Preliminary: version 0.0, Jan.10, 2014)
Important Note: This protocol is preliminary, still subject to change.
RS-232C link is driven at 115200 bps, no parity and 1 stop bit. All communications are done in ASCII characters, case sensitive.
- Initialization:
- Host sends "0" to both boards. FPGA boards should response "1XX" (XX is the pre-assigned team code) in 1 sec.
- First player starts:
- Host sends "25" or "2A" to the first player. "25" means that the first move must cover (5,5) and "2A" is about (a,a). The FPGA board must send the four-letter code in 1 sec.
- Second player starts:
- Host sends "35XXXX" or "3AXXXX" to request the second player's first move. The move must cover (5,5) for "35XXXX" and (a,a) for "3AXXXX". "XXXX" is the opponent's first move. The FPGA board must send the four-letter code in 1 sec.
- Move:
- Host sends "4XXXX" (XXXX is opponent's move in the four-letter code.) The FPGA board must send the four-letter code in 1 sec.
- Pass:
- If no possible move found within 1 sec after receiving "3XXXX", the FPGA board must send "0000" instead of a valid four-letter code. Exceeding 1 sec limit results in immediate loss of game.
- Termination:
- Host will send "9" at the end of a game. Code
"0" follows if next match is scheduled.
- Player can do a hard reset of the FPGA at this point, if declared to referee before the match starts.
The protocol / codes above are summarized in table 1.
Code | Sent by | Description | Response Code |
---|---|---|---|
0 | Host | Code 0 initiates the match. | Code 1 |
1XX | Board | Response to code 0. XX: team code. | none |
2X | Host | First move request for first player. X: "5" to the player who covers (5,5) and "A" for (a,a). | Four-letter code |
3XYYYY | Host | First move request for second player. X: "5" to the player who covers (5,5) and "A" for (a,a). YYYY: Opponent's move. | Four-letter code |
4XXXX | Host | Move request. XXXX: Opponent's move. | Four-letter code |
9 | Host | Termination. Code "0" may follows to this code. | none |
Example of Board-Host-Board Communication
An example of the message sequences and resulting board situation are given and illustrated in Table 2 and Fig.6. The team code of board 1 and 2 are "AA" and "BB", respectively. The first player is board 1.
1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | a | b | c | d | e | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1 | 1 | 1 | 1 | 1 | 1 | 2 | 2 | |||||||
2 | 1 | 1 | 2 | |||||||||||
3 | 1 | 2 | ||||||||||||
4 | 1 | 2 | ||||||||||||
5 | 1 | 2 | ||||||||||||
6 | 2 | |||||||||||||
7 | 2 | |||||||||||||
8 | 2 | |||||||||||||
9 | 2 | |||||||||||||
a | 2 | |||||||||||||
b | ||||||||||||||
c | ||||||||||||||
d | ||||||||||||||
e |
|
Seq # | From: Host To: Board 1 | From: Board 1 To: Host | From: Host To: Board 2 | From: Board 2 To: Host |
---|---|---|---|---|
1 | 0 | 0 | ||
2 | 1AA | 1BB | ||
3 | 25 | |||
4 | 53e0 | |||
5 | 3A53e0 | |||
6 | a8e0 | |||
7 | 4a8e0 | |||
8 | 21k7 | |||
9 | 421k7 | |||
10 | 94j0 | |||
11 | 494j0 | |||
12 | 61a0 | |||
13 | 461a0 | |||
14 | 71b3 | |||
15 | 471b3 | |||
(game continues) |
If you find any problem in the protocol, please contact osana at eee.u-ryukyu.ac.jp .