Answered step by step
Verified Expert Solution
Question
1 Approved Answer
clear all; close all; file = fopen ( ' TransmittedMessage . txt ' ) ; % Open the file ( should be in the same
clear all;
close all;
file fopenTransmittedMessagetxt; Open the file should be in the same folder
message freadfilechar; Read the text as a string from the file
fclosefile; Close the file
Converting the message into a bit stream
textdoubletemp decbinmessage; Convert each character into binary minus zero is used to convert it into double instead of logical
Each character is represented by bits
bitstream reshapetextdoubletemp.; Reshape it into an array is needed for proper ordering
BPSK Modulation
Fs ; Sampling freq
Tb e; Bit duration
fc ; Carrier freq
Eb ; Energy per bit
dt Fs; time step
N lengthbitstream; Number of bits to be transmitted
t :dt:NTb; Time vector
t t:lengtht; the last element is discarded to adjust the size of the time vector
Stream repelembitstream,Tbdt; Enlarge the bit stream to match the size of the time vector
StreamStream; Replacing s with NRZ Level Encoder This arrangement fits the definition of log likelihood ratio
StreamStream; Replacing s with NRZ Level Encoder This arrangement fits the definition of log likelihood ratio
ModulatedSignal sqrtEbTbcospifctStream; BPSK modulated signal to be transmitted
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started