top of page

Note: Please scroll down to see all of the projects below ↓

Retro Video Game

Objective of This Project

I've created a retro video game titled APOPHIS, a real-time arcade-style video game for my Digital Design Lab class. The main objective is to survive as long as possible from the incoming asteroid that is about to hit the earth (which is you). In this case, we are in control of the earth's defense system known as APOPHIS, a giant shield that can rotate 360 degrees around the earth to block the incoming asteroid and save the world from being destroyed.

SCRN0316.BMP

Utilizing Microcontroller & Oscilloscope Display

To make this game a reality, I will be using an LPC1769 LPCXpresso microcontroller: the essential part of creating this whole video game (coded in C using MCUXpressoIDE software). Considering that this is a dynamic motion video game (arcade-style), where everything is happening simultaneously, I will then be using an oscilloscope (X-Y mode) to be our main digital display. We can then utilize the idea of “vector graphics” to make our game more smooth and realistic throughout the gameplay.

Schematic.png

Controller & Sound Effects 

In addition, to control the whole movement of our shield in the video game, I will be using an analog joystick to be the main input. The game will also have sound effects to complement the overall gameplay, by having a square wave tone (using PWM) generated from a Piezoelectric speaker to accompany the player. However, this video game will not be completed without background music (theme song) that will keep playing throughout the whole game from a Piezoelectric speaker that will generate a song with at least 8 notes. To add challenge to the game (to make it more fun), the asteroid moving towards the earth along with the background music will also speed up as the game progresses.

IMG_3758_edited.jpg

Retro Video Game
Final Demo

This is the final gameplay demo of APOPHIS. The game was displayed on an oscilloscope and with an analog joystick we can control the movement of the shield to block incoming astroids from all four directions.

Wiring Printed Circuit Board

Objective of This Project

The main objective of the Printed Wiring PCB Board project is to design, construct, and demonstrate a printed wiring board that implements a digital logic circuit for my Circuits Laboratory class. When 5V and CLK cycle is applied to the PCB board, LAM_3353 (my school ID) will display on the 7-segment display one letter/number at a time in the corresponding order.

Jacky's Multisim Schematic Simplified.PNG

Utilizing logic gates design on ni multisim & Eagle

To test that my logic is working properly and is displaying LAM_3353 on the 7-segment display in the correct order, I've initially tested it on NI Multisim first. Knowing that my logic is working properly, I then move all the components to Eagle. By doing so, I will be able to design my PCB board for further fabrication process with OSH Park (the company that makes PCB boards).

Jacky's Eagle Schematic.png

Finalizing pcb Board for fabrication on Eagle

After putting all the essential parts on Eagle, I can now start designing my board within the software. The most challenging part of this design stage is making sure that there are no "wire crosses" as it can cause some problems with our circuit (short circuit), and fitting all the components on a 2" x 3" board dimension. After receiving my board from OSH Park, I can then solder every logic gates and other components onto the board (as shown in the video below), and it's ready to be tested. 

Jacky's PCB Board.png

Wiring Printed Circuit BoarD
Final Demo

This is the final demo of my project. The 7-segment display is displaying LAM_3353 in the corresponding order every 1 second or so, which is what I wanted. Therefore, it is apparent that the logic are working according to plan.

Transistors sumo bot

Objective of This Project

The main objective of this project is to build a sumo bot that knocks out an opponent while staying in the ring. This project allows me to show my full understanding of different types of transistors and how different electrical components work within the robot for my Electronics Lab class. There are two parts to this project, the first part is to test whether our robot is tracking the box or not (as shown in the video). Whereby, we will be attaching a beacon to our opponent robot for the second part, so our robot can essentially track it and try to knock the opponent out of the ring just like knocking out the box in the first part. 

Overview copy.png

Designing my sumo bot logic on ni multisim

I started with designing all the logic and what electrical components we need to use for the logic of the robot on NI Multisim. However, for this project, it is quite challenging for me due to how we cannot use any microcontroller as part of the robot to control any of the motor movements. This robot used a generous amount of MOSFETS, four 555 timers, one Op-Amp, two TSOPs, two motors, resistors, capacitors, transistors, diodes, CDS cell, LEDs (colored LED and IR LED), and a 5V relay. 

IMG_2192.HEIC

Preparing my sumo bot for the final competition

After accomplishing the first part of the robot project (as shown in the video below), I then moved on to the second part, which is modifying the robot to knock out other opponents instead of just knocking out boxes. I adjusted the capacitors and resistors value on the 555 timers, which will change the backup and rotation time of the robot when approaching the white line of the ring. 

IMG_2271.HEIC

Transistors Sumo bot
Final Demo

