Simple program featuring a few API functions usage of the X_NUCLEO_IHM04A1 library.

Dependencies:   X_NUCLEO_IHM04A1 mbed

Dependents:   SimplePIDBot

Fork of HelloWorld_IHM04A1 by ST Expansion SW Team

This application provides a simple example of usage of the X-NUCLEO-IHM04A1 Brush DC Motor Control Expansion Board.

It shows how to use four unidirectional brush DC motors connected to the board by running the four motor in parallel. At the beginning, no motor is running. Each time the user presses the user button, a new brush DC motor is activated. Motors run during one second, stop during one second and run again.

  • motor 1 runs at 20% of maximum speed.
  • motor 2 runs at 30% of maximum speed.
  • motor 3 runs at 40% of maximum speed.
  • motor 4 runs at 50% of maximum speed.

For the hardware configuration of the expansion board, please refer to the X_NUCLEO_IHM04A1 library web page.

Revision:
7:20ff5668f5fe
Parent:
6:b9b32d6c2b40
Child:
8:05340e740644
--- a/main.cpp	Fri Mar 24 11:00:26 2017 +0100
+++ b/main.cpp	Fri Mar 24 13:09:02 2017 +0000
@@ -179,7 +179,7 @@
     motor->attach_error_handler(my_error_handler);
 
     /* Printing to the console. */
-    printf("Motor Control Application Example for 4 Motor\r\n\n");
+    printf("Motor Control Application Example for 4 Motors\r\n\n");
 
     /* Select the configuration with no bridge paralleling, two unidirectionnal motors on bridge A 
        and two unidirectionnal motors on bridge B */