# TEEP first week documentation
## Basics of 5G

### Key Technology of 5G
1. Scalable OFDM-based Air Interface
- Refers to a flexible radio access technique that allows the system to operate over different bandwidth sizes — from very narrow (e.g., 5 MHz) to very wide (e.g., 400 MHz).
- In the early days of mobile tech, bandwidths were fixed. But as users demanded faster internet for more devices in more places, engineers needed a flexible system — hence, scalable OFDM.
- Think of it like a highway with adjustable lanes. During traffic jams (heavy data), it expands to fit more cars (data streams). At night (low traffic), it shrinks to save energy.
2. Advanced Channel Encoding
- Refers to smart coding techniques that add redundancy to the data to detect and correct errors without retransmitting.
- In past generations (like 3G/4G), bad connections meant retransmitting lost packets, which cost time and energy. New encoding techniques make 5G smarter — it can fix broken messages on the fly.
- Imagine sending a fragile glass vase in the mail. Channel encoding is like adding bubble wrap — if something breaks, the receiver can still piece it together.
3. Massive MIMO (Multiple Input Multiple Output)
- Involves using dozens or even hundreds of antennas at the base station to serve multiple users simultaneously.
- As cities got denser and more people went online, traditional antennas couldn’t keep up. With Massive MIMO, 5G towers now talk to many people at once, clearly and efficiently, like a choir instead of a soloist.
- Imagine a busy restaurant where, instead of two overwhelmed waiters, you have 100 smart robots, each following one customer around and serving them personally.
4. Mobile mmWave (millimeter Wave)
- Refers to the use of very high frequency spectrum (typically above 24 GHz) for mobile communication.
- With 4G, downloading a 4K movie took a few minutes. In crowded places, the signal often lagged. Engineers turned to higher frequencies — like opening a new expressway in the sky, dedicated for ultra-fast data — even if it only goes a short distance.
- Think of mmWave as a bullet train — super fast, but only works on perfectly smooth tracks with no obstacles.
### General Differences Between 4G and 5G

### General 5G Architecture Options

* 5G NSA (Non-Standalone)
- 5G NSA is a transitional architecture where 5G works on top of existing 4G infrastructure. It uses:
- 4G LTE for control signaling (like authentication, mobility, etc.)
- 5G NR (New Radio) for faster user data.
- Why use 5G NSA? :
- Faster to deploy — no need to build an entirely new core network.
- Lower cost for operators in the early stages.
- Supports early 5G use cases like enhanced mobile broadband (eMBB).
* 5G SA (Standalone)
- 5G SA is a full 5G architecture — it uses 5G for both radio (RAN) and core network.
- It runs independently from 4G.
- Uses a new native 5G Core, supporting features:
- Ultra-low latency
- Network slicing
- Why 5G SA is Needed:
- Unlocks the full potential of 5G (not possible with NSA).
- Supports advanced use-cases like:
- Autonomous vehicles
- Industrial automation
- Smart cities
- AR/VR with ultra-low latency
### 5G Core Architecture

## 5G RAN & O-RAN

RAN stands for Radio Access Network, and it is the part of a mobile network that connects your device (like a smartphone) to the core network.
In simple terms:
Imagine you're trying to send a message to your friend who's across town.
The RAN is like the local post office that picks up your message (wireless signal), figures out where it needs to go, and sends it to the main delivery center (core network).
It also handles incoming messages and delivers them back to your phone.
* What does RAN do in a mobile network?
1. Connects user devices (UEs) like phones, tablets, and IoT devices to the network.
2. Transmits and receives radio signals via base stations (like 4G eNodeB or 5G gNodeB).
3. Handles radio resource management — decides how much bandwidth each user gets.
4. Provides mobility — keeps you connected as you move from one area to another (like during a call in a moving car).

## RAN and OSI Model 7 Layers


## Integrated RAN vs Disaggreted

* Integrated RAN:
- The RU and BBU are located at the same site, typically at the base of the cell tower.
- Coaxial feeder cables are used to connect the RU to the antennas mounted on top of the tower.
- These cables are long and thick, which can cause significant power loss—the longer and bigger the cable, the greater the loss.
- This results in lower power efficiency and may reduce signal strength and coverage.
* Disaggregated RAN:
- The RU is placed near the antenna, either at the top of the tower or close to it. This setup is often called RRU (Remote Radio Unit) or RRH (Remote Radio Head).
- Only a short and thin coaxial cable is needed to connect the RU to the antenna, minimizing power loss.
- The RU is connected to the BBU using fiber optic cables through the fronthaul interface, which has near-zero signal loss.
- This setup improves power efficiency, allows for stronger signal, and provides better coverage.

## RAN Functional Split

RAN functional split refers to dividing the traditional, monolithic base station (BBU) into smaller, modular units. This makes the network more flexible, virtualized, and cost-efficient.
* Monolithic RAN:
- The RU (Radio Unit) is close to the antenna and handles the radio signals.
- The BBU (Baseband Unit) does the digital processing.
- These two are connected by the Fronthaul.
- The BBU connects to the Core Network via Backhaul.
* Functional Split RAN:
- The RU (Radio Unit) still handles radio signal transmission.
- The DU (Distributed Unit):
The DU is responsible for real-time processing of the radio interface. It sits in between the Radio Unit (RU) and the Centralized Unit (CU).
- PHY (Physical Layer) Signal modulation, demodulation, encoding/decoding, OFDM processing, MIMO processing
- MAC (Medium Access Control) Scheduling, resource allocation, retransmissions (HARQ)
- RLC (Radio Link Control) Segmentation, reassembly, error correction
- The CU (Centralized Unit) :
The CU manages non-real-time functions of the RAN. It acts more like the brain of the system, handling mobility and session control.
- PDCP (Packet Data Convergence Protocol) Header compression, security (ciphering), IP packet routing
- RRC (Radio Resource Control) Signaling between UE and network, handover control, bearer setup
- SDAP (Service Data Adaptation Protocol) QoS flow mapping to data bearers
* These components are connected by:
- Fronthaul (RU - DU)
- Midhaul (DU - CU)
- And Backhaul (CU - Core Network)

## RAN RIC (RAN Intelligent Controller)

O-RAN RIC stands for Open Radio Access Network - RAN Intelligent Controller. It is a central component in the O-RAN architecture designed to introduce intelligence, flexibility, and openness into the Radio Access Network (RAN) of mobile systems like 5G.
The RIC enables intelligent, automated control of RAN resources using data-driven decision-making, particularly AI and Machine Learning (ML).
* The implementation of Artificial Intelligence (AI) in the O-RAN architecture is most suitable within the Non-Real Time RIC (Non-RT RIC). This is because AI, particularly Machine Learning (ML), typically requires large-scale data collection, processing, model training, and evaluation, all of which are computationally intensive and time-consuming tasks.
* In contrast, the Near-Real Time RIC (Near-RT RIC) is designed to handle time-sensitive functions that require fast and immediate responses, usually within a time frame of 10 milliseconds to 1 second. Therefore, while the Near-RT RIC may execute already-trained models or apply pre-defined policies, the actual development and training of those models are better performed in the Non-RT RIC.
* By placing AI/ML processes in the Non-RT RIC, the system can ensure both optimal model accuracy and efficient network performance without compromising the latency requirements of real-time radio operations.
# Next DEMO
https://hackmd.io/@XyMSKk5ZRU6mrKfDrEH9Vg/rJLpHJFyee