This is the final demo of my robot project. The robot will run when it detects light, and it will then start tracking the box and knocking it out of the ring. A beacon is attached to the box, so the receiving circuit on the robot can track and follow it. In addition, I also have an IR LED and phototransistor circuit attached on the robot to track the white line on the ring, so it knows when to back off.

Touch-Free Switches

Objective of This Project

As part of the final independent project for my Electronics Lab, I want to build something that can be useful for our society today. The primary use of this circuit in our daily lives is to function as a touch free-switch for hygienic purposes, whereby, traditional switches present a lot of risks that could potentially affect our health in the long term. However, the circuit that I’ve designed can do something much more than just turning ON/OFF an LED, instead of putting our output as ordinary LED we could potentially connect it to other electric devices. This includes but is not limited to, a touch-free fan, a fan that can be operated by hand movement, a touch-free automatic door, a security system, and other industrial applications.

Working-Principle-of-IR-Sensor.jpg

Designing my Touch-Free Switches on NI Multisim

I design this circuitry on NI Multisim. The main component here is the LM555 Timer used in an “astable mode” for the “trigger mode” and "monostable mode" for the "timer mode" of the touch-free switch. In an “astable mode,” the timer will act as an oscillator that generates a square wave with a specific frequency depending on the values of the resistors and capacitor used, which allows us to trigger the output as HIGH or LOW. Whereby, in “monostable mode” will allow the timer to generate a pustulating output which allows us to give the circuit a specific time duration.

Independent Design.png

putting everything together

After testing if my circuits for both "trigger mode" and "timer mode" is working properly on NI Multisim, I then started building all the circuitry on a separate breadboard for each of the modes. Whereby, both circuits are working properly as expected. In this case, instead of attaching the output to something like a motor or a fan, I attached it to something much more simpler like a yellow and blue LED (however, we can change the output to something more useful) representing different modes. 

Independent Design_edited.jpg

Touch-free switches
Final Demo

This is the final demo of my touch-free switches project. There are two modes for this circuit built separately, one is "trigger mode", pressing a button to turn something on, and another one is "timer mode", pressing a button and it will switch off at a specific time depending on the resistors and capacitors values.

LabVIEW PID Controller Lego Mindstorm

Objective of This Project

The essential goal of this project is to learn how to implement PID (Proportional-Integral- Derivative) control in our Lego Mindstorm EV3 robot by writing our codes in LabVIEW 2016 for my Introduction to Control Systems Engineering class. The task that we have to accomplish with our robot is to create a line follower using PID control to go up a ramp in our first phase. Then when both light sensors see black, they will switch into a state machine, and act as a line follower to track around the edge of the ring in our second phase. Lastly, when the ultrasonic sensor sees an object less than 10 cm away from itself, it will switch the state into PID control to track down the edge of the ring in our third phase.

Phase 1.png

Design pid algorithm & lego mindstorm robot

I implemented the PID control by trial and error, without implementing any specific method initially. I started with measuring the light sensor values by placing the sensor in the middle of the light and dark areas. Whereby, the values change when we are on-ramp and on-ring, due to the light that is being reflected from certain objects can be different, and this will be our “set point” value. Initially, I made a proportional controller by setting our Kp equal to 1 and slowly tuning the values of both Ki and Kd to make our PID control by testing it numerous times and making various observations when adjusting each value. The graphs below show the final run during our final competition that implements PID control for the first phase and third phases of the competition.

IMG_4737.HEIC

PID Verification graph & benefits 

Using LabVIEW 2016 I retrieved the data recorded in the EV3 brick to start making the PID gains graph. By writing a few lines of code on MatLab 2022 I managed to plot out the PID gains graph as shown. By doing so, it is apparent that I've implemented a full PID controller to the robot, not just making a proportional controller. As shown in the video below, we can see how the robot runs very smoothly when it changes its state from a "state machine" to a full "PID controller" as its performing its line following stage and outer ring tracking stage.

PID Graphs.jpg

Labview pid controller lego mindstorm Final Demo

This is my final demo of the PID controller Lego Mindstorm robot. The robot started in PID state when going up the white ramp (line follower) onto the ring, in which it switch its state to a normal "state machine" to track the outer white ring. Once it sees an object less than 5 cm away from it, the robot changes back to PID state and will stop once we press the button on the top. 

LabView vending machine

Objective of This Project

The goal of this project is to learn how to use LabView 2016 properly and understand the benefits of both having a "state machine" and making a "string constants" for my Introduction to Control Systems Engineering class. Whereby, I will have to build two vending machines, the first one using a state machine and one using string constants, with an additional useful plugin to the vending machine itself.

3.png

Utilizing state machine on labview

