me7VwYi

Smart cars based on the Liangshan School of Licheng

 
Overview
The smart car based on the LCSC Liangshanpai
model uses two 14500 rechargeable lithium batteries.
The simplified version aims to keep the PCB size within 10x10mm, therefore, the interfaces for the camera and remote control modules are not included. The tracking module is also reduced to a single comparator chip.
 
Most components are through-hole, such as 1kΩ, 10kΩ, and 20kΩ resistors, buttons, and indicator lights. This is for easier soldering (actually, it's to clear out inventory from the training camp's simple oscilloscope).
 
Replacing components should be done with caution!
 
Since the official RZ7899 motor driver chip was unavailable on the LCSC website, a substitute, the BDR6126D, was used. The pin definitions are the same, and the schematic doesn't need modification. (And it's through-hole; having gone through the simple oscilloscope training camp, I'm still quite familiar with through-hole soldering).
However, there are noticeable differences in actual use.
First, there is no recommended wiring diagram for the RZ7899, or rather, the following application circuit is the recommended wiring diagram. The image below shows the application circuit for the RZ7899. (I noticed the official tutorial didn't include a capacitor between VCC and GND next to the motor driver chip, or even a filter capacitor next to the comparator.)
However, the BDR6126D application diagram recommends an external capacitor for VCC. I didn't include this in my simplified version.
In hindsight, this is quite dangerous; decoupling capacitors are crucial. They need to be at least 100uF, a value that's difficult for a 0603 package, and the rated voltage needs to be at least 7.4V. Tantalum and aluminum electrolytic capacitors seem the most reliable options.
Secondly, in my own testing, PWM has no control effect on the BDR6126D; the input PWM wave cannot achieve the effect of speed regulation of the motor (it works after retesting, updated 2024.4.24). The following is the input control timing diagram of the BDR6126D.
Previously, the RZ7899 datasheet didn't contain any description of PWM waves, leading me to believe that anything conforming to a similar input truth table would have similar performance. The image below shows the input truth table for the RZ7899, which is completely identical to that of the BDR6126D. (Surprised by the harsh realities of the market)
 
A closer look at other motor driver chips from Bardin Microelectronics (the BDR6126D is one of their products) reveals clear indications that PWM input is possible, along with corresponding input control timing. This datasheet provides nothing; while PWM control is possible, it feels somewhat unprofessional.
Changing the parameters in the PWM duty cycle function did not achieve the expected speed control effect. Adjusting the speed setting didn't significantly change the motor speed.
Another issue is the power-on timing of the BDR6126D. Before VCC power-on, its control pins cannot be logically controlled.
However, in the pin assignment, LQ- is assigned to PB4, and PB4 is in pull-up mode after reset. Using the BDR6126D, after downloading the program and resetting, the left front wheel always rotates; continuously pressing the reset button will cause it to rotate continuously.
 
Pin assignments are clearly not arbitrarily chosen.
 
To simplify wiring, I assigned one of the tracking GPIO pins to PA14 in the simplified version. This introduced a potential problem: after the program is downloaded and reset, the tracking indicator light on that line becomes very bright and only returns to normal after a power cycle. Secondly, I configured PA14 in pull-up mode, so Keil cannot recognize the DAP download port, requiring the program to enter boot mode for the next download (similar to serial port downloads). Always carefully read the datasheet when assigning pins! In short, these two tracking lines are essentially unusable.
 
Finally, a serious issue arises: when the car is given a straight-ahead command via Bluetooth, it turns left, and the same happens when reversing, similar to turning the steering wheel to the left while reversing. Right-turn and left-turn commands cause the car to rotate counter-clockwise and clockwise respectively.
Initially, I suspected the problem stemmed from differing wheel friction, given that the wheels are 3D printed and not perfectly round (they're white and get dirty after rolling around on the ground); or perhaps the motor output torque was different (the motors weren't from the same manufacturer). However, after swapping the wheels (right front and left rear, and if the motor torque output was inconsistent, or the wheel friction differed significantly, placing the stronger drive in the front and the weaker drive in the rear to balance the torque), the problem persisted. Reducing the output of the right half of the motor didn't resolve the issue either (leading me to discover that PWM had no effect on the BDR6126D driver chip).
参考设计图片
×
 
 
Search Datasheet?

Supported by EEWorld Datasheet

Forum More
Update:2026-03-26 23:17:56

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
community

Robot
development
community

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号