LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Soft Motion error -70229 (operating servo motor in SolidWorks from LabVIEW)

Dear National Instruments and helpers,

 

I am attempting to observe and operate a motor in SolidWorks from LabVIEW with Soft Motion. I have set it up as a servo motor and written a small VI with a Read and a Straight-Line Move (Relative) function blocks in a timed loop. The error returned from both blocks is -70229 which I understand to mean:

"A function call made to the motion controller timed out waiting for a response to an executed command. Verify that NI SoftMotion is installed to the target and that the ethernet cable is correctly connected."

As Soft Motion is installed, and I am not running hardware, I am guessing it is timing out. I have reduced the Maximum Step Size of the Assembly from 0.01s to 0.001s in a successful attempt to get rid of the error message that said it was greater than the NI Scan Engine Scan Period. Does anybody have any idea what might be going wrong and how it could be fixed?

Also, I have no idea the sort of order the position and velocity inputs to the Straight Live Move should be, as I don't know what units they are measured in. I am using default values of 1000.

I have otherwise followed all instructions in the tutorial with the Sorting Table. Any advice would be very gratefully received.

(If files are needed I can send these easily).

Kindest regards,

Ashwin

0 Kudos
Message 1 of 25
(4,472 Views)

Hi Ash,

 

It would be useful if you could list what versions of everything you are using (LabVIEW, Soft Motion, etc), any examples of code you could upload would also be useful. One thing you could try is looking at this knowledge base article. It notes that the error could be the result of having multiple versions installed to your target. Might be worth having a look over! http://digital.ni.com/public.nsf/allkb/0F7252C95910B49D86257926005F3B24

 

Kind regards,

Matt H
Applications Engineer
National Instruments UK
0 Kudos
Message 2 of 25
(4,423 Views)

Hi Matt,

 

Thank you for replying.

In fact I originally had a different error, stating:

 

"An error occurred while opening the configured SolidWorks Assembly. Select Synchronize to Assembly from the SolidWorks Assembly shortcut menu to attempt to reopen the assembly, or open the assembly manually and select Synchronize to Assembly from the SolidWorks Assembly shortcut menu."

 

which I looked up here:

http://digital.ni.com/public.nsf/allkb/D4B0ADE10330CC338625760A00458776

 

which indicated my version of LabVIEW was too old. So I downloaded the latest Soft Motion and LabVIEW programs from the NI site:

https://lumen.ni.com/nicif/us/evaltlktindctrl/content.xhtml

 

So I am using LabVIEW 2013 (upgraded from 2012), and presumably the same version of Soft Motion. I had no previous versions of Soft Motion installed before 2013. However, I do still have LabVIEW 2012 installed.

As for SolidWorks I am running 2012, I think the student edition.

 

I have attached an example of the code I have been experimenting with, to no avail. As I guess is obvious, I don't really know what I am doing.

I read the page you suggested, thank you very much for referring me to that. I do not exactly know what it means by:

"Do not perform a standard install; instead, install one of the recommended software sets."

 

Thanks again for your help, I am fast running out of time to finish this project and your help is invaluable.

Ashwin

0 Kudos
Message 3 of 25
(4,415 Views)

Hi Ashwin,

 

I actually found a few more resources related to your problem. The first Knowledge base article seems to say that the original error is caused by not having a compatible version of SolidWorks installed on the PC, so I looked for compatibility documentation, which led me to this. http://digital.ni.com/public.nsf/allkb/4E19738335E5E0B3862578D3007023C8, Though 2013 is not listed, it shows that each version is only compatible with its corresponding module version, with no backwards compatibility. 

 

You said you assumed the same version, but it might be best you check exactly, otherwise we cant be certain thats not the problem. You can find the version that you have installed by starting Measurement & Automation Explorer, expanding the my system tree, and then the software tree. You should be able to find soft motion under there and confirm the version.

 

 

You can download the version for 2013 here if necessary http://joule.ni.com/nidu/cds/view/p/id/4265/lang/en

 

Kind regards,

Matt H
Applications Engineer
National Instruments UK
0 Kudos
Message 4 of 25
(4,404 Views)

I should note that you will find SoftMotion beneath the appropriate labview tree in the previously mentioned subgroup

 

Regards,

Matt H
Applications Engineer
National Instruments UK
0 Kudos
Message 5 of 25
(4,402 Views)

Sorry I think I made a misake in my previous post. I think when I got the version error I upgraded both LabVIEW and SolidWorks, LabVIEW to 2013 and SolidWorks to 2012. It appeared to fix that issue, allowing me to add SolidWorks asssemblies to LabVIEW and start up simulations, although not actually intervene in the model. So currently I am running LabVIEW 2013 (not sure if that's SP1, but it says 13.0), and MAX shows I am using SoftMotion 13.0.1

 

Thinking it over I am wondering if maybe just my VI programming is totally wrong, because things do suggest that the programs would work together, everything apart from the -70229 faults that is. There is no reading coming from the read block, and no activity in the SoliWorks model when I run a straight-line-move, but maybe my programming is wrong? I have just used default values of 1000 for velocty and position, and default of zero for acceleration.

 

Thank you so much for your help, I was totally at sea with this, it's great to have some help!

0 Kudos
Message 6 of 25
(4,398 Views)

Hi Ashwin,

 

No Worries, Im happy to help!

 

If you can get the softmotion functions in LabVIEW then that would suggest that you did manage to solve your initial problem. Have you tried running individual functions and seen if they work alone?

 

Regards,

Matt H
Applications Engineer
National Instruments UK
0 Kudos
Message 7 of 25
(4,392 Views)

Hi Matt,

 

Sorry for the delay, my connection seems to have been ditched, so had to switch computers.

 

Yup I have tried many permutations, including individual functions, in the way it was outlined in a tutorial as well, step by step. (I can't seem to access the tut now but it was a white-paper, possibly http://www.ni.com/white-paper/9566/en I tried a Read block whilst the motor was being rotated in SolidWorks to see if any values were output. I tried Straight-Line-Moves, assuming that would drive a motor, but I wasn't sure if I should use it in Absolute of Relative or some other mode. I have no idea what sort of values to input either. I have copied the wiring and set-up for a tutorial for a Sorting Machine but that wouldn't work. Eventually I posted because I noticed the -70229 error, but I've got not much idea what I am doing.

Regards, Ashwin

0 Kudos
Message 8 of 25
(4,383 Views)

Hi Ashwin,

 

If you've been following tutorials, I would have thought that things should work properly. One potential troubleshooting step would be to try the same thing in LabVIEW 2012 (Make sure you install the right version of SoftMotion, found here http://joule.ni.com/nidu/cds/view/p/id/3117/lang/en). For controlling a servo motor I think that SoftMotion includes some specific functions, as documented here http://zone.ni.com/reference/en-XX/help/371093K-01/nimclvfb/controlipservo/, I don't know if you've tried any of those, they might work better than what you've been trying already. If you can find any tutorials again,it would be good if you can point me towards them that would be handy.

 

Ill continue looking into the problem my end, let me know if you have any joy doing anything with any SoftMotion functions.

 

Kind regards,

Matt H
Applications Engineer
National Instruments UK
0 Kudos
Message 9 of 25
(4,378 Views)

Hi Matt,

Well I am downloading the 2012 SoftMotion, we shall see if that works! I have looked

at the servo motor functions and they look great, exactly what I need. But it would

appear it needs SoftMotion Premium which I don't have at home. I will take a look to

see if they have it on the University system when I go in tomorrow. That would

certainly be a great soluton if I could get access to the premium version some day,

but as for this project (which is coming to an end soon) I don't know what to do.

What are FPGA targets? The servo functions say they are specific to FPGA targets.

Thank you so much for your help, you have been very helpful in my time of need! I will see how SoftMotion 2012 works when it is up and running. My connection on my desktop seems to be down, so will have to wait for that to sort itself out before downloading SoftMotion 2012. Thank you so much!

Kindest regards,

Ashwin

0 Kudos
Message 10 of 25
(4,373 Views)