Memory games have become a big hit in recent years. They flood video games, phone applications, and even social networking sites. Studies have shown that by playing games that require a certain level of memory recall, people can actually improve their fluid intelligence (the ability to reason and solve new problems). This activity will help improve your memory by displaying a series of random LED colors through a Bi-Color LED. You will then have to repeat the pattern shown using pushbuttons. But be careful! In each round the colors will appear faster and faster, making it harder to remember.
Check out the video below for an overview before you start.
]
Getting Started
If you are new to the BASIC Stamp microcontroller or to programming, it would be a good idea to review the following before beginning:
- Complete the following chapters in What’s a Microcontroller? (#28123)
- Chapter 1 (Getting Started)
- Chapter 2 (Lights On – Lights Off)
- Chapter 3, Activities 2 & 3 (Pushbutton Control)
- Chapter 7, Activity 2 (Tracking Light Events)
- Review the following commands in the PBASIC Language Webhelp:
- BUTTON
- GOSUB
- RANDOM
- READ
- WRITE
Parts List
This activity can be completed solely with the parts included in the BASIC Stamp Activity Kit (#90005). Below is a listing of all parts required for this activity:
- (1) HomeWork Board with BASIC Stamp 2 (#28158)
- The BASIC Stamp 2 on a Board of Education (#28103) is also suitable for this activity
- (1) Bi-Color LED (#350-00005)
- (1) Green LED (#350-00001)
- (1) Red LED (#350-00006)
- (2) Pushbuttons (#400-00002)
- (4) 220 Ω resistors (#150-02210)
- (2) 470 Ω resistors (#150-04710)
Source Code
Source code for the Bi-Color LED Memory Game