⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 ms_orthogonalspreading_initialization.m

📁 CDMA2000 反向信道仿真 matlab
💻 M
字号:
%============================================================
% MS_OrthogonalSpreading_Initialization
%============================================================
%根据信道类型设置walsh码的长度和序号
switch xChannelType
    case 1
        %反向基本信道
        xWalshCodeLength=16;
        xWalshCodeIndex=4;
    case 2
        %反向补充信道1
        xWalshCodeLength=2;
        xWalshCodeIndex=1;
    case 3
        %反向补充信道2
        xWalshCodeLength=4;
        xWalshCodeIndex=2;
    case 4
        %反向专用控制信道
        xWalshCodeLength=16;
        xWalshCodeIndex=8;
    case 5
        %反向公共控制信道
        xWalshCodeLength=8;
        xWalshCodeIndex=2;
    case 6
        %反向导频信道
        xWalshCodeLength=32;
        xWalshCodeIndex=0;
    case 7
        %反向增强接入信道
        xWalshCodeLength=8;
        xWalshCodeIndex=2;
    otherwise
        error('Error: Invalid Channel Type for Radio Congiguration 3 in cdma2000 MS block <Spreading and Modulation>');
end
%根据无线配置设置输入信号的重复因子
%只支持RC3,RC4
switch xRC
    case 3
        switch xFrameLength
            case 6120
                xRepetitionCount=fix((1228.8*xFrameDuration)/12288);
            case 3048
                xRepetitionCount=fix((1228.8*xFrameDuration)/12288);
            case 1512
                xRepetitionCount=fix((1228.8*xFrameDuration)/6144);
            case 744
                xRepetitionCount=fix((1228.8*xFrameDuration)/3072);
            case 360
                xRepetitionCount=fix((1228.8*xFrameDuration)/1536);
            case 172
                xRepetitionCount=fix((1228.8*xFrameDuration)/1536);
            case 80
                xRepetitionCount=fix((1228.8*xFrameDuration)/1536);
            case 40
                xRepetitionCount=fix((1228.8*xFrameDuration)/1536);
            case 16
                xRepetitionCount=fix((1228.8*xFrameDuration)/1536);
            case 24
                xRepetitionCount=fix((1228.8*xFrameDuration)/384);
            otherwise
                error('Error: Invalid Frame Length for Radio Configuration 3 in cdma2000 MS block <Spreading and Modulation>');
        end
    case 4
        switch xFrameLength
            case 4584
                xRepetitionCount=fix((1228.8*xFrameDuration)/12288);
            case 2280
                xRepetitionCount=fix((1228.8*xFrameDuration)/6144);
            case 1128
                xRepetitionCount=fix((1228.8*xFrameDuration)/3072);
            case 552
                xRepetitionCount=fix((1228.8*xFrameDuration)/1536);
            case 267
                xRepetitionCount=fix((1228.8*xFrameDuration)/1536);
            case 125
                xRepetitionCount=fix((1228.8*xFrameDuration)/1536);
            case 55
                xRepetitionCount=fix((1228.8*xFrameDuration)/1536);
            case 21
                xRepetitionCount=fix((1228.8*xFrameDuration)/1536);
            case 24
                xRepetitionCount=fix((1228.8*xFrameDuration)/12288);
            otherwise
                error('Error: Invalid Frame Length for Radio Configuration 4 in cdma2000 MS block <Spreading and Modulation>');
        end
end
%end program
        
        
        
        
        
        
        
        
        
        
        
        
        
        
        
        
        
        
        
        
        
        
        

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -