Stepper 7 Click Board
Stepper 7 Click Board
The Stepper 7 Click Board™ is a bipolar step motor driver. It features an H-bridge bipolar step motor driver, which supports full and half step control modes. The Stepper 7 Click Board™ also carries a port expander so that the communication can be done with a minimal number of pins, through the mikroBUS SPI bus.
Software Support
We provide a library for the Stepper 7 Click Board™ on our LibStock page, as well as a demo application (example), developed using MikroElektronika compilers and mikroSDK. The provided click library is mikroSDK standard compliant. The demo application can run on all the main MikroElektronika development boards.
Library Description
This library carries everything needed for stepper motor control, including speed and acceleration setup. The library can be adjusted to work on the different amount of ticks per second. Also, speed and acceleration can be provided in float format. The buffer used for movement calculation is defined by the user in order that the library can be adjusted for MCUs with very limited RAM resources. Check the documentation for more details how to use it.
Key Functions
uint8_t stepper7_setSpeed( float minSpeed, float maxSpeed, float accelRatio, T_STEPPER7_OBJ obj )
- Sets up the motor speed
uint8_t stepper7_setRoute( const uint8_t direction, uint32_t steps, T_STEPPER7_OBJ obj )
- Sets up a new route
void stepper7_start( T_STEPPER7_OBJ obj )
- Starts motor movement
The application is composed of three sections :
- System Initialization - Initializes all GPIO pins found on Stepper 7 Click and timer to 1ms interrupt.
- Application Initialization - The first segment initializes driver and stepper control. The second segment
sets up movement limits, maximum and minimum speed, and acceleration ratio. The third segment enables motor
and sets up the new route which will be called from the application task. - Application Task - (code snippet) - Sequentially moves the motor and executes movement until the end.
void applicationTask() { stepper7_start( (T_STEPPER7_OBJ_P)&myStepper ); while( myStepper.status.running ) stepper7_process( (T_STEPPER7_OBJ_P)&myStepper ); Delay_ms( 2000 ); }
In addition to library function calls, example carries necessary Timer ISR and Timer initialization. Check Timer initialization settings and update it according to your MCU - Timer Calculator.
The full application code, and ready to use projects can be found on our LibStock page.
Additional Notes and Information
Depending on the development board you are using, you may need a 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. The terminal available in all MikroElektronika compilers, or any other terminal application of your choice, can be used to read the message.
MIKROSDK
The Stepper 7 Click Board™ is supported with mikroSDK - MikroElektronika 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.
Stepper 7 Click Board
Frequently Asked Questions
Have a Question?
Be the first to ask a question about this.