LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Problem about data in "real time"

> This is very strange because if I take your example and open it like that it doesn't work too. But It doesn't explain

> why the first time it worked... I changed nothing ! It's really strange -_-

 

I took another look at this code. I may have made a mistake. I thought you were requesting 10k samples at 1k Hz.

When I open your DAQ Assistants today, I'm seeing 1k samples at 10k Hz.

Since I don't have the HW, the DAQ Assistant gives a warning, so I'm not sure the values I see are correct.

 

Can you verify your requirements for me?

steve

----------------------------------------------------------------------------------------------------------------
Founding (and only) member of AUITA - the Anti UI Thread Association.
----------------------------------------------------------------------------------------------------------------
Message 21 of 58
(1,785 Views)

Hi Bob,

 

It's ok, don't worry 🙂

 

Yes ok I didn't understand with your last message but yes I understand 🙂 

 

I didn't think about this when you spoke about connector ! Yes you are right I wasn't focus on this way. For now I changed every VI's name to begin, and I looked at the Input and Output 🙂

 

I'll work in it then 🙂 Thank you again for your very interesting advice. I appreciate !

 

Regards,

 

Maxime  

0 Kudos
Message 22 of 58
(1,784 Views)

Well sorry It wasn't really clear that's true.

 

In fact, my test is during 0,6s. 

 

I just put 6k samples at 10k Hz to have this 0,6s. 

 

I suppose that it's not the same thing now in this VI contrary to the others because it's not the same goal... 

0 Kudos
Message 23 of 58
(1,782 Views)

Or maybe did I understand nothing ? ...

 

To be more specific, if it can help. My project consist in a mannequin projected on a steering wheels. The mannequin is on a trolley and go ahead several sensor. One of them, called Trigg, is using as a landmark. And when the trolley go ahead this one, the acquisition is began, and the impact is 0,6s after. With my main  this things works 🙂 

 

And, the impact is controlled thanks to 2 acceleremeters, and the sensors (in the path of the trolley) are used to measure speed, inflate the airbag etc.

 

So the goal is saving every data  in an excel file during this test (accelerometers and the 4 others sensor). 

 

About the DAQ That's why I had 6k samples for 10k Hz. it's during 0,6s. But I don't know if I really understood very well... 

 

But with this Vi, I suppose that it's really different, and doesn't matter the samples and frequency nop ? It can be good if I got a point every... 0,01s in example ? I think that's enough 🙂 maybe 0,001 if I can ! I don't really know how it works :3 

 

 

 

0 Kudos
Message 24 of 58
(1,778 Views)

I'm not sure... when you are asking my requirements, did I answer the good thing ? 🙂 Or do you need something else ? 

0 Kudos
Message 25 of 58
(1,773 Views)

--------------------------------------------------------------------------------------------------------------------------

To be more specific, if it can help. My project consist in a mannequin projected on a steering wheels. The mannequin is on a trolley and go ahead several sensor. One of them, called Trigg, is using as a landmark. And when the trolley go ahead this one, the acquisition is began, and the impact is 0,6s after. With my main  this things works Smiley Happy 

 

And, the impact is controlled thanks to 2 acceleremeters, and the sensors (in the path of the trolley) are used to measure speed, inflate the airbag etc.

 

So the goal is saving every data  in an excel file during this test (accelerometers and the 4 others sensor). 

----------------------------------------------------------------------------------------------------------------------------

This helps a lot - thanks!

 

How do you start the acquisition?

Do you have to run several loops (collecting and logging data) to make sure you don't miss it?

 

Have you considered using one of the sensor inputs to trigger your acquisition?

(I'm not sure if your hardware supports it, but it's worth checking.)

 

steve

 

 

----------------------------------------------------------------------------------------------------------------
Founding (and only) member of AUITA - the Anti UI Thread Association.
----------------------------------------------------------------------------------------------------------------
Message 26 of 58
(1,768 Views)

Well I don't know if it's the same thing between my Main and My VI excel. 

 

In my opinion, i'll put the VI Excel in the main and run the both VI in the same time then, it's probably possible after all 🙂 

 

Well, In my Main, I start the acquisition thanks to the release tab in the Assistant DAQ, and I put as release the sensor Trigg. You should see that in my main 🙂 

And indeed, in the VI Excel (the most important actually finally ^^) I didn't put a condition. So I suppose that when I run the VI, the loop begin immediatly, without condition. 

 

So about several loops. I don't. For now I got my main and my Excel file, seperated. Put them together it's a good idea yeah, probably a future question 😄 But actually I'm just testing the VI Excel thanks to my hand only, not with the real system ^^ to don't lose my time 🙂 So I run the VI and I stand up to put my hand in front of the sensor to change de value (1 or 0) and I can see in the excel file if It works or not. And as I said it works one time ! Just one ... the first time. And after, nothing, even if I changed nothing. 

 

I hope I answered correctly to your first answers... I'm not really comfortable with the english and National instruments (stuff and Labview) so I hope that I said what you want. 

 

About your last question, I suppose that it's what I do in my main ? If I understood ... If not.. I don't know what is this solution :3 

 

Anyway thanks a lot again to help me ^^ I appreciate :3 And I'm really stress because I can't finish this project without your help, it's too hard ><

 

If you need something else, i'll do my best to answer 🙂

 

Regards ! 

 

Maxime

0 Kudos
Message 27 of 58
(1,763 Views)

Well...

 

I don't know if Labview is kidding me or not 😮 ahah ...

 

I just run the VI to see an other time the error, and it works. Everything works...

 

I tried a second time (cause yesterday the first test worked too) but no, the second time it works anyway. I tried 5 times, I still got the good file Excel and everything looks ok... I don't understand -_- I changed really nothing O_o. 

 

I'll still try this afternoon with my hand to see what's can be wrong... and tomorrow i'll try with the real system ! 

 

If I don't have problem tomorrow too, i'll put this topic as solve.. but for now, i'll still testing. Maybe that 1h later i'll see the same problem that yesterday... 

 

Regards 

 

Maxime

0 Kudos
Message 28 of 58
(1,754 Views)

Hi again 🙂 

 

So I got some news, I still got this strange thing. 

 

Yesterday, it worked. All of my tests worked, maybe should I just change differents settings etc, but the results were good. 🙂

 

This morning, I tried with the real system, and it works 3 times in a row, but for my last hit, I would like to run the acquisition later in the test (remember that I have to click on "run", I don't have condition for now to run the VI automatically). And now, again, I got this error. 

 

I don't know what's this ^^ I'll try again, and listen to your advice if you got some for me 🙂 And maybe will I put the topic as solve this afternoon, cause It works... but something is wrong with the acquisition in my opinion !

 

Thank you,

 

regards. 

 

Maxime

0 Kudos
Message 29 of 58
(1,728 Views)

Some new code to try.

 

I used the Generate NI-DAQmx Code option to convert the Express vis into DAQmx code.

This should work better.

 

You will have to open DAQmx Multi tasks.vi and select your physical channels.

You change your setting by changing the constants in the upper left.

 

Also each module has an Init vi. Open and check them for accuracy.

 

steve

----------------------------------------------------------------------------------------------------------------
Founding (and only) member of AUITA - the Anti UI Thread Association.
----------------------------------------------------------------------------------------------------------------
Message 30 of 58
(1,716 Views)