08-08-2008 07:00 AM
08-08-2008 08:30 AM
hi Ed,
Nothing really leaps out at me from your program as to why you are getting this effect. I would suggest looking closer at your voltage profile from your joystick as two possibilities come to mind.
I can see from your code that there has already been some consideration of these situations so it may not be this. Equally perhaps you may have to trade off some of this behaviour at one extreme compared to undesired effects at the other extreme e.g. too much delay may miss a small movement.
Hope this may help.
08-13-2008 11:31 AM
Hi Ed,
Was just trying to follow this thread up and see if you had made any progress with your problems and if you needed any more help with it.
Regards,
08-14-2008 02:11 AM
James, I found the problem with the program- it seems that the timings were not acting in the right place, but by moving the task inside the case structure it now acts much quicker. I think the peculiarity was that the program would sense the input, then wait for the time delay before it passes the command signal onto the task, where it would then actuate. In the new version, the program commands the task before the delay time, therefore eliminating the strange timings we were seeing before. I have attached the code so you can see what I mean.
Cheers,
Ed
08-14-2008 03:08 AM
Excellent! I can see what you mean. Just a word of warning though, as you have it set up the wait and the DAQmx command will be able to begin in parallel so your timing might be slightly out. Better still would be to have the DAQmx task in the sequence structure before the wait, this would make your timings more reliable and guarantee the DAQmx executing before the wait.
Regards,