2 wheel differential drive robot: weeding task in paddy field

hello,
My goal is to robotize a 2 driven wheels (+3 caster wheels) vehicle for weeding paddy fields!
the vehicle mounts 2 ebike motors (48V - 1600 W).
The robot should:

  • follow the paddy’s row (start and ending points are mapped via GPS).
  • continue the run till the limits of the paddy field.
  • invert direction of the work and change the row.

I want to equip the robot with a GPS RTK module (ARDUSIMPLE).
I am here because I would like to listen your opinion about some questions:

  • which are in your opinion the most suitable ardupilot hardwares for this kind of operations?
  • can i code ardupilot to make my own wheel velocity control (e.g. with a Lyapunov smooth control)?
  • can i make the controller able to read from the Sd the waypoint of the rows? My idea is to make the controller independent from the mission planner.
    Thank you in advance for your time, hope this topic is of your interest
    Andrea
1 Like

I am also trying to build a farm rover using ebike type motors, but am still in the beginning stages. I want to have it travel over our vegetable beds. I have a pair of 12" tires with BLDC hub motors that I am currently playing with.

I am unable to offer an informed opinion about ardupilot hardware being suitable or not, but I am currently trying to figure out if the Pixhawk 2.4.8 will work as a microcontroller with these BLDC motors.

These motors have their own controller that is a box with several wires coming out. So far I’ve learned that I first needed to connect two of these single wires in order for the motor to spin. This is like an on/off switch. Then there is a three-wire harness is for throttle. It is designed to be manually controlled by a scooter driver, and hooking this 3-wire harness to a potentiometer will allow you to manually control the motors speed. I have yet to figure out if Ardupilot and a Pixhawk can use these wires to gain throttle control via RC or through Mission Planner.

There is also a 2-wire harness that makes the wheel spin in reverse if you jumper it. This would likely prove useful, but again, I’m not yet sure if these can be connected to a Pixhawk, so that the motors could be controlled via RC or MissionPlanner.

Further wires that could prove useful are a three-wire harness labeled “3 speed”. Perhaps this could help the tires travel more slowly over the bumpy ground you find around farms

Please let me know if you discover a way to make Ardupilot work with these motors and I’ll do the same

I just found this post which discusses the use of ebike motors controlled by an RC transmitter

In a nutshell “RC servo signal is a 1-2ms pulse with repetition period of ~20ms. Ebike controllers generally accept an analog voltage between 0-5V (with 1V=off and 4V = full throttle). You will need an interface to convert from one to the other.”

The post suggests using an Arduino in between your autopilot and ebike motor controller to read the servo PWM and covert it to the analog voltage your ebike controller needs to operate.

I’m hoping one can also use additional servo outputs to interface with the reverse wire and three-speed selection wires on the ebike controller. These would be great to assign to 2 and 3 way switches on an RC transmitter.

Andrea, I have had an attempt at using brushless motors for my rover:

https://discuss.ardupilot.org/t/redclaw-crayfish-aquaculture-feeder/50311/11?u=bill_k

As mentioned in this post I had to use an Arduino to convert the RC pulses from the autopilot into the appropriate analog voltage plus reversing signal. It proved to be do-able and had a good outcome in controlling the motor on the bench. I guess it would be relatively simple to add low/medium/high speed control switching to the Arduino functionality.

My problem was the very low braking effect of the brushless motors due to the way the supplied brushless controllers worked. My rover has a low rolling resistance and so when the throttle was reduced quickly, the rover kept going faster that the brushless controller could cope. The controller had a brain fade and wouldn’t pick up control again until everything came to a complete stop. Clearly we couldn’t continue with this.

We have swapped to using brushed motors and hope to get back to troubleshooting and using the brushless motors sometime in the future

This BLDC controller has some wires labeled “Cut-off power brake”. Do you think it is possible to use this function to keep the rover, after a quick let off of the throttle, at speeds that avoids the controllers brain fade?

Bookmarking this thread!

I am building an autonomous weed spray bot with differential drive steering.

The detector part is working OK enough ( https://www.youtube.com/watch?v=Z8HcImINGg8 :)).

Platform:
Pixhawk 2.4.8
12v cordless drill motors
uBox M8T RTK
QGroundControl

Like arlottandrea I am also interested in varying the speed during missions. There are references to MAV_CMD_DO_CHANGE_SPEED online but I haven’t investigated.

1 Like

Hi Steve, sorry about the tardy reply.

My controller had less control wires and didn’t come with any identification of which wire was what.
I was able to identify most but never was able to find any “brake” wires. As such I am not in a position to offer much verifiable advice.

My understanding is that with these controllers the brake action will either short the motor windings together (giving the best braking) or connect them back to the battery (giving regeneration but less braking effect). I imagine testing on the bench will give some indication as the braking effect is quite strong.

My guess is that activating the braking will have a positive effect on the control and would be well worth pursuing. If using an Arduino or similar mcu as an interface between the Pixhawk and the motor controller then adding this functionality should be straightforward enough.