4wd Project

Marv

USA

Thought I would share my progress so far converting my old 4WD project over to using my new EZ-B controller. Over the last year or so, I have had it running on an Arduino Mega using Xbee RF modules for communications.

I had an on-board 2.4ghz camera but always had problems with it knocking out my Xbee communications (also 2.4ghz). Lately I tried Synapse RF modules instead of Xbee but had similar issues. I don't think I'll have any problems using the EZ-B camera and Bluetooth communications. But at some point, I want to change the EZ-B's Bluetooth adapter over to Synapse, as it can work out to several thousand feet line of sight.

Here's how the 4WD is outfitted: (1) Sabertooth 2x12 motor controller; (4) Gearhead 12V, 30:1, 200rpm motors; (1) 12V 2800mAh battery; (4) Sharp GP2Y0A21YK0F IR Range Sensors; (2) Quadrature Motor Encoders.

The Sabertooth and battery pack are located in the base. The Sharp range sensors, EZ-B ultrasonic sensor and camera are not connected in the photo, so don't give me a hard time about all the loose wires.

I never got around to installing the motor encoders or doing any more with the Sharp range sensors than testing them. The motor encoders will eventually be used to keep track of distance travelled.

Here's where I'm at this point in the new project: I have the Sabertooth motor controller connected and working with the EZ-B much to our dog's frustration. Reminds me, I need to add the ability for the 4WD to bark.

The Sabertooth swiches are set for Mode 3 Simplified Serial at 38,400 baud (1,3, & 6 ON). The EZ-B is getting its 12VDC power from the same battery as the Sabertooth, so their grounds are tied together through the battery connection. The only other connection is one wire from the Sabertooth S1 terminal to the EZ-B's D0 port.

Because I have both of my left motors are connected to the Sabertooth's Motor #1 output and both of my right motors are connected to its Motor #2 output, I had to change the settings in ARC's HBridge Sabertooth Panel as follows:

Full Forward Left 127 Right 255

Turn Left Left 1 Right 255

Turn Right Left 127 Right 128

Full Reverse Left 1 Right 128

It goes forward or reverse about 10 feet per second with these settings. It can rotate or turn on a dime and would no doubt eventually tear a hole in the carpet, which my wife says will cause something even worse to happen, depending on who she catches first. Really, those tires mounted to those motors can do some serious turning when one side goes full forward and the other side goes full reverse.

Next up will be making the EZ-B ultrasonic ranging sensor work with my 4WD. I have tested the ultrasonic sensor by itself, and it works great. It looks like it can sense 3-4 times farther out than the Sharp sensors.

Until next time.

User-inserted image

By — Last update

ARC Pro

Upgrade to ARC Pro

Experience early access to the latest features and updates. You'll have everything that is needed to unleash your robot's potential.

#17  

One simple thing I've forgotten before is making sure there are ground wires between all modules. confused

Canada
#18  

Thanks yeah I could see how that would be easy to miss too. I figured out that it was a defective controller. Swapping it out fixed the issue. Thanks for all your help!

#19  

Hi Marv,

Great robot and nice Blog. I am also using a Sabertooth 2 x 12. Could you explain how you determined the values that you used in the config section? I must be misunderstanding something......not sure I follow how to decide what numbers to use for my Sabertooth. I tried the numbers you used but, it is not going full speed in FWD or REV. When I tried changing some of the numbers it behaves differently than I would expect.

I guess what really throws me is the nomenclature used such as "Left Turn Left Value", "Right Turn Left Value" and some of the others mentioned on the picture below.

User-inserted image

Thanks,

Rex

#20  

Update....

Marv, I reviewed your previous post and discovered my answer. I need to read more carefully :D

Anyway you posted....

"Left Motor = 1 to 127 (Full Rev = 1, Stop = 64, Full Fwd = 127) Right Motor = 128 to 255 (Full Rev = 128, Stop = 192, Full Fwd = 255)"

This was the key!

#22  

I was about to say I've been sidetracked by another project the past couple of months, but I see it has been more like 4 months! Once it gets nicer here in Indiana, I'll get back to my robot. I want to do some camera and wireless testing with it outside.

I've been totally engrossed in a Raspberry Pi this winter and am now in the process of converting my home monitor & control system over to it from a Windows computer.

Here's a blog of some of my tests: http://allenmlab.blogspot.com/

#23  

Yes, I can see that from your blog. I once knew a top tier programmer from indiana named Marv. By chance have you ever worked on state government projects?

#24  

Nope -grew up here and retired here but lived everywhere else in between...