CANOpen - sample rate problem

Hello

I use the CANOpen toolkit to communicate with a sensor that can be set at a sampling frequency of 1 kHz. Before I used the standard frame API and there I received my PDO objects to each MS because I want to make programming easier I would use CANOpen. But I can't set the sample rate of 1ms. When you use 2ms data is not transmitted with the correct timestamp interval.

I have attached the message error code when you use 1ms as sampling frequency and the part of the diagram block with the initialization of the PDO.

Maybe someone can give me a hint.

Best regards

--
Joachim

It is good, your sensor begins to send pictures as soon as you start communication.

You might remove the remote setting function and then it would behave like your old application framework API, except for one detail.

Your old approx. api framework its mult read read all available images.

The CANopen Read is only a single point read. Thus, he read only a single image. This means that you need to run the loop in ms rate, that is really risky with windows.

You can enable buffering, but it can lead to errors of overflow, or turn off the buffering is now and read the most recent value.

See the example updated the.

DirkW

Tags: NI Products

Similar Questions

  • With the NI 9205 module Max sampling rate - problems

    Dear friends,

    I develop a project of lv, which makes and control system of engine dyno. The material is CRio-9022 with other cards and also 9205 for AI. There is an encoder for angle attached to the motor shaft with 3600 chatted by Tower as well as an index to indicate the end of a revolution. the output of the encoder is measured by card 9411. The speed of the motor is 1500 rpm. I measure pressure data and couple when I receive a 'tick' of the wheel. This means my sampling rate for pressure and torque each is 90KO/s.

    but I was not successful to lead it. The program is great and I can show them, but I believe that there is a problem in the choice of material for the task. With the data of pressure and torque of the 9205, I also measure other channels for the controller output mass flow and temperatures. So in all I use 8 channels of the 32 available. But only the pressure and torque are acquired at the wheel-driven sampling rate. the rest are acquired about 5 times per second.

    Since the 9025 is a multiplexing ADC, 250K sampling frequency is divided by the number of channels accessed = 250 K/8 = 31 K samples/channel. With this in mind, I decided to acquire data of pressure and torque with each beat 3rd rotary encoder, essentially on 30K samples/s sampling. However, I see a large amount of noise.

    So I decide to average more than 1 second cycles (so the engine runs at about 25 cycles/sec, I averaged over this issue). The resulting pressure and torque graphics do not match with those measured by an oscilloscope in terms of amplitude but the frequency and shape is correct.

    I noticed an interesting feature in the charts. When I pass interpolation between the points, I see several curves made by points instead of a continuous locus of points. Accordingly, I find that the acquisition is slower than necessary, and so there are less number of points sampled as required. These points are not synchronized 25 cycles I have on average and therefore the separate "curves". It is because of the possibility that some points receive a higher number of 'contributions' several times (when you add), the neighbouring points.

    so I conculde that the 9205 is not fast enough to do the job. also noise, perhaps due to crosstalk or gosting when the mux changes channels. the impdences output pressure and the couple are of the order of 10 K ohms.

    the Labview code outline: well, there is a vi FPGA, which takes the rotary encoder ticks and sends a signal to the case of each 3rd tick. The signal contains a 16-bit integer, indicating the number of ticks. This signal is sent to a 1 element FIFO. This fifo is read in a parallel while loop, where it remains awaiting a new element. The while loop bed fifo, where data are available, takes a measure of pressure channel. A node memory of the method is called to provide data according to contained in the index number equal to the number of ticks to signal fifo. Then he adds the current pressure reading to the reading of the memory and stores the sum in the same memory location.  Thus, an array of elements of 1200 is formed, where each elemnt is a sum of the values taken of more than 25 cycles. This memory is transferd to a dma fifo and reading side host. is done similarly to involved couple. host-side the fifo is read and divided by 25 to get the average. This average is displayed on a waveform graph.

    Please check the attached file to get an idea of the problem. Sorry for the long post.

    Please suggest if you understand the problem and suggesstions or solutions.


  • After starting hearing sound becomes distorted (sample rate problem?)

    Hello!!

    Just when I start the program (Audition 2), I noticed that all the sounds that play inside or outside the program are distorted. He

    kind is sound that occurs during playback of a file to the frequency of sampling, kind of digital noise.

    When I stop the program and start any sound or a mp3 file on the computer, he continues to play distorted. It happened immediately and did not have before.

    I have Windows XP. The audio driver is "Soundmax Digital Audio". The audio driver is "Audition Windows Sound".

    At the hearing, in the Control Panel, hardware Audio Setup, "directsound output ports" are defined Soundmax Digital Audio with the size of buffer 2048; audio channels: 2 ; Bits per sample: 16. Said of the driver properties: 44100 Hz sampling frequency of; clock source internal, samples of size 2048 buffer

    There is no problem with my drivers or anything. I have no idea why this has happened.

    Any ideas would be greatly appreciated! I hope it's a sort of hearing that must be adjusted.

    I had this happen when I used a card firewire motu back in the day.   It worked fine for a few days and all the sudd

    en I'd get the loud pop and the line in my record.  I sold it after finding that it was not compatible with my windows upgrade.   Here are a few ideas that might help you

    • Your sound card has a windows update and threw it out of your drivers. Try to re install your drivers again now that your pc has updated.

    Hope that helped.

  • 9237 & 9205 with 9178 chassis sampling rate problem

    I have two 9237 and installed 9205 on 9178 chassis. In order to acquire data at the same time, all the 9237 and 9205 use the 9178 chassis onboardclock. But when the sampling frequency is 20000 Hz, 20000 points just takes less than a second. When the sampling frequency is 10000Hz, get 10000 points takes 1 second.   Why does this happen?

    A 9237 use a channel, another 9237 use 4 channels, the 9205 use 3 channels (differential).  And manual brand 9178 slightly confused me, the frequency of onboardclock MHz 80?

    Looking forward to your help. Thank you.

    By default the 9237 derives its clock dividing down from his own time of 12.8 MHz (see specifications) base.

    12.8 MHz / 256 / N

    Where N is a whole 1 to 31.

    10 kHz is achievable (12.8 MHz / 256 / 5), but it's not 20 kHz (12.8 MHz / 256 / 2.5).

    The driver will round up to the next frequency, which is be of 25 kHz (12.8 MHz / 256 / 2).  25 kHz, we would expect 20 k samples to be acquired in 0.8 seconds.

    Best regards

  • Meter in a loop and read reduced sampling rate

    Chassis: 9188

    AI: 9219

    CI: 9401

    As pictured, without reading of CI, I can adjust the sampling rate of metered software. But reading of CI, the maximum rate is around 5 Hz. I already changed 9219 high-resolution property to high speed. What is the problem?

    Hi, Carlos, thanks for your response. I acutally has solved this problem by using the connection series I and CI (i.e. connect error off HAVE error in the CI) but not parallel as the pic shows.

  • . VI filtering IIR and response: response of Butterworth filter size depends on sampling rate - why?

    Hi people,

    I'm not an expert in the design of the filter, only a person in applying them, so please can someone help me with an explanation?

    I need to filter signals very infrequent using a buttherwoth filter 2. or 3. order of the bandpass 0.1 to 10 Hz.

    Very relevant amplitudes are BELOW 1 Hz, often less than 0.5 Hz, but there is as well the amplitudes beyond 5 Hz to observe.

    It's fixed and prescribed for the application.

    However, the sampling rate of the measuring system is not prescribed. It may be between say between 30 and 2000 Hz. Depends on the question of whether the same set of data is used for analysis of the higher up to 1000 Hz frequencies on the same measure or this is not done by the user and he chooses a lower sampling rate to reduce the size of files, especially when measuring for longer periods of several weeks.

    To compare the response amplitude of 2nd and 3rd order filter, I used the example of IIR filtering .vi and response:

    I was very surprised when I found that the response of greatness is considerably influenced by the SAMPLING RATE I say the signal generator in this example vi.

    Can you please tell me why - and especially why the filter of order 3 will be worse for the parts of low frequency below 1 Hz signal. Told me of people experienced with filters that the 3rd oder will less distort the amplitudes which does nothing for my the frequencies below 1 Hz.

    In the attached png you see 4 screenshots for 2 or 3 command and sampling rate of 300 or 1000 Hz to show you the answers of variable magnitude without opening labview.

    THANK YOU very much for your ANSWERS!

    Chris

    Hello Cameron and thanks for my lenses of compensation.

    I can now proudly present the solution of my problem.

    It seems to be purely a problem of the visualistion information filters through the cluster of the scale.

    After looking in the front panel of the IIR, I suddenly noticed that the "df" of the pole size is changing with the Fs of the input signal.

    For a Fs to 30 Hz, the "df" is 0.03 Hz so you see the curve of the filter with more points, see png.

    For a Fs 300 Hz "df" is 0.3 Hz, so the curve is larger with only 3 points between 0 and 1 Hz.

    For a 1 kHz Fs the df is 0,976 Hz, so there is no point in the graph between 0 and 1 Hz.

    It's strange that for constant Fs, df of this cluster NOT reduced with the increase in the number of samples, as it does in an FFT.

    However, I hope now the filter used now for the curves obtained with the proposed Lynn way and the response of greatness from the filter information fit together.

    Thank you for your support.

    Merry Christmas and a happy new year to all.

    Chris

  • High sampling rate for 18 strings in a single task - DAQmx

    Hello

    My current experiences require the acquisition of 18 channels (6 HAVE custom voltage with excitement, voltage AI 12) data at a sampling frequency of 50 kHz. My question is if it is faesible using a single cDAQ-9172 chassis. Used modules are 2 x NI 9237 and 4 x NI 9215.

    The previous researcher on this project used 2 different Renault to do this, but I was hoping that I could reduce it to a single DAQ to simplify the synchronization of all channels.

    I wrote a *.vi (attached) to do this and write to a TDMS file using a structure of producer-consumer; However, when I run the * .vi, I can run for minutes, but the number of samples recorded for the PDM is rarely more than 100 k. Subsequently a buffer size error (attempted to read from the samples that have been overwritten) with less than 200 k samples ever record. I checked the max sampling rate (using a property timing node) with the configured task as in the * .vi and it shows a maximum of 235kHz.

    I can't say if I make just the structure of the producer consumer incorrectly or if I ask too much of the cDAQ-9172 unique?

    Any help would be much appreciated.

    See you soon

    Bart

    Hi bart.s,

    TiTou speaks sampling aggregate not simultaneous, so sampling rate 50kS/s is the same for all channels.

    I see the problem in the loop of the producer. If your sampling frequency is 50kS/s/ch and you read that a single sample/ch you will lose data because the producer loop cannot run so fast. You should read more than one sample. I recommend you also to move your tracing to the consumption loop code and work with larger amounts of data.

    The second problem may be with the error handling in your loop of consumer. Merge the mistakes of loop of consumer and producer and also add a few general for two loops off if the error occurs (for example, using local variable).

    Best regards

    CaravagGIO

  • Save the high sampling rate data

    Hello!

    I use NI PXI-4462. (204.8kS, input analog 4 / s sampling frequency)

    I want to collect data from "load" (channel 1) and "acceleration sensor" (2nd, 3rd, 4th channel).

    I also want to save data to a text file.

    So I do a front pannel and block diagram. You can see in the attached file.

    The program works well in a low sampling rate.

    However, when I put up to 204800 s/s sample rate, the program gives me "error-200279".»

    I don't know what means this error, and I know why this happened in the high sampling rate.

    I want to know how I can fix it.

    Is there any problem in my diagram?

    Is it possible to save high sampling rate data?

    I really want to samplling more than 200000 s/s rate.

    I would appreciate if you can help me.

    Thank you.

    NH,

    You have provided excellent documentation.  So what has happened is that the amount of time it takes to run the other portion of the loop results in a number of samples to be taken is greater than the size of the buffer you provided (I don't know exactly what it is, but it will happen at high frequencies of sampling high) resulting in samples are crushed.  You might be best served in this case to take a loop of producer-consumer - have the loop you have acquire the data but then have an additional loop that processes the data in parallel with the acquisition. The data would be shipped from the producer to the consumer via a queue.  However, a caveat is that, if you have a queue that is infinitely deep and you start to fall behind, you will find at the sampling frequency, you specify that you will begin to use more and more memory.  In this case, you will need to find a way to optimise your calculations or allow acquisition with loss.

    I hope this helps.  Matt

  • sampling rate 5015

    Hi talented engineers OR,.

    I use PXI 5015, measurement studio and make acuqisition of data sampling rate 40 MHz. The command

    niScope_ConfigureHorizontalTiming (vi0 40000000, 40, 50, 1, VI_TRUE)

    is used to set the sampling frequency. However, when we check the signal of sampling, it is 60 MHz rather than 40 MHz. same thing happened when it is set at 50 Mhz. The actual sampling frequency is always 60 MHz. But when we created the frequency goes low to 20 MHz or 10 MHz, it works fine. We use an external 10 MHz reference clock, and I'm sure that the PLL is locked. We are a State control.

    Everyone comes up with the same problem? Please let know me if you need more information about it. Thanks in advance.

    Sincerely,

    Bin

    Hi Ben,

    Unfortunately, the only way you can use a 40 MHz sampling frequency is if you import it into 1 PFI. The ditch down the method that we use with our advice on sample clock gives you only the integer values 1 and more. 60 MHz is your next best option.

    Kind regards

  • Specified sample rate clock works do not

    I hope that I was right to post on this forum. I have a problem that I had not previously in the acquisition of data on a chassis 9172 cDAQ using a 9234 for 2 analog inputs and a 9219 for four thermocouple inputs. The 9219 is obviously not ideal as it has a rate relatively low sample (and I have a 9213 on the way), so I'll have to use to HAVE. ADCTimingMode to isolate channels on this module for "high speed" mode if I can get an adequate sampling for my load. The question that arises is that no matter what I do to specify a sample rate, the actual sampling rate ends up being 1651,61 Hz, higher than the features of the 9219, if I get an error. I tried to use the DAQmx property node to set the calendar and the clock sampling VI but neither work. The only source that I can choose is on board, but when I check the source used is cDAQ1Mod1/AI/SampleClock, even if I get an error when I try to provide as a source of sample VI clock.

    As it is, my VI runs despite this error and seems to produce accurate data, but the original problem is with long testing I will have unnecessarily large data sets unless I start to decimate my other data, and the secondary problem, it's that I can't get the program to run when I try to incorporate my task of counter. In this case, the error ends the execution and he acquires no data.

    I have attached my VI under the task of counter (I'm on 8.5 and have the coming upgrade as well), but also an image of a simplified version of the VI only try to specify the settings of a channel of AI. I get the same result with it. I'm a bit of a loss here because I've never had this problem before, and it seems that there is something beyond rudimentary that I'm missing, so I would really appreciate any help anyone could provide. Thanks in advance.


  • Conflict to sample rate (specified real vs)

    I use NI 9234 to acquire my sensor data using labVIEW 8.6. I have been using labView for only the past two weeks, so please bear with me as my knowledge is so fundamental. I'm reading several channels over time. My problem is when I finished my VI, I discovered the whenever I change my bit in VI code rate, she even more fast (several sampling rate than what I said).

    I've never used a time base external with a data acquisition card, so it's a bit outside my field of knowledge. You may consult the manual to see if it's possible.

    Personally, I wouldn't bother. If you want a lower sampling rate 1,652 kHz, you could always decimating up to a lower rate. For example, if you enjoy at 1,652 kHz and then take each sample 16, you would then end up with an effective 103,25 Hz sampling rate.

    If you want to exactly 100 Hz you could make, because they suggest in the link and use the 'resample waveforms (continuous) .vi"to re - sample data.

  • Buffer size different sampling rate.

    Hello

    I'm new to Labview and me has encountered a problem.

    I did some measurements using two Renault and continuous type used samples. One device was NI 9239 and this one has a sampling frequency possible other than the size of buffer that I put. I put the size of the buffer of 3000 and the rate of possible samples of the device were 2941 and 3125.

    From what I understand, this type (continuous type of samples) the size of the buffer is full and send it to the computer.

    My question is this: my device sample rate is 3000 or 3125?

    Why do you ask? You say that you know that a sampling rate of 3000 is not possible.

  • Sampling rate - USB NI 6259

    Hello.

    I have problem with maximum sampling on USB - 6259 of NOR. I measure the hearts of rabbits EKG and I need to know, what maximum frequency can I sample this signal. I use 10 channels and I don't know if the maximum sampling frequency is for each channel or one.  I know, I use the sampling rate 1 MECH. / s, but I don't know if MECH. / s means MHz I do need knowledge rate (frequency) Hz sampling. I know that USB - 6259 OR maximum sampling rate 1 ms/s, and 16 bits of resolution. This means 2 MB/s, but it is for each channel, but only one? Can I sample my signal with sampling rate 1 MHz theorist?

    Thak much for your answers.

    Since you have only a clock unique convert and the channels are multiplexed, by channel sampling frequency is the rate divided by the number of channels max. In your case, you would be sampling each 100kS/dry.

  • Different sampling rate with the same connector AIO, Labview FPGA

    Hello

    I use LV 2009 with the new Toolbox FPGA and an NI PXI 7854R. I acquire an analog signal with a sampling frequency of 600kS / s. I need as the sampling rate for the processing of the data, but I also need the signal sampled with a much smaller, variable sampling frequency to a FFT.

    I've attached a picture to clarify, in a simple example, I'm looking for.

    I tried with the structure case only take each ' iht iteration, but did not get the expected results.

    Does anyone have another idea how to solve my problem? Of the, "Resampling" express VI in the funtion FPGA palette does not help me.

    Thanks in advance,

    Concerning

    Hello

    the connector for the analog input is a "shared resource", so you should he alone in your FPGA Code.

    Find attached an example that shows how to perform this task of analysis.

    Concerning

    Ulrich

    AE OR-CER

  • Audition 3.0 how to disable ASIO and the default Sample Rate recording?

    Hi people,

    New here, but I hope someone can help me with a few questions, I'll have with Audition 3.

    Firstly, some background questions.

    I use hearing parallel to a broadcast audio broadcast program called SpotOn,

    This software requires that I run the sound card, a RME Madiface XT in 48 k mode, and that all the outputs that it uses are defined as WDM Windows so that the windows kernel mixer can control them.

    This means that when I use the hearing at the same time, I have to configure it to use the "Audition 3.0 Windows Audio" driver to stop him from taking control of the sound card directly and change setting which prevent SpotOn to see its output.

    The problems I encounter are that hearing itself seems to randomly change mode in the edit window ASIO driver, I suspect that this happens when I import audio data from a key which is from 44.1 to modify for use in SpotOn. This often seems to not only make the outputs of the card its invisible to the windows kernel mixer but also change the sampling frequency of 44.1 sound card and stops work SpotOn.

    The second question I have is that the sampling frequency of default record when I record in edit mode is always 44.1 and if used it again change the map sound 44.1 and causes the same problems, I'd be very keen to know how to change this default to be 48 k if possible.

    Then.

    What I ultimatly looking is...

    1. a way to disable the ASIO drivers in hearing so that it is not only this option is available, and cannot use the Audition 3.0 Windows Sound Drivers.

    2. a way to make the sampling rate 48 k to stop people choosing 44.1 mistakenly when saving default record.

    Any help or advice that anyone can give would be much appreciated.

    Thanks in advance for your comments

    What other pilots ASIO sees your installation of 3 AA? If it's the Madiface one and you use only WDM drivers you can just uninstall the ASIO RME driver?

Maybe you are looking for

  • Uninstall quick search

    Following advise I was looking for v.framework remove the quick search. When Linc Davis says - April 22, 2015, in response to sweettat-, I found called AlimaTailflower. AlimaTailflower appeared just after unwittingly downloading an application hide.

  • TIME MACHINHE BACKUP REMAINS IN PREPARATION MODE

    TIME MACHINE REMAINS IN PREPARATION

  • WRT54G2 - no internet connection

    I have just replaced my WRT54G with a WRT54G2 router.  I used the same settings that were on my WRT54G.  Everything works fine as long as I have the blue cable plugged into my computer and the other end into Port 1 of the router.  As soon as I discon

  • Engraving of a Zoom H2 CD in WAV format?

    I'm lost - I made the USB connect to your computer the H2-I can read the files - with windows media - through the computer player.  I burned a CD - R I can play the CD I did but only in the computer... How to make a CD that can be listened to in the

  • Unpluging printer creates Virtual Port Mismatch

    Ive installed my printer Dymo 450 turbo twin perfectly. its been working for months. However, once I took my Dell Latitude mobile E5520 and reconnected the USB physical port EVEN on my computer, the print spooler has the wrong virtual port assigned.