+ Post New Thread
Results 1 to 5 of 5
  1. #1
    Newbie level 4
    Points: 666, Level: 5

    Join Date
    Jun 2009
    Posts
    6
    Helped
    0 / 0
    Points
    666
    Level
    5

    problem with pskmod

    Hi,
    i m trying to simulate DS-cdma BER performance using MATLAB for multiusers. My problem is that "pskmod" function only accepts positive values from 0-M and in
    DS-CDMA when adding different spreaded codes i get some negative
    values that cant be given to "pskmod" e.g. " -1 1 1 -1 1 -1 -1..."
    So, how can i pass the spreaded codes using "pskmod"?
    i am trying to modulate with qpsk.
    its very urgent, i really need your help.
    thanks very much!

    •   AltAdvertisement

        
       

  2. #2
    Member level 2
    Points: 973, Level: 7

    Join Date
    Jun 2008
    Posts
    44
    Helped
    2 / 2
    Points
    973
    Level
    7

    Re: problem with pskmod

    you need to convert -1 to 0. Do it by adding 1 with all the bits and then divide it by 2. You input this to pskmod. You can convert the zeros to -1 later when you need it.



    •   AltAdvertisement

        
       

  3. #3
    Advanced Member level 3
    Points: 9,408, Level: 23

    Join Date
    Oct 2008
    Location
    Sindh, Pakistan
    Posts
    895
    Helped
    181 / 181
    Points
    9,408
    Level
    23

    Re: problem with pskmod

    Quote Originally Posted by eran135
    Hi,
    i m trying to simulate DS-cdma BER performance using MATLAB for multiusers. My problem is that "pskmod" function only accepts positive values from 0-M and in
    DS-CDMA when adding different spreaded codes i get some negative
    values that cant be given to "pskmod" e.g. " -1 1 1 -1 1 -1 -1..."
    So, how can i pass the spreaded codes using "pskmod"?
    i am trying to modulate with qpsk.
    its very urgent, i really need your help.
    thanks very much!
    I had this problem sometime ago. The solutions are:

    (1) Do a reverse mapping i.e from -1 -> 0 and +1 -> 1

    (2) Modulate the data first and then spread (go for this one)

    Hope this helped....
    .... I had to search a lot before this headache was gone



    •   AltAdvertisement

        
       

  4. #4
    Newbie level 4
    Points: 666, Level: 5

    Join Date
    Jun 2009
    Posts
    6
    Helped
    0 / 0
    Points
    666
    Level
    5

    Re: problem with pskmod

    Communications_Engineer,
    thanks for your help but i did not understand something.
    does not the modulation has to be after the spreading?



  5. #5
    Advanced Member level 3
    Points: 9,408, Level: 23

    Join Date
    Oct 2008
    Location
    Sindh, Pakistan
    Posts
    895
    Helped
    181 / 181
    Points
    9,408
    Level
    23

    problem with pskmod

    No not really. Remember that here we are using the "baseband" modulation, so it can come before spreading.



--[[ ]]--