Average implement properly sampling frequency

I am writing a program for the acquisition of data that reads the voltage and data current with a 3 phase generator, IE. There are 3 channels of voltage and data 3 (also represented under tension) current data channels come in my USB-6009.

The waveform is not yet known but probably roughly sinusoidal until about a power of say 1.5 kHz frequency. I need to work on the (reliable) frequency in real time I know the speed of the generator. I use the 'harmonic distortion Analyzer' VI do basically this deep down it's a FFT on the data. I suspect it's too much an overload of treatment because if I increase to more than 1000 Hz sampling frequency, I'm starting to have problems - and if the data max 1,5 KHz I need to sample and analyze at least 3 kHz, of course.

Yes - the question is, how can I get the sample to say 3-5 kHz and work on the fundamental frequency of a channel in real time without causing any fall?

All responses are greatly appreciated.

Dave

Dave,

(1) I prefer to put all of the analyses (as TFF) in a separate loop.  The loop of the acquisition is acquisition.  He acquires the data and puts it into a queue or motor of action to be used elsewhere.  In this way the acquisition schedule is not dependent on the time required for analysis or display or save to file...

(2) lines are built in features that allow the data to be passed to independent parties to the program efficiently and without risk of conditions of competition inherent in global or local variables.  They also have interesting features like the clusters of the error and wait times.  Motor action are the screws in the form of a while loop with a shift register uninitialized to retain this data.  They contain generally structure case to allow the selection of different actions, such as Initialize, writing and reading, or more complex things like subset of return or average accumulate data.  Research on the Forum for the nugget of Ben and many other messages on the subject.

(3) convert the data type as a whole.  Obviously, you cannot acquire a fraction of a sample, by using a representation of data that supports the fractions is not necessary.  In this case, it is not a big deal, but constraint points can tell you that LV is doing additional work behind the scenes to change data types, maybe not the way you wanted changed them.

(4) Yes and no.  The FFT should work even if the signal to noise ratio is reduced.  Think of the component continues as being the 'noise' in this calculation.  If you want zero crossings, so it is essential that the offset be withdrawn.  With the current shift zero crossings will be moved off the middle of the sine wave points or the signal may cross any zero if the oofset is greater than the peak of the periodic component value.

(5) I suspected something like that.  Multiplying is a bit faster than dividing so it is best if the speed is important.  If it is more convenient for the user or the programmer to get dividers, let the programme calculate the reciprocal multipliers.  Do it once, outside the loop where it does not affect the time.

(6) I missed that you move data between the loops.  Can't do it with the register shift.  See point 2) on the queues or the drivers of the Action.  Notifier could be used also for the stop.  My opinion: the only place where you need a local variable is if you need to write a value to a control, such that when you set a saved a file configuration.

A lot to learn.

Another question: in the original post you said that you needed the determination of the frequency in 'real time '.  It is a slippery term.  You use it for anything other than the number of samples to read?  How fast can change the frequency?  What are the consequences of a delay in obtaining the frequency?  How late can tolerate you before that consequences are unacceptable?

Lynn

Tags: NI Software

