hmc5883l

Dependencies:   HMC5883L LCD4884 MFRC522 eeprom mbed

Files at this revision

API Documentation at this revision

Comitter:
1918june
Date:
Wed Dec 09 09:03:26 2015 +0000
Parent:
12:7fb5636ca854
Commit message:
june

Changed in this revision

project.cpp Show annotated file Show diff for this revision Revisions of this file
diff -r 7fb5636ca854 -r 9ad2742de34f project.cpp
--- a/project.cpp	Wed Dec 09 07:02:53 2015 +0000
+++ b/project.cpp	Wed Dec 09 09:03:26 2015 +0000
@@ -529,7 +529,7 @@
     UID[6]=39;
     UID[7]=231;
 
-    /*eeprom.write(1,&NameJune,11);
+    eeprom.write(1,&NameJune,11);
     wait_us(1);
     eeprom.write(12,&SurJune,10);
     wait_us(1);
@@ -542,7 +542,7 @@
     eeprom.write(51,&IdO,11);
     wait_us(1);
     eeprom.write(81,UID,8);
-    wait_us(1);*/
+    wait_us(1);
     eeprom.read(1,&recieveNameJune,11);
     eeprom.read(12,&recieveSurJune,10);
     eeprom.read(22,&recieveIdJune,11);
@@ -562,7 +562,7 @@
     lcd.backlight(ON);
     wait(2);
     lcd.LCD_clear();
-    // servodown();
+     servoup();
     while(1) {
         lcd.LCD_write_string(0,0,"SCAN ID CARD",0);
         if ( ! RFID.PICC_IsNewCardPresent()) // Look for new cards read all time
@@ -653,7 +653,8 @@
                     break;
                 }
             }
-
+            mode=0;
+            main();
         }
         if(mode==2) {//selectplace
             printf("2");
@@ -698,9 +699,10 @@
                         eeprom.write(POINT_June,&point,1);
                     if(user==2)
                         eeprom.write(POINT_O,&point,1);
-                    break;
-                }
+                    break;                }
             }
+            mode=0;
+            main();
         }
         //       printf("mode=%d\n",mode);
     }  //end while mode loop