4-PAM simulation error

12 ビュー (過去 30 日間)
Siddharth A
Siddharth A 2022 年 6 月 24 日
回答済み: Jaswanth 2024 年 1 月 3 日
I am Trying to just simulate a PAM 4 signal and demodulate it i keep getting this error.
Error in 'Pam4_modulation/M-PAM Modulator Baseband': Input must be an integer between 0 and M-1.
i am using a random interger generator block in my simulink model.
there is no output from the integer genertaor when i connect it to the 4PAM block. i would like to generate and display pam4 signal and even add noise to it. Can i understand what is the problem here.
i have attached the file to this.
  1 件のコメント
Scout Patel
Scout Patel 2023 年 5 月 4 日
Double click on "Random Integer" . Set the size to 4

サインインしてコメントする。

回答 (1 件)

Jaswanth
Jaswanth 2024 年 1 月 3 日
Hi Siddharth,
The key to resolving the error you're encountering in your Simulink model lies in setting the size of the random integer generation correctly. For a PAM-4 (4-level Pulse Amplitude Modulation) system, the integers used to modulate the signal must range from 0 to 3, which corresponds to the four distinct amplitude levels (hence the term '4' in PAM-4).
The error message you're receiving, "Input must be an integer between 0 and M-1," indicates that the input to the M-PAM Modulator Baseband block is expected to be within a specific range. In the case of PAM-4 modulation, 'M' is 4, so the range of acceptable integers is 0 to M-1, which translates to 0 to 3.
Please refer following image for guidance.
Hope the above information is helpful in resolving your issue.

カテゴリ

Help Center および File ExchangeModulation についてさらに検索

タグ

製品


リリース

R2021b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by