Generic Step Motor WebInterface - control a step motor using a Pololu A4983 driver from a webinterface (EXPERIMENTAL PROTOTYPE - just to be used as a proof-of-concept for a IoT talk, will not be updating this code so often)

Dependencies:   EthernetNetIf RPCInterface mbed HTTPServer

Revision:
0:8b3857d4ce02
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/A4983StepMotorDriver/A4983.h	Mon Apr 16 09:41:53 2012 +0000
@@ -0,0 +1,28 @@
+//---------------------------------------------------------------------------------------------
+// Class to interface Pololu A4983 Stepper Motor Driver
+// http://www.coolcomponents.co.uk/catalog/product_info.php?products_id=358&currency=EUR
+// https://www.pololu.com/file/download/a4983_DMOS_microstepping_driver_with_translator.pdf?file_id=0J199
+//---------------------------------------------------------------------------------------------
+class A4983
+{
+  //-------------------------------------------------------------------------------------------
+  private:
+  //-------------------------------------------------------------------------------------------
+  
+  //-------------------------------------------------------------------------------------------
+  public:
+  //-------------------------------------------------------------------------------------------
+  uint8_t  f_motor_enable;             // flag to Enable/Disable Step Motor, 0 => Disable, 1 => Enable
+  uint8_t  f_motor_direction;          // flag for the Step Motor direction, 0 => Normal, 1 => Inverted
+  float    k_delay;                    // delay constant in seconds (Step Motor Speed) [0.0001;0.000025]
+  //-------------------------------------------------------------------------------------------
+  A4983();
+
+  void adjust_microstepping_mode(uint8_t factor);
+  void singlestep();
+  void sleep(bool value);
+  void looprun();
+  void loopstart();
+  void loopstop();
+};
+//---------------------------------------------------------------------------------------------
\ No newline at end of file