HAPO WS22 / Mbed 2 deprecated HAPO_WS22_Labor3_final

Dependencies:   mbed

Files at this revision

API Documentation at this revision

Comitter:
alexander0707
Date:
Mon Dec 05 15:58:01 2022 +0000
Parent:
22:5600f9b29a51
Commit message:
v4.0 Jetzt klappts doch.

Changed in this revision

main.cpp Show annotated file Show diff for this revision Revisions of this file
--- a/main.cpp	Mon Dec 05 15:47:05 2022 +0000
+++ b/main.cpp	Mon Dec 05 15:58:01 2022 +0000
@@ -76,18 +76,10 @@
 #define nZifferF    ~(nSegA | nSegE | nSegF | nSegG)
 #define nZifferOff   (nSegA | nSegB | nSegC | nSegD | nSegE | nSegF | nSegG | nSegH)
 
-byte bIdx; /*
-* Description : Index auf Ausgabe
-*/
-
 byte bDigit; /*
 * Description : aktives Digit
 */
 
-byte bBargraph; /*
-* Description : Bargraph durchschalten
-*/
-
 byte bS1Timer; /*
 * Description : Timer für Taste S1
 */
@@ -112,14 +104,6 @@
 const byte enVergleich = 0x02;
 
 
-byte bState; /*
-* Description : 
-*/
-
-byte bHotKey; /*
-* Description : Auswahl der Taste
-*/
-
 byte bDisplayDot; /*
 * Description : 
 */
@@ -128,18 +112,6 @@
 * Description : Hauptzustand
 */
 
-byte bBeepTime; /*
-* Description : Tondauer 
-*/
-
-byte bEinstellungsModus;/*
-* Description : Einstellungszustand 
-*/
-
-byte bSchwellenwertVergleich;/*
-* Description : Einstellungszustand 
-*/
-
 byte bTimeLong;/*
 * Description : Ob Taste bereits lange gedrückt war 
 */
@@ -151,17 +123,11 @@
 * Description : pointer to data
 */
 
-byte bComp;
-
 
 word wSerial; /*
 * Description : serielles Ausgaberegister
 */
 
-word wClockTime; /*
-*Description : Timer für verstrichene Zeit
-*/
-
 word wClockShow; /*
 *Description : Timer für verstrichene Zeit
 */
@@ -190,14 +156,11 @@
 * Description : Zähler für Dots
 */
 
-int zaehler;
 
 /* Bitmuster */
 const byte abZiffer[] = {nZiffer0, nZiffer1, nZiffer2, nZiffer3, nZiffer4, nZiffer5, nZiffer6, nZiffer7, nZiffer8, nZiffer9, nZifferA, nZifferB, nZifferC, nZifferD, nZifferE, nZifferF, nZifferOff};
 //const byte abBargraph[] = {~Bit0, ~(Bit0|Bit1), ~(Bit0|Bit1|Bit2), ~(Bit0|Bit1|Bit2|Bit3), 0x0f};
 byte abTxBuffer[60];
-byte abTxBufferOld[60];
-
 
 
 void vShiftLoad(word wLoad){
@@ -348,7 +311,6 @@
     } 
 
 
-
 void vCheckTasten( void ){
     vTasteS1();
     vTasteS2();
@@ -391,13 +353,6 @@
 
 
 
-
-
-
-
-
-
-
 Serial stComX(D1,D0); // UART-Kommunikation (Txd(D1)/Rxd(D0)) mit dem PC 
  
 /*
@@ -487,8 +442,6 @@
 }
 
 
-
-
 /***************************************************************************
 *   main()
 ***************************************************************************/
@@ -507,13 +460,8 @@
         
         if(stComX.readable()) {
             abTxBuffer[0]=stComX.getc();
-        }
-        
-        //stComX.attach(&vIsrRxComX, Serial::RxIrq); /* ISR zum Datemempfang vom PC */
-        //stComX.attach(&vIsrTxComX, Serial::TxIrq); /* Sende-ISR */
-        
-        vCheckCom();
-    
+            vCheckCom();
+        }    
     
         switch(bMainState) {
             case enSchwellenwert: