Signal Generators

cancel
Showing results for 
Search instead for 
Did you mean: 

Scripting FGEN with stream or change digital gain with script marker/events

Task: Using a PXI-5422 (and external PC/MXI3) with an arbitary waveform to control a el.dyn. linear shaker table. For this I need about 5 periodes for fade in and fade out.

If wfrm_fade_in, wfrm (n periodes, stationary part) and wfrm_fade-out fit into memory, I can use script or arb sequence, no problem 🙂

But if my periode gets longer (>2s) I run out of memory with this solution. (I have 'only' memory for about 25s@5MSPS and >10s periode is requested )

 

One way out would be streaming... , well during the 'stationary' part I would like to avoid the streaming load (have to fetch some 200MSPS readings 🙂 ) , so  my idea is something like this:

 

Script myScript
    stream <no samples of fade_in>

    repeat until scripttrigger0
        generate mywfrm
    end repeat

    stream <no samples of fade_out>

end script

 

However the manual states:

  • The script may not contain conditional statements, including if-else, repeat until, and break statements.

I would have give it a try, but I currently cant access 'my' PXI system, so this doesn't seem to work (please correct me when I'm wrong)

Using repeat <n> should work, but then I can't fade_out when the operator detect a failure and press the BIG RED BUTTON 😉

Another idea:

Fade_in and _out could be of the same wfrm with fractional amplitudes (digital gain would be fine), but unfortunately scripting doesn't support any gain settings, so is there any way to use marker events to change the digital gain (or attenuation)  in LabVIEW (Software)?   The timing matter, but for the low frequencies I hope some ms don't matter.

 

Or: How many ms do I loose inbetween when I start a list of 3 scripts? (start and end using stream, and repeat until with generate in the middle)


 

 

 

 

Greetings from Germany
Henrik

LV since v3.1

“ground” is a convenient fantasy

'˙˙˙˙uıɐƃɐ lɐıp puɐ °06 ǝuoɥd ɹnoʎ uɹnʇ ǝsɐǝld 'ʎɹɐuıƃɐɯı sı pǝlɐıp ǝʌɐɥ noʎ ɹǝqɯnu ǝɥʇ'


0 Kudos
Message 1 of 1
(5,397 Views)