11-26-2018 08:12 AM
Hi, I have a LabView program that uses NI USB-8451/2 and sends SPI commands to a slave device repetitively in a loop. I want the program to have as short iteration time as possible, to be able to re-program slave device fast.
The NI-USB 8452 have an excessively long execution time of 1000+ ms. This is not a complicated program, no converging algorithms or anything similar, just simple calculations and register write/read. For comparison, the same program on the older NI-USB 8451 takes 20-30 ms to run.
Also, i noticed that execution time on 8451 gets longer and longer as more iterations are done (after thousands of iterations time reaches 300-400 ms , from initial 20-30). There are no self-appending variables. All the variables are re-assigned on the start of new iteration.
What's the issue? The SPI runs with 10 MHz clock and wirtes/reads 11 32-bit registers, so the programming time should not take longer than hundreds of us.
The program uses formula nodes for simplicity.
I would be grateful for any help.
Regards
11-26-2018 09:41 AM
@GSnawadzki wrote:
What's the issue?
Impossible to say without seeing the code. But my first thought is you are not handling references properly.
11-27-2018 09:33 AM
Hello crossrulz, thank you for your reply.
According to:
https://forums.ni.com/t5/LabVIEW/reference-vs-local-variable/td-p/1781924
and
https://knowledge.ni.com/KnowledgeArticleDetails?id=kA00Z0000019LXrSAM&l=pl-PL
I am not using references nor property nodes. Only direct wire or local variable, because they are faster.
Unfortunately, I cannot show the code (it's my employer's property) 😕
Regards
PS. I'm also a fan of Monty Python and the Knights of NI 😄
11-27-2018 09:50 AM
@GSnawadzki wrote:
I am not using references nor property nodes. Only direct wire or local variable, because they are faster.
I was actually referring to the reference to the 8452.
@GSnawadzki wrote:
Unfortunately, I cannot show the code (it's my employer's property) 😕
Then make a small example that is showing the issue.
@GSnawadzki wrote:
PS. I'm also a fan of Monty Python and the Knights of NI 😄
Knight of NI is actually a community ranking for those who manage to rack up 10k posts. Though, the term was created by Dennis (the original knight) who was a HUGE Monty Python fan.
11-27-2018 01:41 PM
@crossrulz wrote:
...
@GSnawadzki wrote:
PS. I'm also a fan of Monty Python and the Knights of NI 😄
Knight of NI is actually a community ranking for those who manage to rack up 10k posts. Though, the term was created by Dennis (the original knight) who was a HUGE Monty Python fan.
Here is the thread from 16 years ago when we were figuring out what the top ranking should be.
Ben