06-21-2011 05:54 AM
Hi nitzz
it didn't work maybe you can modify on my own program , I really apreciate your help, this is last shot I think :). I attached both sub VI and main program, if is possible you modify it and then upload it again. thanks .
I think you got what is right.
other thing is I want to use straing guage with DAQ card , and then compare the measured value with constant number. if value was bigger then stop whole process, I have exprience with daq card and how it works, but for stop the whole process do you have any idea ? thanks
I just attached the main vi, the sub vi I already attached in previous post.
best regards
erfan
06-21-2011 06:34 AM - edited 06-21-2011 06:35 AM
You got a wait function of 3000 ms. AND you got a "wait for next multiple" which you have connected a numeric controller to. Remove the 3000 constant and the "wait for next multiple", and connect the numeric controller to the "wait ms" function instead.
You should have studied NItzz' example a bit more.
06-21-2011 07:33 AM
Hi erfan,
I still wonder why it doesn't work for you. Now I suppose something is wrong with your VISA Configuration. You can take a look at the attached VI. I have disabled all the VISA Components in that and your subVI. So you can call it a simulation VI for your project. The rest of the array and looping part is present.
I have also removed the sequence structure from your code. The explanations are given on the block diagram. Using Sequence structure extensively is not a good practice. They restrict the flow of the program. You must learn more about data flow programming. Using error clustors for controlling the data flow and practice different kind of state machines.
Run the proram and press GO button. In the INTO VISA Indicator you can see the digits from the 2D array coming one by one with a delay of 2000ms(2Secs). These are the values which are getting written into your VISA. If this much is working fine for you, then either I am missing out something which you explained or your Instrument configuration using VISA has something wrong. I can't run that part as i don't have the instrument.
I hope this helps you in someway.
Regards,
Nitzz
(Give kudos to good Answers, Mark it as a Solution if your problem is Solved)
06-21-2011 07:36 AM
Hi,
Regarding the Daq Card and strain Gauge, Which DAQ card are you using? If you are continuously acquiring signals from the card you must put the DAQ mx in a while loop and wire a stop button to its conditional terminal. If you press the stop button the while loop will stop running and hence the acquisition will also stop.
Regards,
Nitzz
(Give kudos to good Answers, Mark it as a Solution if your problem is Solved)
06-22-2011 07:37 AM
Hi nittzz thanks alot dude , yeap I have same idea about strain measurment , I am using usb-6008 . about the sensor, do you think strain gauge is proper sensor for this kind of job ? I choose strain gauge but if you know better sensor tell me. thanks.
06-22-2011 07:46 AM
Hi erfan,
I haven't used strain gauges till now and so i can't suggest you a good option. But may be others can give you better options. I think you should close this thread and start a new thread on your question about Sensors as this thread is about inserting delay into an array. If you start a new thread for sensors, someone who has worked on similar projects may be able to help you better. Also you may mark an appropriate solution from the above posts if your problem has got solved so that others also get help later on.
Feel free to posts your doubts here if you have anymore.
Regards,
Nitzz
(Kudos are always Welcome;))
06-23-2011 07:59 AM
Hi nittz , I see the way that program run . you solved the problem man, thank you alot , but why u delet the times? because I need to control the number of sequnce. i did not connect the program to robot yet, i need to import sub vi for search, i forgot how to connect sub vi into main because this program is for long time ago. I need to improve more, I try to connect subvi and see how the robot is working, then come back to you. thanks alot
06-23-2011 08:01 AM
Byn the way i want to control the delay between the rows and elemenst both. possible ?
06-23-2011 10:28 PM
You need learn more from NitzZ's example, then you can do it yourself in the same way.
06-24-2011 01:46 AM
yes I am trying to learn , I also practic and test it, because im beginer in labview. Im in colloge until late therefore i could work on my robot only at midnight. I really appreciate nitzz for his help