Australia
Asked — Edited

Initiation Script

I'm not sure if this normal or not but its always happened to me, whenever I first run the initiation script, the motors with encoders, (radar & waist), both running with Sabertooth/kangaroos, need to "home" to the limit switch so the motors know their position, but one or both don't start "homing". They just sit there. I then stop the script and restart it and the second time they will home. Everything else in the script will run each time I start it, It's just the motors with encoders. Does anybody else have this problem?

Also, I have two EZBs. Most times I need to scan for their address so I can select them and the Init script can connect them. Nearly every time, (from one day to the next) the addresses are different from the last time I connected them. Is there a way to fix this as well?

Steve


ARC Pro

Upgrade to ARC Pro

Join the ARC Pro community and gain access to a wealth of resources and support, ensuring your robot's success.

#1  

In your router reserve a fixed IP address for your ezbs. This way your ezbs (or any other device you choose for that matter) will always have the same IP address...

Australia
#2  

Thanks Richard, That should make things much less annoying at start up. I know you have been using Sabertooth motor controllers for some time now, do you have any thoughts on the encoder homing problem or ever experienced something similar?

#3  

As far as homing, do you have long enough sleep commands before and after the homing commands? You mentioned that you have trouble connecting to the ezb's. Are you sure you're connected when you have the homing issues.

I home several encoders for Roos in my int scrip for my b9. Download my latest project from the cloud and have a look. Maybe you'll see something that helps. Post your project so we can take a look. ;)

Australia
#4  

Hi Dave,

I had a read of your Init script, awesome by the way, and I'm fairly certain that my issue is, as you suggested, not enough sleep before the motors try homing, I will re-wright my script and see if that works

Thanks Dave

#5  

Ya, I found that you need to give the system enough time to send the command through the Uart port and receive it. It's pretty fast but it's easy to flood considering you're sending through wifi and dealing with three or four devices. Keep us informed.;)

Australia
#6  

Well Dave, You've done it again :) The new Init script with more sleep worked perfectly. I basically copied yours and modified to suit my configuration and omitted the stuff I don't have yet, Like arms ;) Works first time, every time.

Thanks Dave.

#7  

I'm glad I was able to help out some how.

Did you get your connection issues fixed yet with the rolling IP address and having to rescan all the time? I hope Richard's suggestion helped. :)

Australia
#8  

I haven't fixed that problem yet, but only I need to work out how to open the router settings and change them, I'm sure that will fix the problem. I have put it off because I have a new router from our service provider coming and once I receive that I will be able to reserve addresses to the EZBs ......

#9  

I bet you're going to be very happy with the outcome.