encoder

Dependencies:   QEI mbed

Revision:
2:aa961ba3199e
Parent:
1:1b18e69bf50f
--- a/main.cpp	Wed Nov 08 01:38:27 2017 +0000
+++ b/main.cpp	Fri Nov 10 19:23:08 2017 +0000
@@ -1,9 +1,14 @@
+/*
 #include "mbed.h"
 #include "QEI.h"
 Serial pc (PA_2, PA_3); //serial comm enabled on pins pa_2 and pa_3
 QEI encoder_Right(PB_3, PA_15, NC, 360, QEI::X4_ENCODING);
 QEI encoder_Left(PA_1, PC_4, NC, 360, QEI::X4_ENCODING);   //forward increases pulses
-PwmOut(m_Left, PC_7)
+PwmOut m_Right_B(PC_7);
+PwmOut m_Right_F(PB_10);
+PwmOut m_Left_F(PA_7); 
+PwmOut m_Left_B(PB_6); 
+*/
 
 //QEI functions
 /*
@@ -16,17 +21,20 @@
 int     getRevolutions (void)
     Read the number of revolutions recorded by the encoder on the index channel.
 */
-
+/*
 int main()
 {
-
+    m_Right_F.write(0.5);
+    //m_Left_F.write(.25);
+    //m_Left_B.write(.25); 
     while(1) {
         wait(0.1);
-        m_Left.write(0.75);
+        
         pc.printf("Pulses is: %i\n", encoder_Right.getPulses());
         //pc.printf("Pulses is: %i\n", encoder_Left.getPulses());
     }
     
     
 
-}
\ No newline at end of file
+}
+*/
\ No newline at end of file