Difference between revisions of "F18: Catch me if you can"
Proj user11 (talk | contribs) (→Design & Implementation) |
Proj user11 (talk | contribs) (→Wireless Module) |
||
Line 285: | Line 285: | ||
[[File:CmpE244_S18_Detectable_Accelerations.png|400px|thumb|center|Accelerometer Detection]] | [[File:CmpE244_S18_Detectable_Accelerations.png|400px|thumb|center|Accelerometer Detection]] | ||
− | ==== Wireless Module ==== | + | ==== Wireless Module: ==== |
[[File:nordic.PNG|350px|thumb|center|'''Nordic Wireless Block Diagram''']] | [[File:nordic.PNG|350px|thumb|center|'''Nordic Wireless Block Diagram''']] | ||
Revision as of 01:05, 16 December 2018
Contents
Grading Criteria
- How well is Software & Hardware Design described?
- How well can this report be used to reproduce this project?
- Code Quality
- Overall Report Quality:
- Software Block Diagrams
- Hardware Block Diagrams
- Schematic Quality
- Quality of technical challenges and solutions adopted.
Project Title
Catch Me If You Can
Abstract
"Catch me if you can" is a fun game where the user must be attentive and agile enough to catch the randomly dropping eggs from above into a basket. This is all displayed in the LED matrix acting as the screen. The user shall gain and accumulate points equivalent to the eggs collected successfully and there shall be a limited score for each level. The system will consist of two SJ boards, the one board will be used as a game console with which user will try to catch the eggs by moving the board in the required orientation. The other board will control the display module that displays the graphics of eggs falling and also the basket movement. The display module shall communicate with the game console via RF Nordic transceiver. There will be various sounds produced by the display module board for various events during the game like an egg catch\miss or an intermediate milestone reached.
Objectives & Introduction
Objective
Here, we develop an Embedded system in the form of a 2D game involving a Matrix LED display acting as the Human Machine Interface to guide the player along the way while playing the game. This project aims at integrating micro-controller peripheral drivers and the application software in a meaningful way, where the accelerometer data is sent out from a node via wireless Nordic transceiver to control slider movement on the other node to control the game according to player's performance.
Introduction
The Project consists of three main modules:
Control Module: It consists of accelerometer on SJ one board. Calibrated board orientation is sent to the Display Module via Wireless Module.
Display Module: It is responsible for controlling 32*32 LED Matrix and Piezo buzzer interfaced to SJ One Board.
Wireless Module: It is used to establish communication between Display and Control module.
About the game
- Player should collect the eggs into the basket which are shot from the canon.
- Press switch on the console (SJOne board) to start the game.
- Tilt the console left or right to move the basket.
- Collect the eggs.
- Avoid red objects, if caught Game Over, else continue to collect eggs till the end of level.
Team Members & Responsibilities
- Aquib Abduljabbar Mulani
- Wireless chip TX driver/application and calibrating accelerometer.
- Kailash Kumar Chakravarty
- RGB LED 32x32 matrix driver and game application code.
- Nandini Mandya Shankaraiah
- Audio output and Wireless chip RX driver/application.
- Rishabh Sheth
- PCB design.
- Swanand Sapre
- Console application code and Game level design and application code.
Schedule
Week# | Date | Task | Status | Actual Completion Date |
---|---|---|---|---|
1 | 10/16/2018 |
|
Completed | 10/25/2018 |
2 | 10/30/2018 |
|
Completed | 11/05/2018 |
3 | 11/06/2018 |
|
Completed | 11/13/2018 |
4 | 11/13/2018 |
|
Completed | 11/16/2018 |
5 | 11/20/2018 |
|
Completed | 11/22/2018 |
6 | 11/27/2018 |
|
Completed | 12/1/2018 |
7 | 11/30/2018 |
|
||
8 | 12/04/2018 |
|
||
9 | 12/11/2018 |
|
Parts List & Cost
Sl No | Parts | Seller | Quantity | Price |
---|---|---|---|---|
1 | SJOne LPC1758 Microcontroller Board | Preetpal Kang | 2 | $160 |
2 | RGB LED Matrix Panel - 32x32 | Sparkfun | 1 | $55.6 |
3 | Piezo Buzzer | Amazon | 2 | $1.5 |
4 | Accelerometer | On board | 1 | NA |
5 | Switches | On board | 4 | NA |
6 | Portable Power Supply | Local seller | 1 | $5 |
7 | RF Nordic | On board | 1 | NA |
8 | BOM / PCB components | Sparkfun | - | $20 |
Design & Implementation
Hardware Design
Discuss your hardware design here. Show detailed schematics, and the interface here.
PCB Design
KiCAD 5.10.0 software was used for PCB design. We created two PCB's, one for LED display to connect display connector and piezo buzzers
The steps involved in the PCB design process are discussed below:
PCB Schematic Design
As a first step, we designed a circuit. We created parts which are missing in KiCAD library
Hardware Interface
Hardware design diagram above gives an overview of the entire system which consists of the two SJ-One controllers: one board is used as Control Module and other board is used as the Display Module.
- The Control Module uses the onboard accelerometer on SJ-One which is interfaced via I2C protocol. The calibrated accelerometer values are then used to determine the basket position on the LED Matrix.
- The Display Module SJ-One board is used to control a 32*32 RGB LED Matrix.This matrix displays the basket, eggs shot from the cannon.The movement of the basket is as per the orientation value received from the Control Module, through Wireless Module. It also consists of Peizo buzzer which is controlled via PWM pin.
Display Module
RGB LED Matrix:
The Human Machine Interface is a display which is composed of 1024 RGB LEDs arranged in a 32x32 matrix. Each RGB LED contains separate red, green, and blue LED chips within a single board. The screen is split horizontally into 2 equal halves each having 16 rows and 32 columns. The display's columns are driven by one set of drivers and the rows by another. To lit an LED, both its column and row driver needs to be turned on. To lit an LED with a particular color, the red, green, and blue chips in the column driver are controlled separately. The column driver devolves into 3 32-bit shift registers as well as 3 32-bit parallel data registers. On each rising edge of the shift clock, whatever data is present at the 6 data inputs gets shifted in. Once the shift registers are filled, the latch signal is asserted to latch these register contents into the parallel data output register.
Piezo Buzzer:
Piezo electric buzzer are high performance buzzer that employ piezoelectric elements and are designed for easy incorporation into various circuits. These buzzers are designed for external excitation, the same part can serve as both a musical tone oscillator and a buzzer. In our project we are using this device to create musical tones by varying the operating frequency.The different range of operating frequency are generated from PWM peripheral. Different range of frequencies are maintained as constants ,these constants are fed to PWM,which generates square wave. The output of the PWM is driving the Piezo buzzer.
Creating musical tones by varying frequency
int fire[]=
{
550,/*twice the freq of this and use always tempo as 40 */
404,
315,
494,
182,
260,
455,
387,
340
};
void fire_sound_level(void){
for(int i = 0;i < 8;i++)
{
uint8_t tempo = 40;
while(tempo)
{
pwm.SetFrequency(fire[i]*2);
pwm.SetDutyCycle(pwm.k2_1,50);
pwm.PwmEnableMode(true);
tempo--;
}
}
pwm.PwmEnableMode(false);
}
Control Module
Accelerometer:
In our project,we have calibrated the accelerometer based the values of X,Y and Z co-ordinates corresponding to different orientations of the accelerometer to control the horizontal movement of the Basket to catch the eggs on the screen. |