Take the 2-minute tour ×

I'm trying to figure out how to simulate eye diagrams for communications systems using Python. I'm not sure I have the theory down completely, though. From what I could figure out using some old LabWindows C code, the process is something like this:

  1. Take an input pattern and convert it into a discrete signal with the same time step between points as the system's step data
  2. Perform an FFT on the input pattern and convert the system's step data to an S-parameter
  3. Multiply the transformed pattern and the S-parameter pointwise (equivalent to convolution in the time domain)
  4. Take the inverse FFT of product.

This is essentially all the old code seems to be doing, but unfortunately at the key steps there are calls to LabWindows functions that have poor online documentation, and I don't have access to the development libraries myself.

Any help or knowledge of eye diagram theory would be a tremendous help.

share|improve this question
It seems to me that this should be migrated to Stack Overflow site. –  AdamRedwine Oct 3 '11 at 21:22

2 Answers 2

I needed to ensure that the pattern itself was long enough to get the correct $\Delta f$ in the frequency domain, since $\Delta f = \frac{1}{N}$ where $N$ is the number of points in the pattern signal. If this $\Delta f$ does not match that of the transformed data, then there is no real way to combine the two.

share|improve this answer

I think the sequence of steps should be:

  1. convert input-data into analogue signal (modulation)

  2. apply distortion and noise to simulate the effects of the channel (e.g. using convolution with impulse response)

  3. demodulate the analogue signal into the out-data

Then you plot input-data against out-data.

share|improve this answer
My problem is that while there are plenty of software packages out there that can do the simulation, I need to integrate it into an automated test system. I can't seem to find any literature online detailing how to actually do this simulation. I was hoping that there would be someone who had worked with this sort of metric before and could aid me in my development. –  bheklilr Aug 3 '11 at 13:31
Do you have a coder and decoder? A long time ago I looked at linmodem, which is a software modem implementation for linux by the great Fabrice Bellard linmodems.org. –  whoplisp Aug 3 '11 at 13:47
I found the solution. I was not making my pattern long enough to get the frequency content necessary from the FFT. –  bheklilr Aug 3 '11 at 14:01
@bheklilr: You should post that as an answer and accept it. –  Kevin Reid Oct 2 '11 at 13:16

Your Answer


