On the Bafang controller, the ERROR 21H
Controller Report Error
code may result while riding.
The issue that may you may have is the Bafang system powers off after a few minutes.
Powering it back up, will allow the pedal assist to continue, however the speed will not display and the mileage will not increase on the computer display. After a short amount of time, the computer unit will turn off and stop displaying and the pedal assist will stop.
(This is the same as the Auto-Shut off that happens when you leave your bicycle parked for a while and it turns off because of no movement.)
The 21H Error indicates the Bafang speed sensor is not functioning. The sensor magnet may have come out of position or the wiring had become faulty.
But most likely, the issue is the magnet on the wheel spoke is out of position. Check the magnet for the positioning so that the magnet passes by the speed sensor. Wipe the magnet and speed sensor off in case there has been a build up of mud or dirt that is keeping the magnet from triggering the sensor as it passes.
In case of an electric malfunction, an application of di-electric grease on all of the electric connections can quickly the resolve electric connection issues. Disconnect the speed sensor wire connection and apply the di-electric grease in both ends of the connector and reconnect. If you are riding on dusty trails, the dust may have went into the electric connection and stopped the electrical circuit. The di-electric grease will resolve the issue.
The same issue has happened on a Shimano Steps e-bike I was servicing. The application of di-electric grease in the wire connections immediately resolved the Shimano Steps systems error codes.
It is a good idea the put di-electric grease in all of the e-bike connections.
✅Having a small tube of dielectric grease in your bicycle tool kit is highly recommended.