From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

PRBS generation on FPGA

I Folk,

I need to generate a Pseudo Random Binary Sequence (PRBS) on board of the FPGA.

The PRBS is more general than the n-sequence, which is a special pseudo-random binary sequence of n bits generated as the output of a linear shift register.

It is 'pseudo' because it is deterministic and after N elements it starts to repeat itself. For PRBS the number N is N = 2^k − 1 where k is the delay in number of bits.

In the FPGA VI library is included a "White Noise Generator (FPGA Module)", where the help file says that the parameter "White Noise Type" contains the option "Uniform" that "Generates a uniformly distributed, pseudorandom pattern whose values are in the range [–a:a–1], where a is the value of Amplitude."

1- Is the "uniformly distributed, pseudorandom pattern" a "Pseudo Random Binary Sequence"?

2- In the "White Noise Generator (FPGA Module)", which is the parameter "k" that fixes the number N of elements after that the PRBS starts to repeat itself?

3- If the "White Noise Generator (FPGA Module)" is not a PRBS, do you know how to generate a PRBS on board of the FPGA?

Thanks,

Asper

0 Kudos
Message 1 of 10
(8,465 Views)

Hello Asper,

I don't think that the White Noise Generator is a PRBS sequence.

In the FPGA module there's not a function to generate that kind of sequence. In LabVIEW there's a function that creates a PRBS sequence, "MLS Sequence Waveform", as discussed in this othe forum.

So my suggestion is to look at the block diagram of this function and program it yourself with the FPGA module. Since for now it's not supported you could write this question to the "Product Suggestion Center".

Regards,

Andrea N.

Andrea N.
Principal Applications Engineer - Semiconductor EMEA
National Instruments Italy
Certified LabVIEW Architect - Certified TestStand Architect
0 Kudos
Message 2 of 10
(8,430 Views)
Hello asper,

I don't know if there is a PRBS-VI in LabVIEW already, but, according to
http://www.fh-wolfsburg.de/cms/de/pws/meyer/lehrveranstaltungen/rtvertiefung/unterlagen/PRBS.pdf (german document)
all you need is a shift register and a XOR.

The attached VI will generate a PRBS with N=5.

Hope this helps.

Uli


Message Edited by UliB on 07-11-2008 06:29 PM
0 Kudos
Message 3 of 10
(8,421 Views)

Dear Andrea,
thank you for the advice.
Before writing in the forum, I had already opened the block diagram of "MLS Sequence Waveform" and I had discovered that the approach implemented can not be translated to the FPGA because the VI uses many features that are not available on FPGA platform, for example the random number generator.

Regards
Asper

0 Kudos
Message 4 of 10
(8,399 Views)

Dear Uli,

many thanks you for your idea, I think that it's correct and I will work on it, I need a PRBS with N = 2^23-1.

Regards,
Asper

0 Kudos
Message 5 of 10
(8,398 Views)

Hello asper,

take a look at

http://www.xilinx.com/support/documentation/application_notes/xapp052.pdf.

This document lists which stages of the shift register you have to use as input for a XNOR (not XOR !). The table for k goes from 3 to 168 (N=2^k-1).

Uli

0 Kudos
Message 6 of 10
(8,355 Views)

Dear Uli,
thanks you again for the information.

By using your suggestion and the description of the Linear Feedback Shift Register I have been able to develop a PRBS with desired characteristic polynomial and repetition period (2^32-1).

LFSR: http://en.wikipedia.org/wiki/Linear_feedback_shift_register

I have also found that there is a good example of code in the IPNet

LV FPGA Pseudo Random Number Generator: http://decibel.ni.com/content/docs/DOC-1143

Regards,
Asper

0 Kudos
Message 7 of 10
(8,289 Views)

Dear Andrea

 

excuse me, but my Italian is still too rudimentory....

 

We are in 2012 now, so this thread is old. However, it is the most up to date I could find in this forum.

 

Our goal: To use PXI or Compact RIO to generate a PNBS with a modulation frequency between 15 and 150 MHz and use it to trigger an optical modulator, such as an acousto optical modulator.

 

My idea (seemingly the most easiest solution): Take a PRBS VI such as

http://zone.ni.com/reference/en-XX/help/371361F-01/lvwave/mls_sequence_wf/ or

 

http://zone.ni.com/reference/en-XX/help/372458C-01/lvsysid/generate_prbs/

 

and compile it on an FPGA card, such as the 7966R for PXI or something similar for Compact RIO. In fact, the modulation as well as the clock will be on this card, possibly also a demodulation.

 

Will this work? If not, would you have any hints?

 

Thank you very much!

 

warmest

Manuel

 

 

 

0 Kudos
Message 8 of 10
(6,263 Views)

Dear Andrea

 

excuse me, but my Italian is still too rudimentory....

 

We are in 2012 now, so this thread is old. However, it is the most up to date I could find in this forum.

 

Our goal: To use PXI or Compact RIO to generate a PNBS with a modulation frequency between 15 and 150 MHz and use it to trigger an optical modulator, such as an acousto optical modulator.

 

My idea (seemingly the most easiest solution): Take a PRBS VI such as

http://zone.ni.com/reference/en-XX/help/371361F-01/lvwave/mls_sequence_wf/ or

 

http://zone.ni.com/reference/en-XX/help/372458C-01/lvsysid/generate_prbs/

 

and compile it on an FPGA card, such as the 7966R for PXI or something similar for Compact RIO. In fact, the modulation as well as the clock will be on this card, possibly also a demodulation.

 

Will this work? If not, would you have any hints?

 

Thank you very much!

 

warmest

Manuel

 

 

 

0 Kudos
Message 9 of 10
(6,262 Views)

Hello Manuel,

 

I've heard you're in contact with my colleagues from AE Department and Sales Department. I'm sure you'll get the answers you need from them.

In any case the configuration you need is not compactRIO but a FlexRIO, like you wrote in the previous post a PXIe-7966 would do the job with the right Adapter Module.

We'll get back to you soon and after that I'll post as well in this thread.

Regards,

 

Andrea N.

Andrea N.
Principal Applications Engineer - Semiconductor EMEA
National Instruments Italy
Certified LabVIEW Architect - Certified TestStand Architect
0 Kudos
Message 10 of 10
(6,241 Views)