Similar Questions

  • PCI-6111 valid sampling frequencies

    We have old card PCI-6111 that we still use. A question was posed regarding the applicable sampling frequency setting.

    According to the manual, this thing must have base clock of 20 MHz and 100 kHz. There also a divisor of 24-bit and (not sure about this) multiplier of 2 bits. I guess that these can be used for the base of appropriate clock frequency scaling.

    What sampling rate can be set on this thing? This is a spec 5 of average size, then that would be the upper limit. Can I put any arbitrary frequency (integer) under this? Or what I need to work explicitly what it's capable of? With a 24-bit divider, this would imply that there is a wide range of frequencies that doesn't "work" on this map.

    What happens when I select a frequency that is "bad"? Round it inflicts, turn down?

    Hello Isaac, it's Paul with engineering Applications to the OR.

    This device offeres 2 at simultaneous sampling of the analog inputs, 5 MS/s per channel - The 2 AI can enjoy up to 5 Mhz per channel each.  You can only have 1 frequency clock for your tasks to HAVE, but this clock frequency can be adjusted from 1 kHz to 5 Mhz, set by you.  Note that most of our maps allow GOT down to 1 HZ, but this ADC is different because it uses a pipeline ADC convereter.  In addition, since this card can taste at the same time, it means that two analog channels will be read at the same exact time (in parallel).  In addition, the value of I is a 12-bit number.

  • Change the value to trigger record data for 1 s sampling frequency of 50 KHz

    Hello

    I have a VI with NI9215 and cDAQ-9178 chassis hardware. The function of the VI came out an instruction to RS232 interface and record 1 second of data every time that the set point is changed.

    The procedure is

    (1) modify the policy to the flow regulator

    (2) wait 2 seconds.

    (3) record of 4 channels for one second to the sampling frequency of 50 KHz.

    At present, the problem is for the first edition of this program, two seconds (rather than) data was saved and corn, the error message 200279.

    II. I revised for the second edition of the structure of the producer and the consumer who can increase the speed of the buffer.

    The question is how to configure the trigger to start the backup of data and limit data save for one second whenever the set point value changes.

    (1) which edition is best for my application?

    (2) how to trigger the data record?

    (3) how to record only a second of data?

    I also checked this announcement and the elapsed time seems not to work for this case.

    Any help would be greatly appreciated!

    Melody

    Hello

    you have not used properly the nodes property.

    1. replace the case structure in the first loop, with DAQmx features, with a structure of the event. Change the event fires for a worth of control of the setpoint change.

    Edit: as stated in your first post, use the structure of the event, but put inside the while loop.

    2. DO NOT connect error output from the stop command property node. Replace it with a local variable for the stop button.

    Try these and let me know.

  • Sampling frequency for two different routes for acquisition of data USB-6009

    Hello

    I use a box USB-6009 and incorporating the "daq assistant" to change the sampling frequency.  I'm trying to find a way to set the sampling frequency to two unique values for the two separate channels.  I tried implementing two assistants daq and different for each channel sampling frequency setting, although it does not work.  Is it possible to set the sampling frequency for all channels, and then reduce the rate for another channel - or an alternative?  I would be recognizing any input on this matter, thank you!

    -Anthony

    All tasks on a DAQ card using the sample clock should use the same clock.  Therefore, you cannot have two tasks on the same sample of DAQ card at different rates.

    Alternatives would be:

    1. to combine all channels in a single task and to accept additional data

    2 get an additional DAQ card to use at the same time

  • sampling frequency

    Dear all!

    I hope everyone is doing well!

    Well! I am a student in first year of Labview and would like an expert on this VI opinion I did. I'm learning by doing! This VI is to see the effects of sampling at different frequency. I have a LABVIEW 8.5 and uses an express VI to simulate signal, two assistant screws DAQ etc. I also play a little with the number of samples and sampling frequency.

    Come to the points that I did not understand!

    1. the present VI crashes and I am not able to understand what is the reason?

    2. the time scale itself changes as I raise the number of samples, even if I keep the same frequency sampling.

    3. in addition, the peak frequency changes with the number of samples! Why?

    I hope to have your kind response!

    Thanks for your time!

    Tajim

    Hi Tajim,

    Sorry for the late reply. I made a few changes to your VI and it works very well.

    You can start with the choice of the same sample rate and the number of samples of the three waveforms. In this way, all will synchronize initially.

    After that, you can try to change the sampling rate and the number of samples for the waveforms. However, you should becarefull when setting very large number of samples. If you have a low sampling rate, say 100 Hz and a high number of samples, say 1000 samples it will take 10 sec to acquire all the samples. If the second DAQ assistant is running at the highest sampling at the same time, you will have an overflow of buffer of data acquisition and it may hang. Of course it is a means to avoid this by implementing different structures in LV, but for the purposes of this test, you should be ok if you just keep this in mind.

    Thank you!

  • Can I mix up to 32 bits at a higher than 44.1 kHz sampling frequency?

    When I'm using Ableton Live, it allows me to choose 16, 24 or 32-bit, and then I can choose a up to 192000 sample rate.  Is this possible in the hearing?  I've been through all the preferences and all tabs and I can't find this option.  Everything I find is a convert, or the option adjust.  But this isn't what I want.  I want to mix down this way.

    The closest thing is when I go to "Export Audio Mix Down", I found, I can select 32-bit.  Then, there is a box for the sampling rate, with all the different values.  But it doesn't allow me to change of 44100.

    ?

    sleepwalk1000 wrote:

    Thanks for the responses guys.  Hmm, well the reason why I ask this question is because I am preparing a cd to be sent to a mastering studio.  The engineer told me to mix down to 24 bits instead of 16 bit.  I asked him why, because everything happens to 16 bit cd anyway.  He said even if my session has 16 bit files, if I have them running through the beaches with effects bus vst as Altiverb (which I do), it will improve the sound effects in mixdown, if treated according to a higher bitrate.  Would poll better mix so he could work in the mastering session.  I assumed that this meant that a higher sampling frequency would also be beneficial.  Maybe not?  I use a lot of high-quality vst effects, so I want to make sure I get the best possible results.  I mean if you have this option and space disk hard isn't a problem, why wouldn't you use it?

    It is interesting that the export Audio Mix Down allows me to mix a session from 16-bit to 32-bit files, but if doesn't let me change the sampling frequency.  Maybe I'm not understanding these terms exactly.  I always thought that, for two, more the number, the higher sound quality.

    SteveG - tell you it would be a waste of more than 32 bit 44.1 kHz mixing?  What about k of 48 or 96 k?  There is not a noticeable difference?

    The sample rate only affects the highest frequency that can be solved - it has no impact on the quality of all, once the rate is high enough to fix all that humans can hear. You determine the highest frequency that can be resolved in any case of the sample given by half to get the "Nyquist" frequency - so 44.1 k the highest frequency that can be fully resolved is 22.05 kHz. The human ear extends up to 20 kHz, but it's only in young children - by the time you reach your teenage years he began to fall, especially if you listen to a lot of loud music... then 44.1 k is already greater than any human condition to the response at high frequency. This overall been proved? You bet it has!

    To discover the truth about the hype about the sound quality in general and more bits/sample rate are concerned, you should first read this thread of AudioMasters - and the links it contains. It's of high quality academic research, and all attempts to discredit have been completely ransacked.

    Your mastering engineer is correct up to a point, but not really for the right reasons - mixtures of 32 bits are usually more specific, simply because the sums do more accurately and scale of signal is significantly improved. You must keep in mind that the only place where you will hear no appreciable difference with one more high bit depth would be in really quiet parts of reverb tails. The best way to do a mix in Audition is to do all this in 32-bit (which is floating point version of 24-bit anyway) and if he really wants a 24 bit file, you can convert the 32-bit mix after that you have to create a copy of 24-bit integer. As much as the 16-bit CD is concerned, if you (or engineer) procrastinate it properly when you do the master of the 16 bits of the final mix of 32-bit CD, then the effective resolution is higher than 16 - bit anyway - there is also a thread of AudioMasters explaining all this too (it's complicated).

    What all the above implies, is that if you keep your mix 32 bit 44.1 k files as they are, if you remaster at a higher sample rate, all you have to do is up-conversion files in hearing. You don't win a single thing in doing that, but then again, you won't lose anything either - and person don't will be able to make a difference! This is not a case of "why don't use you it?" - this is really a case of ' why would you? "

    Either way, it should be noted that due to some misinformation presented by people who should really have known better long, understanding of most of the people of sampling is completely and totally false. Once more, a search around AudioMasters will give you a better understanding of the present. If I get a chance later, I'll look on all appropriate threads.

  • How to acquire with NiScope at different sampling frequencies and lengths Records?

    I need to acquire the data of 2 channels of the NI PXI-5114 map two different sampling frequencies high, at the same time. Also, I put 2 different record length. Is this possible?

    I understand that 'Vertical' settings can be configured for individual chains because the function 'Vertical niScope Configure' has 'channels of entry with which we can assign the desired channel. But for horizontal settings such as "min sampling rate" and the record min length, I could not find such an option to specify the channel. Would it not common to both channels?

    I hope that the device is capable of simultaneous sampling and therefore channels can be configured individually to different sampling rate.

    Hi AJ_CS,

    Why do you have to be distinct from sampling frequencies on channels separated from the digitizer even?  What different sampling rate do you want?

    But for horizontal settings such as "min sampling rate" and the record min length, I could not find such an option to specify the channel. Would it not common to both channels?

    You do not have an option to configure the settings of hoirizontal on a channel by channel basis because this concept does not exist in the traditional sense of the use of a scope.  Compatible with the concept of IVI, an oscilloscope traditional benchtop will have only a button or a set of buttons for setting the parameters of synchronization of the unit.  There is therefore no horizontal configuration to separate channels on the scanners NOR.

    I hope that the device is capable of simultaneous sampling and therefore channels can be configured individually to different sampling rate.

    Similar to a traditional benchtop oscilloscpe, the device is capable of simultaneous sampling.  But as mentioned above, the channels can not be configured for different sampling frequencies high.

    However, you can ignore data that you think is not relevant.  For example, if you assign 100MS/s CH0 and CH1 to 50 MS/s, then you throw all other samples.

    Alternatively, you can use separate scanners (a channel on each digitizer) and configure them to taste at different rates.  You can set frequencies of sampling on scanners NOR separated and even synchronize them with TClk.

    -Andrew

  • How to acquire the signal to very high sampling frequency

    Hello world

    My name is Luke Ho. I am trying to acquire the signal with Labview (Sthelescope). The signal comes from sensor acoustics, then filters and amplifiers to adapt to ADC rank (0 - 5V). Thus, the maximum frequency of the signal is 40 kHz.

    According to the Nyquist theorem, I sampled at least 80 Khz signal.

    Is there a sampling frequency devices like that? or y at - it another way of better? I used the Arduino before, but it was about 10 kHz.

    I need your advice.
    Thank you all and have a nice day.

    holucbme wrote:

    Thanks for your recommendation

    But is it possible without USB Data Acquisition, it is quite expensive for me.

    This is the cheapest option to NEITHER. I tried to look for options to other companies, but more I found in the same price range, or not answering is not your condition of sample rate.

  • AI PXI-6255 sampling frequency

    Hello

    We use a simulated PXI-6255 device and with the LabVIEW example, apparently, that we can achieve a sampling rate of 20 kHz to 50 channels without warnings or errors.

    The spec is the number max of 20 kHz channels must be approximately 38 channels (750000 / 20000).








     

    1.25 single channel of MECH. / s
    multi-channel of 750 ksps / s (aggregation)

    The simulation cannot not representative of the unit or the real PXI-6255 does support a higher rate that we expect?

    Hi jharris66,

    It is not a limitation of the driver to the sampling frequency, so a simulated device reports any error in this case.

    In this example, I think that the limit of 750 kHz comes to the multiplexer.  I don't expect to see the same error messages with the real device, but your accuracy will probably not to spec because not allowing enough time settling between the channels.

    The limit of 1.25 MHz is the maximum ADC sampling frequency.  You can probably exceed this number somewhat, but once you go too far beyond 1.25 MHz you will eventually receive a synchronization from the hardware error when the ADC cannot follow.

    Thus, the specification is still technically 750 kHz for channels multiple acquisitions.  You can probably run at a higher rate than this (even on real hardware), but I wouldn't say that it is supported.

    Best regards

  • Xincrement is not agree with sampling frequency

    I use two PXI-5114 scanners that are being synchronized. I am taking 5 seconds worth of data.  I have = 1e3 sample rate and record length = 5e3. I get only about 1.3 seconds worth of data.  I looked at the actual length of the record and the actual sampling frequency outputs and they said the same thing as the façade made. I looked at and then the info out of the Cluster.vi of Fetch NiScope Multi Wfm and he had the same record length, but the value of Xincrement is 262e-6. This fits with what I get.  Any ideas?

    Thanks in advance.

    Hi AT1,.

    Thanks for posting. What you see, this due to the fact that the minimum sampling rate of the PXI-5114 is 3.81 kech. / s. The digitizer will force any value less than 3.81 kech. / s up to this value, so a record of 5000 samples take 1.31 seconds to acquire. If you are looking to acquire 5 seconds worth of data, I recommend to increase the length of record about 19 050 samples, which should be about 5 seconds worth of data. Let me know if this would work for your application.

    Kind regards

    Joe S.

  • limited on PCI-6052E sampling frequency

    I'm trying to measure with two channels with a PC containing a NI PCI-6052E card that is capable of 333KS/s on LabView 8.2. With two channels each channel must be able to 333KS/s / 2 = 166.5KS / s. everytime I try to set the sampling frequency above 94339 Hz I the following warning and the vi no longer works.

    WARNING 200012 occurred DAQmx start Task.vi:1
    Possible reasons:
    Clock speed specified is greater than the maximum ADC conversion rate. ADC invaded errors are likely.

    If I place a similar task in the Measument and Automation Explorer and I can easily make two channels measures to 160kHz without error. Above 166kHz I start getting the same caveat (200012). The code that I use calls first DAQmx create Channel.vi, then DAQmx Timing.vi and finally DAQmx start Task.vi. Everything works fine and I did measuements, but I can't rise above 94339 Hz sampling rate even if it should be possible.

    I just looked and I can't understand the issue here.

    Dear Voyn,

    I thank very you much for your message on our forum. If you create a task for a single channel, you can get a higher sampling rate? Are you able to reproduce the same problem with an example from the finder example? Go to hardware to go end tab selected and output-DAQmx online-online-online-online Acq Cont voltage analog measures & chart voltage-Int Clk.vi

    You can select several channels as well. If it shows the same behavior; which driver DAQmx do you use?

    Best regards

  • How to change the DAQmx sampling frequency

    Hello

    I'm trying to: record streaming channels (acceleration 21 and 1 tension) using a DAQmx task, then convert the data to a PDM file. The program files and output to the TDMS file very well. The issue I'm having is that I can't change the sampling frequency. I want to record 500samples/s and I can not get the "real sampling rate" of change of 1651.61samples / s. I am trying to use the clock to do this and I succumbed. I also tried to change the settings of "Timing" in the task without a bit of luck. Here is a screenshot of the .VI I created. I've also attached a copy of the file VI. Any help would be greatly appreciated!

    Thank you

    Tony

    You will need to provide the model of your device. You can also look in the sheet/manual to see what the real supported sampling rates. Some devices have limited rates.

  • How to specify the sampling frequency? Must use "measurement & Automation Explorer '?

    I use to measure the input current analog OR cDAQ-9171 (chassis only location USB) and NOR-9207. I have 2010 NOR-installed DAQmx and LabVIEW.

    How can I specify the sampling frequency?

    If I use M & A Explorer to create the task, I can specify the flow rate (Hz) on the Configuration tab-> sync settings.

    For the acquisition of data NOR, it is mandatory to use M & A exploring?

    If I don't want to use M & A Explorer, how can I specify the rate (Hz)?

    Hello

    You can specify the sampling frequency with "DAQmx Timing.vi" located in the function palette DAQmx (read context-sensitive help on how to use wisely).

    You do not have to use M & A exploring (MAX) to create a task.

    A simple and quick way is to use DAQ Assistant (same configuration as in MAX) to configure your measurement.

    Another is to use blocks of DAQmx function to manually build your application code.

    In my experience Assistant DAQ is ideal for simple tasks (one measure), with regard to the more complex measures (synchronized the analog and digital inputs).

    I tend to use function blocks because they give you more freedom about code execution.

    Note: You can also build DAQmx code from a wizard configured DAQ task.

    Best regards

    Matej

  • effects of sampling frequency on the convolution of waveforms (need feedback from a GURU of signal processing)

    I have included my code as version 8.5 for those who have not yet upgraded to 8.6.  I have also included some screenshots so that you can replicate the results I got.  I hope that some signal processing guru can shed light on what I mention it further.

    This VI convolves the signal of impulse response of a simulated servomotor which is essentially a damped sine the input pulse which is a step function.  The signal resulting convolved should be IDENTICAL to that of the step response of the engine which is RED on the display 1.  As you can see the convolution that results in table 2 shows the same structure of frequency, but its magnitude is INCORRECT.  As you can see in the catches of 2 screen sizes differ by a factor of 2 & done the sampling frequency of the wave.  Why the sampling frequency, impact on the scale is also very strange & disturbing.

    Would appreciate any corrections & explanations so that I trust the convolution of the other wave forms of entry than just the step function.

    OK, I think I have it working now.  Your premise on the effect of sampling on the derivative is not the issue.  Does it affect what the FREQ of levy is the basis of time of convolution.  As the convolution product is not continuous but discrete the length of the array should be taken into account & the sampling frequency must be consistent with this length of array as well as 1 second corresponds to 1 second.  If sampling freq is 2 kHz & the length of the array is 1000 then to get the correct time base by a factor of 2 must be taken into account.  In addition, to take account of the DC, shift of the ZERO gain factor must be added to the convolved signal to get the correct size.

    Thanks for making me think more deeply.

  • Synchronization of the inputs and outputs with different sampling frequencies

    I'm relatively new to LabView. I have a NOR-myDAQ, and I am trying to accomplish the following:

    Square wave output 10 kHz, duty cycle 50%.

    Input sampling frequency of 200 kHz, synchronized with the output that I get 20 analog input samples by square wave, and I know what samples align with the high and low output of my square wave.

    So far, I used a counter to create the square wave of 10 kHz, display on a digital output line. I tried to pull the document according to (http://www.ni.com/white-paper/4322/en), but I'm not sure how sample at a different rate than my clock pulse. It seems that this example is intended rather to taste one entry by analog clock pulse. There may be a way to create a faster clock (200 kHz) in the software and use that to synchronize the analog input collection as well as a slower 10 kHz output generation square wave?

    I eventually have to use the analog inputs to obtain data and an analog output to write the data channel, so I need the impetus of the square wave at the exit on a digital PIN.

    How could anyone do this in LabView?

    Hi Eric,.

    All subsystems (, AO, CTR) derive from the STC3 clocks so they don't drift, but in order to align your sample clock HAVE with pulse train that you generate on the counter, you'll want to trigger a task out of the other. I would like to start by a few examples taken from the example Finder > Input and Output material > DAQmx. You can trigger GOT off the train of impulses, start by Gen digital Pulse Train-keep -you probably already use a VI like this to generate 10 k pulse train. AI, start with an example like Acq Cont & chart voltage-Ext Clk - Dig Start.vi-you'll want to use the internal clock so just remove the control of the "Source of the clock" and it uses the internal clock. From there, simply set the "Source of the command" either be the PFI line generates the meter, or ' //Ctr0InternalOutput '-assuming that you are using the counter 0. You'll want to make sure that the start of the task HAVE faced the task of counter I is ready to trigger off the first impulse. They should be aligned at this point.

    For debugging, you can use DAQmx export Signal to export the sample clock - you can then brought the train line and the PFI pulse to make sure that they are aligned.

    Hope this helps,

    Andrew S

Maybe you are looking for

  • Extraction of fundamental characteristics - Watchdog Agent VI could not download the cRIO

    Hello I design an application in real time on one OR cRIO-9022, using the Watchdog Agent made by IMS Center toolkit. During the loading of my VI on CompactRIO, I get the following error message: Deployment SoundVib_Resampling.lvlib:oa_CIC Interpolati

  • graphics cards double Office HP 500 - 205-t

    I have a HP 500 - 205t with which I ordered an upgrade the dedicated video card.  The computer is around the age of six months. Now I find that I need two monitors. The dedicated adapter has only a single output. The integrated one has two. Is it pos

  • Password welcome screen so boring!

    It's really annoying that I have to sign in with my password every time my computer wakes and/or reboots, etc. Is there a way to bypass this initial password when I'm the only one using the computer? It's an Aspire V5 572P 4824, 8.1 for Windows 64-bi

  • Interrupt the print job

    I have HP OfficeJet Pro L7590.  My question is the general impression: How do you give up a print job It is ongoing?  I want to just stop the current print job.

  • Multiple site-to-site vpn configuration

    I am able to successfully create two different ipsec tunnels and I need them to be operational at the same time. However, when I "crypto map" (physical) external interface of my PIX 515, one of them is operational both. The tunnels go to two differen