How does it work?
DC Motor 4 Click is based on the MAX14870, a compact full-bridge DC motor driver from Analog Devices. The driver integrates a short-circuit-protected driver, thermal-shutdown under-voltage lockout, and a separate voltage-sense input that reduces current sensing errors due to parasitic trace resistance. The MAX14870 has a simplified design without a charge pump, and the current is regulated over a sense resistor. The DC Motor 4 Click can supply a connected motor over the external power supply and a screw terminal or by 5V of the mikroBUS™ socket’s rail. You can select power supply input over the MOTOR PWR header jumper, while the 5V of the mikroBUS™ socket’s rail is set by default.
DC Motor 4 Click support changing the direction of the rotation of the connected motor, it can also brake the motor’s rotation, shut the driver down, and regulate the current, thus the motor’s speed. It also features fault output signals for thermal overload and overcurrents. However, the MAX14870 also features an auto-retry mode that will try to enable the driver’s outputs after a 2ms timeout, and if the problem persists, the drivers will be disabled.
DC Motor 4 Click uses a pulse-width modulation signal from the host MCU over the PWM to set the speed of the motor. You can set the rotation direction over the DIR pin. MAX14870 will output the fault statuses over the FLT pin, and the EN pin is used to enable or disable the motor driver.
This Click board™ can operate with either 3.3V or 5V logic voltage levels selected via the I/O SEL jumper. This way, both 3.3V and 5V capable MCUs can use the communication lines properly. However, the Click board™ comes equipped with a library containing easy-to-use functions and an example code that can be used as a reference for further development.
Specifications
Type
Brushed
Applications
Can be used for the development of printers, scanners, relay drivers, vending, gaming machines, and more
On-board modules
MAX14870 – compact full-bridge DC motor driver from Analog Devices
Key Features
Wide range of motor’s power supply voltage, up to 2.5A of peak motor current, low power consumption, speed, and direction control, fault statuses output, short-circuit-protected drivers, thermal-shutdown under-voltage protection, and more
Interface
GPIO,PWM
Feature
No ClickID
Compatibility
mikroBUS™
Click board size
M (42.9 x 25.4 mm)
Input Voltage
3.3V or 5V
Pinout diagram
This table shows how the pinout on DC MOTOR 4 click corresponds to the pinout on the mikroBUS™ socket (the latter shown in the two middle columns).
Onboard settings and indicators
Label | Name | Default | Description |
---|---|---|---|
– | PWR | – | Power LED Indicator |
JP1 | I/O LEVEL | Left | Logic Level Voltage Selection 3V3/5V: Left position 3V3, Right position 5V |
JP2 | MOTOR PWR | Left | Motor Power Supply Selection 5V/EXT: Left position 5V, Right position EXT |
RDC MOTOR 4 Click electrical specifications
Description | Min | Typ | Max | Unit |
---|---|---|---|---|
Supply Voltage | – | 5 | – | V |
External Motor Power Supply | 4.5 | – | 36 | V |
Peak Motor Current | – | – | 2.5 | A |
Software Support
We provide a library for the DC Motor 4 Click as well as a demo application (example), developed using MIKROE compilers. The demo can run on all the main MIKROE development boards.
Package can be downloaded/installed directly from NECTO Studio Package Manager(recommended), downloaded from our LibStock™ or found on Mikroe github account.
Library Description
This library contains API for DC Motor 4 Click driver.
Key functions
-
Generic sets PWM duty cycle.
-
Stop PWM module.
-
Start PWM module.
Example Description
The click is designed to run on either 3.3V or 5V power supply.
void application_task ( void )
{
counter_clockwise( );
clockwise( );
}
The full application code, and ready to use projects can be installed directly from NECTO Studio Package Manager(recommended), downloaded from our LibStock™ or found on Mikroe github account.
Other Mikroe Libraries used in the example:
- MikroSDK.Board
- MikroSDK.Log
- Click.DcMotor4
Additional notes and informations
Depending on the development board you are using, you may need USB UART click, USB UART 2 Click or RS232 Click to connect to your PC, for development systems with no UART to USB interface available on the board. UART terminal is available in all MIKROE compilers.
mikroSDK
This Click board™ is supported with mikroSDK – MIKROE Software Development Kit. To ensure proper operation of mikroSDK compliant Click board™ demo applications, mikroSDK should be downloaded from the LibStock and installed for the compiler you are using.
For more information about mikroSDK, visit the official page.