Timo Karppinen / Mbed OS Hello_IHM02A1_OS_L476RG

Dependencies:   X_NUCLEO_IHM02A1

Embed: (wiki syntax)

« Back to documentation index

main.cpp File Reference

main.cpp File Reference

mbed test application for the STMicroelectronics X-NUCLEO-IHM02A1 Motor Control Expansion Board: control of 2 motors. More...

Go to the source code of this file.


Detailed Description

mbed test application for the STMicroelectronics X-NUCLEO-IHM02A1 Motor Control Expansion Board: control of 2 motors.

Author:
Davide Aliprandi, STMicroelectronics
Version:
V1.0.0
Date:
November 4th, 2015
Attention:

© COPYRIGHT(c) 2015 STMicroelectronics

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. 3. Neither the name of STMicroelectronics nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

Comments by Timo Karppinen For correct use of the NUCLEO-F401RE, L476RG with the X-NUCLEO-IHM02A1, the solder bridge SB15 on the NUCLEO-x4xxRx has to be removed / Getting started with X-NUCLEO_IHM02A1, page 3/24. = IHM02A1 L6470 nCS

Set the motor parameters before connecting the motor!!! Supply voltage, Maximum motor phase curent and Maximum phase voltage are the most important ones. Set as well the step angle - you will set the number of steps per revolution.

On first tests supply the IHM02A1 voltage from a source where you can set the current limit. The limit should correspond the maximum phase current given in the step motor data sheet. Two phases are driven at a time the current might be double the motor phase current.

Wiring the IHM02A1 --- ST4118X1404-A 2A --- Orange phase A\ 1A --- Brown phase A 1B --- Red phase B 2B --- Yellow phase B\

Definition in file main.cpp.