The first vending machine that I made is a very simple state machine. The vending machine will allow quarters to be input also and adjust the program so it has different states (5, cents, 10 cents, 15 cents, 20 cents, 25 cents, etc.) and dispenses when at least 60 cents are added to the vending machine. If we input too much money or if you press the Cancel Transaction Button, then an LED will light up that says "change returned" and the program goes back to the initial state. While writing the algorithm for this vending machine I noticed that it is very simple to make, but it takes a lot of time (tedious) to put in every possible state that the vending machine could land on.

1.png

Utilizing string constants on labview

For the second vending machine, I will be using "string constants" to make my life a bit easier. String constants allow me to make more possible branches/options that the vending machine could take if we were to insert different amounts of coins. Strings are another way to do a state machine and they usually lead to fewer problems and errors. In addition, I've added an extra feature (as shown in the video below) that tells the user how much more money they still need to dispense their soda at $0.60. 

2.png

Labview vending machine final demo

This is the final vending machine in which I've implemented "string constants" to its overall algorithm. In addition, I've added another extra feature which is the message box, which tells the user how much more money they still need to insert to get their soda.

FPGA Verilog Multimeter

Objective of This Project

The goal of this project is to create a digital multimeter that can calculate the DC value inputs given by the professor for my Computer Hardware Design class. For this project I will be mainly implementing everything I learned in this class to this final project, including, UART interface, FPGA Verilog coding to my DE10-Lite Board, and Python terminal interface (which will be sending the data back and forward from the computer to the FPGA board). 

IMG_4703.HEIC

Verilog Coding & planning

For the code, I coded everything on Intel Quartus Prime Lite 2022 in Verilog programming language. The system shall have one UART TX/RX pair. TX shall be assigned to GPIO[0] and RX shall be assigned to GPIO[1]. The UART format is 9600 baud, no parity, one stop bit. The system shall use two 7‐segment displays to display the current value of the selected measurement in hexadecimal. The system shall use SW[1:0] to select the measurement function. KEY0 shall be used as a reset signal. The system shall receive 8‐bit unsigned samples on the UART RX input and store the samples in memory. The system shall store the last 256 samples received. If the value of SW[1:0] is 00, the system shall calculate the DC value of the 256 stored samples.

Screen Shot 2566-01-07 at 14.02.06.png

Applying UART interface with python terminal

When applying the UART interface the data will be sent back and forward between my computer and the FPGA board. Therefore, the selected measurement shall be calculated each time a new sample is received. Each time the measurement is calculated, the result shall be displayed on HEX1 and HEX0 in the hexadecimal format of the board. Each time the measurement is calculated (I will be using Python to be sending a huge list of data in hexadecimal to my FPGA board), the result shall be transmitted via the UART interface. 

Screen Shot 2566-01-07 at 14.03.17.png

FPGA Verilog Multimeter  Final Demo

This is the final demo of my multimeter Verilog project. The data that was given by my professor was put into my computer to the FPGA board via UART interface, in which the calculated values from the FPGA board were then sent back to the Python terminal screen back a forward changing the average DC values as new values were added to the terminal, that's why we can see the number flickering on our FPGA board as our terminal board is updating.

Matlab Signals & FilterinG

Objective of This Project

The goal of this project is to explore the various uses of MATLAB 2022 and to decode specific sound wave that was given to me by the professor for my Digital Signals & Filtering class. For this project, I will be mainly implementing everything I learned in this class about signal design and MATLAB coding to help me solve this task as part of my final project. 

Screen Shot 2566-01-10 at 12.03.23.png

Matlab Coding & planning

For the code, I coded everything on MATLAB 2022 in C / C++ programming language. For this project, we were given a specific sound wave that we have to generate based on the things we learned about filters and signal design. For instance, writing a code that produces a specific sound by a low-pass filter or a high-pass filter. Whereby, I ended up generating a cosine analog frequency of 440 Hz, which makes a small beeping sound on MATLAB for the first part of this project. 

Screen Shot 2566-01-10 at 12.03.32.png

Getting the perfect pitch & sound wave graph

For the second part of the project, we were to generate a longer sound wave of up to 4 seconds long. By doing, I managed to demonstrate "filtering" to the sound, making it produce various frequency sound waves which lasted for 4 seconds each. From this "filtering technique" I then have to get the bad quality audio from the professor and try to make it crystal clear by designing a lowpass digital Butterworth filter for the audio file.

untitled.jpg

Matlab Signals & Filtering Final Demo

This is the final demo of the filtering technique that I've coded as part of my final project. Applying my filtering technique to the lowpass digital Butterworth filter, I managed to convert my professor's bad audio file into a crystal clear audio file that humans can listen to without any disturbances (as shown).

bottom of page