Menu
Microbots
0
  • Learn
    • Getting Started
    • Maker Builds
    • Education
  • Shop
    • Modules & Parts
    • Tools & Gears
    • Robots & Displays
  • About
    • Our Story
    • Reach Out
    • FAQs
  • Sign in
  • English
  • Your Cart is Empty
Microbots
  • Learn
    • Getting Started
    • Maker Builds
    • Education
  • Shop
    • Modules & Parts
    • Tools & Gears
    • Robots & Displays
  • About
    • Our Story
    • Reach Out
    • FAQs
  • Language

  • 0 0

Understanding CodeCell Charging

The CodeCell offers flexibility in power supply options, allowing it to be powered through either the LiPo battery connector, a USB-C cable, or both simultaneously. This ensures adaptability across different use cases.

  • LiPo Battery Connector: Designed for safe and easy battery connection without soldering.
  • USB-C Port: Functions as a power source, charging port and a programming interface.

Power management is handled by the BQ24232 battery management chip, which supports Dynamic Power-Path Management (DPPM). This allows the CodeCell to run from external power while simultaneously charging the battery. The battery charging process follows three key phases:

  1. Conditioning Precharge – Ensures safe charging of deeply discharged batteries.
  2. Constant Current Charging – Provides a stable charge rate until the battery reaches a designated voltage threshold.
  3. Constant Voltage Charging – Maintains a constant voltage while gradually reducing current to complete the charge cycle.

The BQ24232 chip regulates the output voltage, supporting a maximum output of 1500mA when powered by the LiPo battery and 450mA when powered via USB.

Default Charging Parameters

By default, the LiPo battery charge current is set to 90mA. This is optimized for the optional 170mAh LiPo battery, ensuring a safe and balanced charging rate.

Advanced users who wish to modify the charge current can do so by replacing 0402 resistor R12. However, this modification requires precise soldering skills, as 0402 components are extremely small. For further details, refer to the BQ24232 datasheet.

Charging Indicators

The CodeCell library provides visual feedback on charging and power status using the onboard RGB LED:

  • Low Battery Warning: When battery voltage drops below 3.3V, the LED blinks red ten times, and the device enters Sleep Mode to conserve power.
  • Charging Process: While charging via USB, the LED remains blue. When the battery reaches full charge, the LED transitions to a breathing-light animation.
  • Battery Powered Mode: When running solely on battery power, the LED turns green and performs a breathing-light animation.

Reading Battery State

To read the power status of the CodeCell users can use the PowerStateRead() function:

  • 0 = Running from LiPo Battery Power
  • 1 = Running from USB Power
  • 2 = Power Status is Initializing 
  • 3 = LiPo Battery is low
  • 4 = LiPo Battery has fully charged
  • 5 = LiPo Battery is charging

Note: This feature is available from software release v1.2.8 and above, so make sure you have updated the firmware. The CodeCell remains operational while charging the battery, so if you like to stop operation, we recommend polling the power status.

Reading Battery Voltage & Level

To read the battery voltage you can use the BatteryVoltageRead() function or the BatteryLevelRead() to read the battery percentage.

For BatteryLevelRead(), the value returned is between 1–100%. If the battery is charging, it will return 101 and if the CodeCell is powered only via USB without a battery, it will return 102.

Conclusion:

With this information, you now have a full understanding of how CodeCell’s charging system works, including its default behaviors and customization options!

  • Share:

Follow

Github

  • About
  • Software
  • Education
  • Contact
  • FAQs
  • Terms
  • Refund Policy
  • Privacy Policy

Join our Community ~ Be the first to know about new products and get exciting deals!

© 2026 Microbots.

★ Reviews

Let customers speak for us

53 reviews
Write a review
85%
(45)
4%
(2)
2%
(1)
4%
(2)
6%
(3)
21
49
G
CodeCell C6 Drive
Gerhard Weidenauer

Great board with many funktions in small space

User picture
L
MotorCell
Lennart Lange

Nice packaging, good follow up on the delivery, need to look up some online resources now for my first actual project wiht the cell

B
CodeCell C6 Drive
Brandon

Awesome product with great tutorials and example code

G
MotorCell
Gerald Kendrick

Very happy with my MotorCell. I'm incorporating it into a prototype project that will hopefully result in me needing a few more!

User picture
A
CodeCell C6 Drive
Anonymous

Great product! Having the IMU, motor driver, and battery management directly on the board is incredibly handy for quick prototyping. Love it!

Improvement ideas:
- using an ESP32 other than the C6 to get more cores. On a single-core chip, WiFi tasks often interfere with real-time applications.
- adding two more motor drivers (with a slightly higher current rating) would be awesome for drone projects!
- I know the compactness of the board is a huge selling point and really optimised, but exposing a few more pins would be great. With the motor drivers already occupying 4 pins, having only 4 GPIOs left can be tight for complex projects (though I’m nitpicking, I’m really pushing this board to its limits!).

123