Hello Nathalie,
You can use the example "Frequency Response (step response method)" that you can found on NI Web site :
http://sine.ni.com/apps/we/niepd_web_display.display_epd4?p_guid=B45EACE3E6EF56A4E034080020E74861
But, you should just do some modification because NI-5122 uses NI-DAQmx and not Traditionnal DAQ :
*** In the VI front panel, in the "resource name" command, type the name of the device (MAX name) and not DAQ::... (please see the help of the function "niScope Initialize")
*** In the diagram, you will see that the example uses digital trigger. So you need to use the connector "AUX I/O".
This is a 9-pin mini-circular DIN connector Provides access to the external digital trigger lines PFI 0 and PFI 1 (with optional cable)
Please see the user manual in the link below :
http://digital.ni.com/manuals.nsf/websearch/998C51E969F4900486256D9F007103F2
I test the program with PXI-5122 and it works well.
Regards,
Sanaa T
National Instruments France