Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation


8-QAM Digital Communications Simulator

A Python-based simulation of a complete digital communication system, implementing encoding, error detection, 8-QAM modulation, and AWGN channel transmission.

Explore the Documentation »

Report Bug · Request Feature

Table of Contents
  1. About The Project
  2. Lessons Learned
  3. Getting Started
  4. Usage
  5. Contact
  6. Acknowledgments

About The Project

System Block Diagram

Digital Communications System Block Diagram.

8-QAM Constellation Diagram

8-QAM Constellation before and after the AWGN channel.

Audio Reconstruction

Original vs. Reconstructed Audio Signal (R=8 bits).


This repository contains 8-QAM Digital Communications Simulator, an academic project developed from scratch in 2024 for the Comunicação de Sinais Multimedia (CPS) course (now known as Processamento de Sinais Multimedia (PSM)) at ISEL (Instituto Superior de Engenharia de Lisboa).

The primary goal of this project is to simulate an end-to-end digital communication system in Python. It involves sending audio signals through a transmission pipeline that includes uniform PCM encoding, parity-bit error detection, 8-QAM modulation, and transmission over an Additive White Gaussian Noise (AWGN) channel, followed by matched filter demodulation and system evaluation.

(back to top)


Built With

  • Python
  • Jupyter
  • NumPy
  • Matplotlib
  • SciPy

(back to top)


Features & Key Highlights

  • Uniform PCM Encoding: Conversion between integer signals and binary arrays to prepare data for transmission.
  • Parity-Bit Error Detection: Implementation of basic error detection blocks to verify message integrity at the receiver.
  • 8-QAM Modulation & Demodulation: Simulation of an 8-QAM constellation and signal recovery using a matched filter.
  • AWGN Channel Simulation: Application of white gaussian noise to the modulated signal to simulate real-world transmission loss.
  • System Evaluation: Calculation and graphical comparison of theoretical vs. experimental Bit Error Rate (BER) and Signal-to-Noise Ratio (SNR).
  • Audio End-to-End Testing: Full transmission and recovery simulation using a real .wav audio file.

(back to top)


Lessons Learned

  • Digital Communication Pipeline: Consolidated knowledge on how information flows from source encoding to modulation and reception.
  • Signal Processing with Python: Gained hands-on experience using NumPy arrays to manipulate and process discrete signals efficiently.
  • Noise & Interference Analysis: Understood the visual and mathematical impact of AWGN on signal constellations.
  • Theoretical vs. Practical Evaluation: Learned how to plot and compare experimental error rates against theoretical BER formulas.

(back to top)


Getting Started

Follow these instructions to set up a local copy of the project on your machine.

Prerequisites

  • Python 3.8+
  • Jupyter Notebook
  • NumPy
  • Matplotlib
  • SciPy

Installation & Running Locally

  1. Clone the repository:
    git clone https://github.com/GuilhermeGraca/python-digital-comms-simulation.git
  2. Navigate to the project directory:
    cd python-digital-comms-simulation
  3. Install required packages (if not already installed):
    pip install numpy matplotlib scipy jupyter
  4. Open the Jupyter Notebook:
    jupyter notebook "CPS_T1_51827_51736_51829 (2).ipynb"
  5. Run the cells sequentially to visualize the signal processing, constellation diagrams, and BER/SNR results.

(back to top)


Usage

This project serves as a practical study tool for digital communications. You can use it to:

  • Experiment with different SNR values and observe their effect on the 8-QAM constellation.
  • Test different audio files by replacing FalaSala.wav and running the pipeline.
  • Modify the encoding bit depth (R) to see how it affects audio quantization and processing time.

(back to top)


Contact

Guilherme Graça - LinkedIn - GitHub

Project Link: https://github.com/GuilhermeGraca/python-digital-comms-simulation

(back to top)


Acknowledgments

  • ISEL (Instituto Superior de Engenharia de Lisboa) - For the academic environment and resources.
  • Comunicação de Sinais Multimedia (CPS) Course (now Processamento de Sinais Multimedia (PSM)) - For the foundational knowledge in digital communications.
  • Martim Ramos & Rodrigo Monteiro - For the collaboration and teamwork on this project (2024).

(back to top)

About

A Python-based simulation of a complete digital communication system, featuring uniform PCM encoding, parity-bit error detection, 8-QAM modulation, and AWGN channel transmission. Using numpy, scipy, matplotlib. Made in colaboration with Martim Ramos and Rodrigo Monteiro

Topics

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages