Page 1 of 2

the position control on roboclaw 2X30A

Posted: Sun Nov 03, 2019 9:04 pm
by gc967
HI,

i am using roboclaw 2X30A to control motor position.

there are two problems.

first one, how to determine the value of MAX POS on Ion Studio in position setting if i want to control the motor running in just one circle range.

second, i succeeded to control position on Ion Studio but failed to apply it on myRIO through LabView program. The status block works well since it can read the PID values. However, when using the speedacceldeccelpostion m1 block, i cannot control the motor. Sometimes, it will report some errors but errors will disappear if I run the program again.

thanks,
Geng

Image


Re: the position control on roboclaw 2X30A

Posted: Mon Nov 04, 2019 9:53 am
by Basicmicro Support
You will need to be more specific about your application. What do you mean by one circle range?

As for Lab View, check the variable ranges allowed. For the position commands it appears the position variable is being limited to a byte. This need to be changed to a long.

Re: the position control on roboclaw 2X30A

Posted: Wed Nov 13, 2019 8:53 pm
by gc967
Actually, I mean when I use the position control in Ion Studio, how i can let the motor rotate just 360 degrees accurately. In other words, how to calculate the value of MAX position in order to achieve this goal.

thanks,

Re: the position control on roboclaw 2X30A

Posted: Wed Nov 13, 2019 9:05 pm
by gc967
Basicmicro Support wrote:
Mon Nov 04, 2019 9:53 am
You will need to be more specific about your application. What do you mean by one circle range?

As for Lab View, check the variable ranges allowed. For the position commands it appears the position variable is being limited to a byte. This need to be changed to a long.
Meanwhile, could you show me how to change the variable into long type since I cannot find it in the examples offered.

thanks

Re: the position control on roboclaw 2X30A

Posted: Thu Nov 14, 2019 9:23 am
by Basicmicro Support
1. Make sure you update to Basicmicro Motion Studio. If you are still using Ion Motion you have old firmware.

2. The byte to long change was found by another customer while I was working with him on the phone so I have no screen shots but you should be able to bring up properties for the Position value edit box. In there you can change the variable type. It should be a 32bit value, not an 8 bit. If that is your problem that should get you running.

I do recommend that unless you are very familiar with LabView or have absolutely no other choice, that you use Python instead of LabView. LabView is very difficult to support because it is all GUI and a lot of its GUI is pretty horrible in my experience.

Re: the position control on roboclaw 2X30A

Posted: Tue Nov 19, 2019 5:33 pm
by gc967
Basicmicro Support wrote:
Thu Nov 14, 2019 9:23 am
1. Make sure you update to Basicmicro Motion Studio. If you are still using Ion Motion you have old firmware.

2. The byte to long change was found by another customer while I was working with him on the phone so I have no screen shots but you should be able to bring up properties for the Position value edit box. In there you can change the variable type. It should be a 32bit value, not an 8 bit. If that is your problem that should get you running.

I do recommend that unless you are very familiar with LabView or have absolutely no other choice, that you use Python instead of LabView. LabView is very difficult to support because it is all GUI and a lot of its GUI is pretty horrible in my experience.
I change the data type of the address, it is always valid currently but the program still cannot control the motor position. Could you show me whether these all values are in the correct data type?
Image

Re: the position control on roboclaw 2X30A

Posted: Tue Nov 19, 2019 5:34 pm
by gc967
Image

Re: the position control on roboclaw 2X30A

Posted: Tue Nov 19, 2019 5:36 pm
by gc967
Image

Re: the position control on roboclaw 2X30A

Posted: Tue Nov 19, 2019 5:45 pm
by gc967
Hi,

Thanks again for the support. Here is the LabVIEW program in case it helps you diagnose the problem.
Untitled 6.zip
(10.44 KiB) Downloaded 91 times
We have spent some weeks now troubleshooting and still cannot work out why this control-mode is not working. Unlucky for us, this is the specific mode we need for our project. If we can get this to work in LabVIEW, we can buy some more drivers to run in parallel to control 6 motors for our walking robot.

Thanks.

Re: the position control on roboclaw 2X30A

Posted: Wed Nov 20, 2019 8:49 am
by Basicmicro Support
Only the Position setting needed to be changed. Changing the other types may have broken something else. I recommend you download the labview driver again and modify JUST the Position value type. U32 or I32 is fine.