This project implements a one-player Blackjack card game on the mbed microcontroller using the uLCD-144-G2 128 by 128 Smart Color LCD display board with a serial interface and 8 Parallax pushbuttons. The LCD display board shows the values of the cards that are dealt to the player (the user) and the dealer (the computer), and it shows the bet value that player selected. The LCD screen also prompts the player to continue playing if the player lost the round to the dealer. The player can also the follow the game, such as the money pot size, the player's hand, the dealer's hand, and directions for the player to follow, on a PC prompt screen. This project specifically uses Tera Term to show the player.
The 8 pushbuttons serve different purposes using the rules of Blackjack. 4 pushbuttons allow the player to select 4 different bet values: $0, $25, $100, and All in. 2 pushbuttons are used to hit, meaning to ask for another card, and stand, meaning to let the dealer play out after the player is satisfied with the player's cards. The last 2 pushbuttons represent yes, meaning to continue playing the game, and no, meaning that the player decides to walk away from the table (finish playing the game).
uLCD color display board
|MBED||uLCD Header||uLCD Cable|
|5V = VU||5V||5V|
|TX = P28||RX||TX|
|RX = P27||TX||RX|
First pin of the pushbuttons are connected to Digital In
Second pin of the pushbuttons are connected to ground
Internal pullup implemented in the code
Made by George and Pahul
1 comment on Blackjack:
Please log in to post comments.
Do you have a SD Card inserted on top of the LCD?