
If you want to use two hub motor to achieve the differential turn, you need to modify their own custom, there are usually the following two ideas for reference:
One is to realize the differential speed cornering of the left and right motors through the programming of a single-chip computer. The concrete method is to give different speed regulation instructions to the left and right single drivers respectively through the programming of a single-chip computer, thus enabling the left and right motors to realize one side braking, while working to achieve a small angle turn, or while turning, while reversing to achieve in situ turn.
But the control precision of this way is not too high, can only control a direction, can not accurately control the angle. In addition, the faster the motor speed, the more difficult to control. If the road is not smooth, it will be more difficult to control. In addition, turning control, like the control of a car, requires a certain degree of proficiency process, only experienced people can better control. Finally, the load driving force is reduced by half when the motor is on only one side of the turn.

The other is through the steering wheel to pull the first two Cardan turn to achieve mechanical turn, the specific practice also needs to be further understood.
If you want to achieve more complex turning effect, you can use the following two options: one is through a single-chip computer to coordinate the control of a number of servo motors with higher accuracy, so as to achieve more complex turning effect. Or use Aircraft Hub Motor Module to achieve more flexible direction control, similar to the complex movement of robots.
Another option is to use computer vision to automatically navigate and turn. In this case, you need to buy a camera and the corresponding computer vision development kit, and write programs to process the images captured by the camera. Automatic Navigation and turn can be realized by computer vision technology, which is suitable for more complex applications, such as autonomous vehicles or robots.